Date: Sat, 3 May 2014 23:59:39 +0200 (CEST) From: Tijl Coosemans <tijl@FreeBSD.org> To: FreeBSD-gnats-submit@freebsd.org Subject: ports/189323: [patch] textproc/flex: make libfl_pic.a actually pic Message-ID: <201405032159.s43Lxd50082426@kalimero.tijl.coosemans.org> Resent-Message-ID: <201405032200.s43M00xk016509@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 189323 >Category: ports >Synopsis: [patch] textproc/flex: make libfl_pic.a actually pic >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: Sat May 03 22:00:00 UTC 2014 >Closed-Date: >Last-Modified: >Originator: Tijl Coosemans >Release: FreeBSD 11.0-CURRENT i386 >Organization: >Environment: >Description: Currently libfl_pic.a is compiled as a regular static library without -fpic so it is exactly the same as libfl.a. The attached patch modifies Makefile.am to add the -prefer-pic libtool flag. It also adds the --tag=disable-shared flag so a shared library is never built (it would be the same as libfl.so). This requires running automake which requires aclocal which in turn implies autoconf and autoheader. The RANLIB patching in post-patch is removed because it has no effect. The "tests" patching has been included in the Makefile.am patch because automake complains about the trailing backslash otherwise. The MAKEINFO patching is handled in CONFIGURE_ENV. This will be used to fix a problem in devel/libmatheval: https://redports.org/buildarchive/20140503201200-15078/ https://redports.org/buildarchive/20140503214120-38210/ Redports: https://redports.org/buildarchive/20140503214000-47181/ >How-To-Repeat: >Fix: --- flex.patch begins here --- Index: textproc/flex/Makefile =================================================================== --- textproc/flex/Makefile (revision 352934) +++ textproc/flex/Makefile (working copy) @@ -2,6 +2,7 @@ PORTNAME= flex PORTVERSION= 2.5.39 +PORTREVISION= 1 CATEGORIES= textproc MASTER_SITES= SF/${PORTNAME} @@ -12,11 +13,13 @@ BUILD_DEPENDS= help2man:${PORTSDIR}/misc gm4:${PORTSDIR}/devel/m4 RUN_DEPENDS= gm4:${PORTSDIR}/devel/m4 -USES= bison gmake tar:bzip2 +USES= bison gmake libtool:keepla tar:bzip2 +USE_AUTOTOOLS= aclocal autoconf autoheader automake +ACLOCAL_ARGS= -I m4 GNU_CONFIGURE= yes # install flex header to its own dir to avoid conflict with system flex. CONFIGURE_ARGS= --includedir=${PREFIX}/include/flex --disable-shared -CONFIGURE_ENV= M4=${LOCALBASE}/bin/gm4 +CONFIGURE_ENV= M4=${LOCALBASE}/bin/gm4 MAKEINFO="makeinfo --no-split" INSTALL_TARGET= install-strip INFO= flex @@ -27,12 +30,6 @@ NLS_USES= gettext iconv NLS_CONFIGURE_ENABLE= nls post-patch: .SILENT - ${REINPLACE_CMD} -Ee 's/tests//' \ - -e 's/^([[:space:]]*)\$$\(RANLIB\) ([^ ;]*)/\1chmod u+w \2;&/' \ - -e '/echo.*RANLIB/,+1d' \ - ${WRKSRC}/Makefile.in - ${REINPLACE_CMD} -e 's/@MAKEINFO@/& --no-split/g' \ - ${WRKSRC}/doc/Makefile.in ${RM} -f ${WRKSRC}/doc/*.info* .include <bsd.port.mk> Index: textproc/flex/files/patch-Makefile.am =================================================================== --- textproc/flex/files/patch-Makefile.am (revision 0) +++ textproc/flex/files/patch-Makefile.am (working copy) @@ -0,0 +1,21 @@ +--- Makefile.am.orig 2014-03-26 13:46:44.000000000 +0100 ++++ Makefile.am 2014-05-03 23:29:10.000000000 +0200 +@@ -79,6 +79,8 @@ + libmain.c \ + libyywrap.c + ++libfl_pic_la_CFLAGS = -prefer-pic ++libfl_pic_la_LIBTOOLFLAGS = --tag=disable-shared + libfl_pic_la_LDFLAGS = -no-undefined -version-info @SHARED_VERSION_INFO@ + + noinst_HEADERS = \ +@@ -119,8 +121,7 @@ + . \ + doc \ + examples \ +- po \ +- tests ++ po + + localedir = $(datadir)/locale + AM_CPPFLAGS = -DLOCALEDIR=\"$(localedir)\" -I$(top_srcdir)/intl Property changes on: textproc/flex/files/patch-Makefile.am ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property --- flex.patch ends here --- >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201405032159.s43Lxd50082426>