Date: Sun, 9 Jul 2006 19:00:41 GMT From: Anish Mistry <amistry@am-productions.biz> To: freebsd-ports-bugs@FreeBSD.org Subject: Re: ports/99957: libgnugetopt incompatibility Message-ID: <200607091900.k69J0f5h090062@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR ports/99957; it has been noted by GNATS. From: Anish Mistry <amistry@am-productions.biz> To: bug-followup@freebsd.org, steinar@gmx.net Cc: Subject: Re: ports/99957: libgnugetopt incompatibility Date: Sun, 9 Jul 2006 14:59:52 -0400 --nextPart1322474.KUbSKAa4bO Content-Type: multipart/mixed; boundary="Boundary-01=_pIVsElxhiU/YlT3" Content-Transfer-Encoding: 7bit Content-Disposition: inline --Boundary-01=_pIVsElxhiU/YlT3 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Argh! I've attached a patch to fix the problem. Yes, I know what the=20 libgnugetopt Makefile says about the next time the port is updated,=20 but I don't have the time. We just need something so port=20 maintainers don't have to hack around this stupid problem every time=20 it crops up. http://am-productions.biz/docs/libgnugetopt.patch So now port maintainers will need to do the following to handle this=20 problem. =2Eif exists(${LOCALBASE}/include/getopt.h) BUILD_DEPENDS=3D libgnugetopt>1.2:${PORTSDIR}/devel/libgnugetopt =2Eendif Ideally we shouldn't really be checking for the getopt.h and instead=20 for libgnugetopt being installed then enforce the version dependency,=20 but I don't know how to do that. =2D-=20 Anish Mistry amistry@am-productions.biz AM Productions http://am-productions.biz/ --Boundary-01=_pIVsElxhiU/YlT3 Content-Type: text/x-diff; charset="us-ascii"; name="libgnugetopt.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="libgnugetopt.patch" diff -ruN libgnugetopt.orig/Makefile libgnugetopt/Makefile =2D-- libgnugetopt.orig/Makefile Sun Jul 9 14:15:22 2006 +++ libgnugetopt/Makefile Sun Jul 9 14:28:51 2006 @@ -13,6 +13,7 @@ =20 PORTNAME=3D libgnugetopt PORTVERSION=3D 1.2 +PORTREVISION=3D 1 CATEGORIES=3D devel MASTER_SITES=3D ${MASTER_SITE_LOCAL} MASTER_SITE_SUBDIR=3D lioux diff -ruN libgnugetopt.orig/files/patch-getopt.h libgnugetopt/files/patch-g= etopt.h =2D-- libgnugetopt.orig/files/patch-getopt.h Wed Dec 31 19:00:00 1969 +++ libgnugetopt/files/patch-getopt.h Sun Jul 9 14:15:48 2006 @@ -0,0 +1,11 @@ +--- getopt.h.orig Sun Jul 9 14:05:07 2006 ++++ getopt.h Sun Jul 9 14:14:23 2006 +@@ -111,7 +111,7 @@ + errors, only prototype getopt for the GNU C library. */ + extern int getopt (int argc, char *const *argv, const char *shortopts); + #else /* not __GNU_LIBRARY__ */ +-# if !defined (HAVE_DECL_GETOPT) ++# if !defined (HAVE_DECL_GETOPT) && !defined(__cplusplus) + extern int getopt (); + # endif + #endif /* __GNU_LIBRARY__ */ --Boundary-01=_pIVsElxhiU/YlT3-- --nextPart1322474.KUbSKAa4bO Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.3 (FreeBSD) iD8DBQBEsVIwxqA5ziudZT0RAjxwAJ0by8oxIU0f+cdfWYWaT2fC1/mD4ACeI883 JC37U6HG2D5AmHUv0Xph8WU= =TZHQ -----END PGP SIGNATURE----- --nextPart1322474.KUbSKAa4bO--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200607091900.k69J0f5h090062>