From nobody Tue Feb 21 19:24:52 2023 X-Original-To: freebsd-hackers@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4PLq4L6JRVz3t6pX for ; Tue, 21 Feb 2023 19:25:06 +0000 (UTC) (envelope-from SRS0=YbkP=6R=quip.cz=000.fbsd@elsa.codelab.cz) Received: from elsa.codelab.cz (elsa.codelab.cz [94.124.105.4]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4PLq4K5lMnz41S4 for ; Tue, 21 Feb 2023 19:25:05 +0000 (UTC) (envelope-from SRS0=YbkP=6R=quip.cz=000.fbsd@elsa.codelab.cz) Authentication-Results: mx1.freebsd.org; none Received: from elsa.codelab.cz (localhost [127.0.0.1]) by elsa.codelab.cz (Postfix) with ESMTP id B7891D7893; Tue, 21 Feb 2023 20:24:57 +0100 (CET) Received: from [192.168.145.50] (ip-89-177-27-225.bb.vodafone.cz [89.177.27.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by elsa.codelab.cz (Postfix) with ESMTPSA id EB85BD7885; Tue, 21 Feb 2023 20:24:52 +0100 (CET) Message-ID: Date: Tue, 21 Feb 2023 20:24:52 +0100 List-Id: Technical discussions relating to FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-hackers List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-hackers@freebsd.org MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:102.0) Gecko/20100101 Thunderbird/102.7.1 Subject: Re: keeping old php74 in poudriere Content-Language: cs-Cestina, en-US To: freebsd-hackers@freebsd.org References: From: Miroslav Lachman <000.fbsd@quip.cz> Cc: void@f-m.fm In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4PLq4K5lMnz41S4 X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:42000, ipnet:94.124.104.0/21, country:CZ] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-ThisMailContainsUnwantedMimeParts: N On 21/02/2023 19:16, void wrote: > basically i need to keep php74 and all the extensions for a machine > I have to look after. Would the correct approach be to use an overlay? > If this is the correct approach, do I need to: > > 1. make a ports tree that has php74 etc in it, such as 2202Q4, and then: > > [a] remove the whole tree apart from the relevant ports > [b] as [a] but also remove things at the top level like Mk/* > [c] keep the whole 2022Q4 tree, and use that as the overlay. > [d] if [c] then how would the overlay be referenced? From the top of the > tree, or does there need to be one overlay for each port? > > 2. not use an overlay but to use some other method? It depends on how long you will to support it and if you just want to build fixes for vulnerable ports or you want to have everything new except PHP 7.4. I needed to keep PHP 5.6 in the past so I forked the latest ports tree with PHP 5.6 and merged fixes for individual ports from time to time (like newer version of Apache, fixed version of cURL etc.). This works well for a relatively long time. If you need everything new and just an old PHP 7.4, you can use overlays. Overlay directory will contain only the ports you want to add (and probably Mk/bsd.default-versions.mk + Mk/Uses/php.mk The overlay directory must be registered ports tree in poudriere so created it with command poudriere ports -c -p php74_overlay -f /poudriere/ports/php74_overlay -m null Then you will need to copy each port (PHP extension) you want to keep building, eg.: archivers/php74-phar archivers/php74-zip converters/php74-iconv converters/php74-mbstring databases/php74-mysqli databases/php74-pdo databases/php74-pdo_mysql devel/php-composer2 devel/php74-gettext devel/php74-intl devel/php74-readline devel/php74-tokenizer ftp/php74-curl ftp/php74-ftp lang/php74 mail/php74-imap net/php74-sockets security/pecl-mcrypt security/pecl-ssh2 www/php74-opcache www/php74-session Then you can bulk build everything you have listed in "php74" (you can name the file different). Use you correct names for -j, -z and -p. This will work in my environment where jail is named 12_3_amd64 and ports tree is current quarterly ~ 2023Q1 poudriere bulk -j 12_3_amd64 -z php74 -p 2023Q1 -f /usr/local/etc/poudriere.d/pkglists/php74 -O php74_overlay I didn't tested this setup with PHP 7.4 but used something like this with different version of PHP 8.1 than what was in ports tree. Kind regards Miroslav Lachman