Date: Thu, 2 Sep 2004 00:10:57 +0800 (CST) From: Yen-Ming Lee <leeym@utopia.leeym.com> To: FreeBSD-gnats-submit@FreeBSD.org Subject: ports/71250: change-request: add CPPFLAGS for USE_GETOPT_LONG Message-ID: <20040901161057.475C33EAD65@utopia.leeym.com> Resent-Message-ID: <200409011620.i81GKPLZ071595@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 71250 >Category: ports >Synopsis: change-request: add CPPFLAGS for USE_GETOPT_LONG >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Wed Sep 01 16:20:25 GMT 2004 >Closed-Date: >Last-Modified: >Originator: Yen-Ming Lee >Release: FreeBSD 5.2.1-RELEASE-p9 i386 >Organization: >Environment: System: FreeBSD utopia.leeym.com 5.2.1-RELEASE-p9 FreeBSD 5.2.1-RELEASE-p9 #167: Tue Jul 27 05:17:58 CST 2004 root@utopia.leeym.com:/usr/obj/usr/src/sys/UTOPIA i386 >Description: [This is a dirty-but-maybe-useful patch] Some ports in 5.x still depend on libgnugetopt because of getopt_long_only(3). However, the interfaces of getopt_long() and getopt_long_only() are identical. (Only the "long_only" fields of _getopt_internal() are different.) So, if we add CPPFLAGS=-Dgetopt_long_only=getopt_long, we can get rid of the dependency on devel/libgnugetopt. >How-To-Repeat: >Fix: --- bsd.port.mk.diff begins here --- Index: bsd.port.mk =================================================================== RCS file: /home/pcvs/ports/Mk/bsd.port.mk,v retrieving revision 1.497 diff -u -r1.497 bsd.port.mk --- bsd.port.mk 3 Aug 2004 19:03:58 -0000 1.497 +++ bsd.port.mk 1 Sep 2004 15:57:41 -0000 @@ -1361,6 +1361,9 @@ CPPFLAGS+= -I${LOCALBASE}/include LDFLAGS+= -L${LOCALBASE}/lib -lgnugetopt CONFIGURE_ENV+= CPPFLAGS="${CPPFLAGS}" LDFLAGS="${LDFLAGS}" +.else +CPPFLAGS+= -Dgetopt_long_only=getopt_long +CONFIGURE_ENV+= CPPFLAGS="${CPPFLAGS}" .endif .endif --- bsd.port.mk.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040901161057.475C33EAD65>