Date: Thu, 29 Jul 2021 11:18:19 +0200 From: Stefan Esser <se@freebsd.org> To: Baptiste Daroussin <bapt@FreeBSD.org> Cc: freebsd-hackers@freebsd.org, Craig Leres <leres@freebsd.org> Subject: Re: pkg/poudriere: dangling symlink to pkg.pkg.sig [inline patch fixed] Message-ID: <6c707473-9e1d-8ca9-6cd7-af21774a9f74@freebsd.org> In-Reply-To: <20210729074107.yuv6a4tcj55wpbvt@aniel.nours.eu> References: <2adca193-dbeb-8b5a-47a6-9e40e56ee80d@freebsd.org> <20210729074107.yuv6a4tcj55wpbvt@aniel.nours.eu>
next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --tJ5uNZZEx7gEmGulTrx6qvSjoUSwCakK5 Content-Type: multipart/mixed; boundary="pBVNSJMH52CyARz4dCSLASjP4ZZun32lP"; protected-headers="v1" From: Stefan Esser <se@freebsd.org> To: Baptiste Daroussin <bapt@FreeBSD.org> Cc: freebsd-hackers@freebsd.org, Craig Leres <leres@freebsd.org> Message-ID: <6c707473-9e1d-8ca9-6cd7-af21774a9f74@freebsd.org> Subject: Re: pkg/poudriere: dangling symlink to pkg.pkg.sig [inline patch fixed] References: <2adca193-dbeb-8b5a-47a6-9e40e56ee80d@freebsd.org> <20210729074107.yuv6a4tcj55wpbvt@aniel.nours.eu> In-Reply-To: <20210729074107.yuv6a4tcj55wpbvt@aniel.nours.eu> --pBVNSJMH52CyARz4dCSLASjP4ZZun32lP Content-Type: multipart/mixed; boundary="------------E582BDCAAC691F7F19DCCA94" Content-Language: en-US This is a multi-part message in MIME format. --------------E582BDCAAC691F7F19DCCA94 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable [Resending, the inline diff had significant white-space issues ...] Am 29.07.21 um 09:41 schrieb Baptiste Daroussin: > On Tue, Jul 27, 2021 at 02:05:14PM -0700, Craig Leres wrote: >> >> For the last few days, approximately corresponding to when the pkg por= t >> upgraded to 1.17.0, the poudriere build process has been creating a da= ngling >> symlink from pkg.txz.sig to pkg.pkg.sig. Posting an issue to >> github.com/freebsd/pkg did not prove useful; does anyone understand wh= at >> broke (and how to fix it)? >> >> I ran into this because I use a cron job to archive poudriere build tr= ees; >> the job does a diff -r of the latest pkg tree vs. the most recent arch= ived >> tree (to decide if the new tree is worth archiving). >> >> Craig >> > I told you to have a look at the commit in the ports tree in the github= issue, > which apparently you did not. >=20 > In particular: > https://cgit.freebsd.org/ports/commit/Mk/bsd.port.mk?id=3Dec2764d5ec493= 3f52cb0718663f60f1e1b1eed7f >=20 > This is not done by pkg, so this is not a pkg bug, neither done by poud= riere, > this is done by the ports tree, this is a transition so that when someo= ne is > signing his own repo, he has valid signature for FreeBSD 12.2 and 11.4 = which are > the 2 systems which do not know about .pkg extention for the bootstrap = of pkg. >=20 > The safest way to do that was to create a dead symlink so the when pkg.= pkg.sig > appears the symlink is not dead anymore and bootstrap signature can be = checked. >=20 > 1 improvements that can be done, (I don't have time to do it right now:= limit > this to only be created on FreeBSD 12 and 11, limit it to cluster packa= ge > building) The attached patch limits the creation of the symlink to FreeBSD versions before 13. Inline version for easy review (white-space might be damaged): diff --git a/Mk/bsd.port.mk b/Mk/bsd.port.mk index c9532fa5af2e..1a942e8abc0c 100644 --- a/Mk/bsd.port.mk +++ b/Mk/bsd.port.mk @@ -3461,7 +3461,10 @@ ${PKGLATESTFILE}: ${PKGFILE} ${PKGLATESTREPOSITORY= } ${INSTALL} -l rs ${PKGFILE} ${PKGLATESTFILE} .if !defined(_PKG_TRANSITIONING_TO_NEW_EXT) -_EXTRA_PACKAGE_TARGET_DEP+=3D ${PKGOLDLATESTFILE} ${PKGOLDSIGFILE} +_EXTRA_PACKAGE_TARGET_DEP+=3D ${PKGOLDLATESTFILE} +.if ${OSVERSION} < 1300000 +_EXTRA_PACKAGE_TARGET_DEP+=3D ${PKGOLDSIGFILE} +.endif ${PKGOLDLATESTFILE}: ${PKGOLDFILE} ${PKGLATESTREPOSITORY} ${INSTALL} -l rs ${PKGOLDFILE} ${PKGOLDLATESTFILE} Do you approve the commit? Regards, STefan --------------E582BDCAAC691F7F19DCCA94 Content-Type: text/plain; charset=UTF-8; x-mac-type="0"; x-mac-creator="0"; name="pkg-sig.diff" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="pkg-sig.diff" ZGlmZiAtLWdpdCBhL01rL2JzZC5wb3J0Lm1rIGIvTWsvYnNkLnBvcnQubWsKaW5kZXggYzk1 MzJmYTVhZjJlLi4xYTk0MmU4YWJjMGMgMTAwNjQ0Ci0tLSBhL01rL2JzZC5wb3J0Lm1rCisr KyBiL01rL2JzZC5wb3J0Lm1rCkBAIC0zNDYxLDcgKzM0NjEsMTAgQEAgJHtQS0dMQVRFU1RG SUxFfTogJHtQS0dGSUxFfSAke1BLR0xBVEVTVFJFUE9TSVRPUll9CiAJJHtJTlNUQUxMfSAt bCBycyAke1BLR0ZJTEV9ICR7UEtHTEFURVNURklMRX0KIAogLmlmICFkZWZpbmVkKF9QS0df VFJBTlNJVElPTklOR19UT19ORVdfRVhUKQotX0VYVFJBX1BBQ0tBR0VfVEFSR0VUX0RFUCs9 CSR7UEtHT0xETEFURVNURklMRX0gJHtQS0dPTERTSUdGSUxFfQorX0VYVFJBX1BBQ0tBR0Vf VEFSR0VUX0RFUCs9CSR7UEtHT0xETEFURVNURklMRX0KKy5pZiAke09TVkVSU0lPTn0gPCAx MzAwMDAwCitfRVhUUkFfUEFDS0FHRV9UQVJHRVRfREVQKz0JJHtQS0dPTERTSUdGSUxFfQor LmVuZGlmCiAKICR7UEtHT0xETEFURVNURklMRX06ICR7UEtHT0xERklMRX0gJHtQS0dMQVRF U1RSRVBPU0lUT1JZfQogCSR7SU5TVEFMTH0gLWwgcnMgJHtQS0dPTERGSUxFfSAke1BLR09M RExBVEVTVEZJTEV9Cg== --------------E582BDCAAC691F7F19DCCA94-- --pBVNSJMH52CyARz4dCSLASjP4ZZun32lP-- --tJ5uNZZEx7gEmGulTrx6qvSjoUSwCakK5 Content-Type: application/pgp-signature; name="OpenPGP_signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="OpenPGP_signature" -----BEGIN PGP SIGNATURE----- wsB5BAABCAAjFiEEo3HqZZwL7MgrcVMTR+u171r99UQFAmECclsFAwAAAAAACgkQR+u171r99UT9 RwgAuPjbRSkSHGXqB6Am9mDB10VtOuS+DgRwWYmrFXCOzPoCIVoJ27MkS3eUCIY9+AAEimHvtSCL +sWFTPng/Ry/lDmczkCViQd3U7m3BUvwtFQn/kaj7+98yYEd5MK/o2f1RlYU3fPrp5fMwTEfgeSG ZveYXvq89U4cWi0YlDuuM5cVJNPfcvQGMCO+BLcu4m+3ZkHmO7s43yttqc9RZ4VwRhcGS6k8DyRS yiw+r0r1LmnqcK/DenGZXRCgB9l03E4SsQe4b8YxUdTnqP2WnNUnTjhyvIe5T9Em/sIZVIxa6A6k 1eJL6MxgAjtxOUDH7RmrhO0AXX3EhxxNZm0n+SNngQ== =oejC -----END PGP SIGNATURE----- --tJ5uNZZEx7gEmGulTrx6qvSjoUSwCakK5--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?6c707473-9e1d-8ca9-6cd7-af21774a9f74>