From owner-freebsd-ports@FreeBSD.ORG Tue Sep 16 16:05:14 2014 Return-Path: Delivered-To: ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 1E2B0F35; Tue, 16 Sep 2014 16:05:14 +0000 (UTC) Received: from c.mail.sonic.net (c.mail.sonic.net [64.142.111.80]) (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 EF1302F8; Tue, 16 Sep 2014 16:05:13 +0000 (UTC) Received: from comporellon.tachypleus.net (polaris.tachypleus.net [75.101.50.44]) (authenticated bits=0) by c.mail.sonic.net (8.14.9/8.14.9) with ESMTP id s8GG58Sj027110 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT); Tue, 16 Sep 2014 09:05:10 -0700 Message-ID: <54185FB4.6000403@freebsd.org> Date: Tue, 16 Sep 2014 09:05:08 -0700 From: Nathan Whitehorn User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.1.0 MIME-Version: 1.0 To: olli hauer Subject: Re: [Patch] Using MACHINE_ARCH identifiers in pkg References: <5383EEB6.6010703@freebsd.org> <538614AB.4070803@freebsd.org> <53ECCF7F.3040107@FreeBSD.org> <53ECD741.5090703@freebsd.org> <53ED1044.80302@gmx.de> <53ED110C.1040500@FreeBSD.org> <53ED1ED2.7050605@gmx.de> <53F2269D.20101@freebsd.org> <53F277F4.708@gmx.de> <53FCAF63.6030803@freebsd.org> In-Reply-To: <53FCAF63.6030803@freebsd.org> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Sonic-CAuth: UmFuZG9tSVajqSRlFMZd9Uxo4Tj2hauVFepIrUN7ZUeQ0zrgHxzYx81rTvspHr5tMub37+Oqwu7htTSIn+g3+0yq6zwgQ5Z4XE4oXrLc5Zs= X-Sonic-ID: C;jubQOrs95BGjkTZXoK8kYw== M;9KazO7s95BGjkTZXoK8kYw== X-Spam-Flag: No X-Sonic-Spam-Details: 0.0/5.0 by cerberusd Cc: ports@freebsd.org, Baptiste Daroussin , Warner Losh , Bryan Drewery X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Sep 2014 16:05:14 -0000 On 08/26/14 09:01, Nathan Whitehorn wrote: > On 08/18/14 15:02, olli hauer wrote: >> On 2014-08-18 18:15, Nathan Whitehorn wrote: >>> On 08/14/14 13:40, olli hauer wrote: >>>> On 2014-08-14 21:42, Bryan Drewery wrote: >>>>> On 8/14/2014 2:38 PM, olli hauer wrote: >>>>>> On 2014-08-14 17:35, Nathan Whitehorn wrote: >>>> ... >>>> >>>>> Something I've mentioned to Bapt a few times is that pkg needs a >>>>> way to >>>>> have a list of accepted ABI strings. Then we could add both the >>>>> old and >>>>> the new style as accepted (internally) so that old and new >>>>> repositories >>>>> will continue to work. >>>>> >>>> Ups, rollback is not possible after the client database was updated. >>>> >>>> Even by rollback and rebuild the package metadata the following >>>> error pops up. >>>> >>>> ~/pkg-static.old_ABI update -f >>>> Updating repository catalogue >>>> pkg-static: Repository str has a wrong packagesite, need to >>>> re-create database >>>> Fetching meta.txz: 100% of 584 B >>>> Fetching digests.txz: 100% of 43 kB >>>> Fetching packagesite.txz: 100% of 138 kB >>>> >>>> Adding new entries: 34% >>>> pkg-static: wrong architecture: FreeBSD:8:amd64 instead of >>>> freebsd:8:x86:64 >>>> >>>> pkg-static: repository str contains packages with wrong ABI: >>>> FreeBSD:8:amd64 >>>> Adding new entries: 100% >>>> pkg-static: Unable to update repository str >>> >>> Hm. I'm not sure how to handle this. There are two places that emit >>> hard errors in such cases: pkg-add, which is fine since we have a >>> workaround there, and here. The check is at line 446 of >>> libpkg/repo/binary/update.c (you can comment it out for testing). >>> For this one, there does not seem to be any good solution and we >>> need to find one since this is the same issue you ran into the >>> upgrade path. >>> >>> Here are the two options I see. They are similar to each other, and >>> we could do both for some time. >>> 1. Make an intermediate pkg that is otherwise unaltered but doesn't >>> have this check during updates and keep it in the tree for some >>> substantial length of time so most people have it by the time we >>> want upgrades to the new ABI strings. >>> 2. Set PKGNG_ALTABI globally on the ports tree for i386 and amd64 >>> for some period of time so that all built packages get the current >>> ABI identifiers rather than the new ones. >>> >>> Any preference here? Or other options? >> >> Hi Nathan, >> >> Your suggestion 2) could do the trick, at last for current ports. >> >> I will see if I can do some additional tests the next days, specially >> with mixed ABI strings in the packages. >> > > Did you have any chance to do the tests? I prepared a new version of > the patch at http://people.freebsd.org/~nwhitehorn/pkg-new-abi-v2.diff > that marks all built binary packages for i386 and amd64 with the > freebsd:*:x86:* identifiers and so should prevent the old version of > pkg from bailing on a repository with mixed ABI strings. Testing would > be much appreciated. > -Nathan I've made a third version of the patch that chases some recent updates to the ports tree and can be found at: http://people.freebsd.org/~nwhitehorn/pkg-new-abi-v3.diff Please let me know if you run into any difficulties. -Nathan