- Convert to new options framework - Fixes build without X11 [ports/168795]
Previous patch missed the OPTIONS_DEFAULT= IPV6. Not sure if it is intended to have X11 as the default. I left it out of my patch. Attached adds IPV6 to default.
Responsible Changed From-To: freebsd-ports-bugs->sunpoet Over to maintainer (via the GNATS Auto Assign Tool)
Patch tested. It effectively fixes ports/168795
sunpoet pointed out that the previous patches did not properly set X11 as the default for net/mtr. This patch does. While properly keeping it default off for net/mtr-nox11. I also considered some other checks such as ${.CURDIR], ${PKGNAMESUFFIX}. I ended up checking for !defined(WITHOUT_X11) as this avoids needing to updating net/mtr-nox11 and matches how it worked before. Regards, Bryan Drewery
State Changed From-To: open->feedback Please confirm if the patch [1] for new options framework works for you both in net/mtr and net/mtr-nox11. [1] http://people.freebsd.org/~sunpoet/mtr.patch http://www.freebsd.org/cgi/query-pr.cgi?pr=168808 Date: Sat, 23 Jun 2012 10:29:36 -0500
On Sat, Jun 23, 2012 at 11:29 PM, Bryan Drewery <bryan@shatow.net> wrote: > It mostly works. > > 1. mtr_UNSET= is overriding the user's own settings due to = instead of > +=. This is a user-only setting, the OPTIONS_EXCLUDE seems to be enough. > You can see this by adding mtr_UNSET=IPV6 in /etc/make.conf and building > mtr-nox11 Hi, I agree that the patch is not a good solution but it works. OPTIONS_EXCLUDE is not enough. It only *hides* the option from the dialog but does not actually unset the option. You may remove mtr_UNSET line and /var/db/ports/mtr/options then try "make build-depends-list" or "make run-depends-list". The invisible X11 still exists. > 2. Missing tabs on the OPTIONS_DEFAULT and OPTIONS_DEFINE lines I meant not to add tab after OPTIONS_DEFAULT= as it has same length as OPTION_DEFINE=<tab>. Regards, sunpoet > Regards, > Bryan Drewery
On 6/23/2012 12:51 PM, Sunpoet Po-Chuan Hsieh wrote: > I agree that the patch is not a good solution but it works. > OPTIONS_EXCLUDE is not enough. Ok well at least make it a += so it does not override the user's own setting if they have unset IPV6. Regards, Bryan Drewery
On Sun, Jun 24, 2012 at 1:56 AM, Bryan Drewery <bryan@shatow.net> wrote: > On 6/23/2012 12:51 PM, Sunpoet Po-Chuan Hsieh wrote: >> I agree that the patch is not a good solution but it works. >> OPTIONS_EXCLUDE is not enough. > > Ok well at least make it a += so it does not override the user's own > setting if they have unset IPV6. It makes no difference here and we should not use +=. Port Makefile is processed before user's option file. You can test it by yourself with the following steps: 1. Remove WITHOUT_X11 from /etc/make.conf 2. Remove net/mtr and net/mtr-nox11 lines from /usr/local/etc/ports.conf 3. 'make config' and unset both IPV6 and X11 (to generate option file) 4. In net/mtr-nox11, 'make -V CONFIGURE_ARGS -V CATEGORIES' The result should be: --disable-ipv6 --without-gtk --prefix=/usr/local ${_LATE_CONFIGURE_ARGS} net These two lines indicate the IPV6 options is off (ref: net/mtr/Makefile line 31 to 36). Regards, sunpoet > Regards, > Bryan Drewery
On 6/23/2012 1:30 PM, Sunpoet Po-Chuan Hsieh wrote: > It makes no difference here and we should not use +=. Port Makefile is > processed before user's option file. Wrong. Using = blows away the user's options. /usr/ports/net/mtr-nox11# grep mtr /etc/make.conf mtr_UNSET= IPV6 /usr/ports/net/mtr-nox11# grep UNSET Makefile mtr_UNSET= X11 /usr/ports/net/mtr-nox11# rm -rf /var/db/ports/mtr /usr/ports/net/mtr-nox11# make pretty-print-config +IPV6 It is showing IPV6 despite me having it *unset* in /etc/make.conf due to =. Changing to +=: /usr/ports/net/mtr-nox11# grep UNSET Makefile mtr_UNSET+= X11 /usr/ports/net/mtr-nox11# make pretty-print-config -IPV6 Now it correctly recognizes my mtr_UNSET=IPV6. Regards, Bryan Drewery
On Sun, Jun 24, 2012 at 2:39 AM, Bryan Drewery <bryan@shatow.net> wrote: > On 6/23/2012 1:30 PM, Sunpoet Po-Chuan Hsieh wrote: >> It makes no difference here and we should not use +=3D. Port Makefile is >> processed before user's option file. > > Wrong. Using =3D blows away the user's options. > > /usr/ports/net/mtr-nox11# grep mtr /etc/make.conf > mtr_UNSET=3D IPV6 > > /usr/ports/net/mtr-nox11# grep UNSET Makefile > mtr_UNSET=3D X11 > > > /usr/ports/net/mtr-nox11# rm -rf /var/db/ports/mtr > > /usr/ports/net/mtr-nox11# make pretty-print-config > +IPV6 > > It is showing IPV6 despite me having it *unset* in /etc/make.conf due to = =3D. > > Changing to +=3D: > > /usr/ports/net/mtr-nox11# grep UNSET Makefile > mtr_UNSET+=3D X11 > > /usr/ports/net/mtr-nox11# make pretty-print-config > -IPV6 > > Now it correctly recognizes my mtr_UNSET=3DIPV6. > > Regards, > Bryan Drewery OK, now I know what the problem is. Personally I use ports.conf (all options in one file) instead of option files and I do not set xxx_SET/xxx_UNSET in make.conf. Anyway, I have another solution which replaces mtr_UNSET=3DX11 by OPTIONS_FILE_UNSET=3DX11. It should respect mtr_SET/mtr_UNSET in make.conf correctly. Regards, sunepot --=20 =C2=A0 Sunpoet Po-Chuan Hsieh <sunpoet at sunpoet.net> <sunpoet at FreeBSD.= org> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 4096R/CC57E36B 8AD8 68F2 7D2B 0A10 7E9B = 8CC0 DC44 247E CC57 E36B =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 http://people.FreeBSD.org/~sunpoet/pgpkeys.txt
sunpoet 2012-07-04 09:55:12 UTC FreeBSD ports repository Modified files: net/mtr Makefile Log: - Convert to new options framework - Cosmetic change PR: ports/168795 [1], ports/168808 [2] Submitted by: Sayetsky Anton <vsjcfm@gmail.com> [1], Bryan Drewery <bryan@shatow.net> [2] Revision Changes Path 1.85 +7 -10 ports/net/mtr/Makefile _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
sunpoet 2012-07-04 09:55:42 UTC FreeBSD ports repository Modified files: net/mtr-nox11 Makefile Log: - Convert to new options framework PR: ports/168795 [1], ports/168808 [2] Submitted by: Sayetsky Anton <vsjcfm@gmail.com> [1], Bryan Drewery <bryan@shatow.net> [2] Revision Changes Path 1.4 +2 -1 ports/net/mtr-nox11/Makefile _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
State Changed From-To: feedback->closed Problem solved in the ports tree.