Date: Wed, 20 Mar 2002 07:50:04 -0800 (PST) From: Peter Pentchev <roam@ringlet.net> To: freebsd-ports@FreeBSD.org Subject: Re: ports/36133: djbdns-ipv6 port version numbering is broken Message-ID: <200203201550.g2KFo4m86957@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR ports/36133; it has been noted by GNATS. From: Peter Pentchev <roam@ringlet.net> To: Peter van Dijk <peter@dataloss.nl> Cc: bug-followup@FreeBSD.org Subject: Re: ports/36133: djbdns-ipv6 port version numbering is broken Date: Wed, 20 Mar 2002 17:44:38 +0200 --w7PDEPdKQumQfZlR Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Mar 20, 2002 at 12:55:22PM -0000, Peter van Dijk wrote: >=20 > >Number: 36133 > >Category: ports > >Synopsis: djbdns-ipv6 port version numbering is broken > >Originator: Peter van Dijk >=20 > ports tree cvsupped about 30 minutes ago :) >=20 > >Description: >=20 > When installing the djbdns port with WITH_IPV6 set, it installs itself > as 'djbdns-ipv6-1.05.b11_2'. pkg_version, however, thinks that the > port itself has -1.05_2 and considers this to be newer (pkg_version -c > snippet): >=20 > # djbdns-ipv6 > # needs updating (port has 1.05_2) > # > cd /usr/ports/net/djbdns > make clean && make && pkg_delete -f djbdns-ipv6-1.05.b11_2 Yep, I know. Of course, you can avoid it by placing a WITH_IPV6=3Dyes in the environment of the pkg_version process :) > >How-To-Repeat: >=20 > Install djbdns port with WITH_IPV6, then ask pkg_version about versions. >=20 > >Fix: > Put the b11 behind the _2, perhaps? Impossible - the _2 comes from PORTREVISION, the .b11 is part of PORTVERSION; PORTREVISION and PORTEPOCH are tackled at the end of PKGNAME and are unconditionally placed after PORTVERSION. The real fix (well, maybe a workaround for pkg_version(1)) is to invoke pkg_version(1) with the same environment settings used in building the port. <plug> This can be achieved in a simple way by using a patch to make(1) making it invoke an environment processor for selected directories; one way to do it is install the sysutils/penv port, then run: $ cd /usr/ports/net/djbdns $ penv -c mkdir $ penv -S WITH_IPV6=3Dyes $ MAKEENVPROC=3D'penv -L'; MAKEENVDIR=3D/ports/; export MAKEENVPROC MAKEENV= DIR $ pkg_version The patch to make make(1) invoke MAKEENVPROC for the directories matching MAKEENVDIR may be found at: http://people.FreeBSD.org/~roam/bsd/makeenvproc.patch </plug> Of course, another way would be to avoid pkg_version(1) and use portupgrade's portversion(1) or similar utility, which (I think) may be configured so as to keep track of env var settings when determining the package name or port version. G'luck, Peter --=20 Peter Pentchev roam@ringlet.net roam@FreeBSD.org PGP key: http://people.FreeBSD.org/~roam/roam.key.asc Key fingerprint FDBA FD79 C26F 3C51 C95E DF9E ED18 B68D 1619 4553 If the meanings of 'true' and 'false' were switched, then this sentence wou= ldn't be false. --w7PDEPdKQumQfZlR Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (FreeBSD) Comment: For info see http://www.gnupg.org iEYEARECAAYFAjyYrmYACgkQ7Ri2jRYZRVOmPwCbBQoBSNHIC0LZDs1q4tIFGvuT M6YAoJcWQ81MWvd5xjsq+7ASGAroahJR =9sAg -----END PGP SIGNATURE----- --w7PDEPdKQumQfZlR-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200203201550.g2KFo4m86957>