Date: Fri, 15 Apr 2016 17:18:27 +0000 (UTC) From: Adam Weinberger <adamw@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-branches@freebsd.org Subject: svn commit: r413355 - in branches/2016Q2/databases/tokyocabinet: . files Message-ID: <201604151718.u3FHIRoA012165@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: adamw Date: Fri Apr 15 17:18:26 2016 New Revision: 413355 URL: https://svnweb.freebsd.org/changeset/ports/413355 Log: MFH: r413150 r413151 Fix build, install, and package in multiple situations, and use OPTIONS helpers to do so. 1) FASTEST option build fails because -fforce-addr doesn't exist, so just remove it from CFLAGS. 2) disabling SHARED broke build The post-install, as well as the plist, never handled the case when SHARED was disabled. By using OPTIONS_SUB and post-install-SHARED-on, it now works. 3) DEBUG and LZMA were incompatible Building with debugging symbols against the external liblzma from ports caused the build to fail. Mark these as incompatible with each other. 4) PROFILE prevents .so from being built Building with profiling enabled disables shared objects from being built, so simply mark these as mutually exclusive. 5) The extra patching for the DOCS option is not needed, so just remove that whole business. It would be advisable to have better descriptions for the LZMA and LZO options, because lzma and lzo support are still enabled with those options deselected: it just uses the libraries from base instead. Approved by: ports-secteam (junovitch) Deleted: branches/2016Q2/databases/tokyocabinet/files/ Modified: branches/2016Q2/databases/tokyocabinet/Makefile branches/2016Q2/databases/tokyocabinet/pkg-plist Directory Properties: branches/2016Q2/ (props changed) Modified: branches/2016Q2/databases/tokyocabinet/Makefile ============================================================================== --- branches/2016Q2/databases/tokyocabinet/Makefile Fri Apr 15 16:46:24 2016 (r413354) +++ branches/2016Q2/databases/tokyocabinet/Makefile Fri Apr 15 17:18:26 2016 (r413355) @@ -17,8 +17,12 @@ GNU_CONFIGURE= yes USES= gmake USE_LDCONFIG= yes +PORTDOCS= * + OPTIONS_DEFINE= DEBUG DEVEL FASTEST LZMA LZO PTHREAD PROFILE SHARED SWAB UYIELD DOCS OPTIONS_DEFAULT= PTHREAD SHARED +OPTIONS_SUB= yes + DEBUG_DESC= Debugging support DEVEL_DESC= Development build FASTEST_DESC= Fastest run @@ -30,51 +34,32 @@ SHARED_DESC= Shared build SWAB_DESC= Swapping byte-orders build UYIELD_DESC= Detecting race conditions -.include <bsd.port.options.mk> +DEBUG_CONFIGURE_ENABLE= debug +DEBUG_PREVENTS= LZMA + +DEVEL_CONFIGURE_ENABLE= devel + +FASTEST_CONFIGURE_ENABLE= fastest -.if ${PORT_OPTIONS:MDOCS} -PORTDOCS= * -.else -EXTRA_PATCHES= ${FILESDIR}/extra-patch-Makefile.in -.endif - -.if ${PORT_OPTIONS:MDEBUG} -CONFIGURE_ARGS+= --enable-debug -.endif -.if ${PORT_OPTIONS:MDEVEL} -CONFIGURE_ARGS+= --enable-devel -.endif -.if ${PORT_OPTIONS:MFASTEST} -CONFIGURE_ARGS+= --enable-fastest -.endif # to not confuse with system liblzma -.if ${PORT_OPTIONS:MLZMA} -CONFIGURE_ARGS+= --enable-exlzma -LIB_DEPENDS+= liblzma.so.1:archivers/lzmalib -.else -CONFIGURE_ARGS+= --disable-exlzma -.endif -.if ${PORT_OPTIONS:MLZO} -CONFIGURE_ARGS+= --enable-exlzo -LIB_DEPENDS+= liblzo2.so:archivers/lzo2 -.else -CONFIGURE_ARGS+= --disable-exlzo -.endif -.if ! ${PORT_OPTIONS:MPTHREAD} -CONFIGURE_ARGS+= --disable-pthread -.endif -.if ${PORT_OPTIONS:MPROFILE} -CONFIGURE_ARGS+= --enable-profile -.endif -.if ! ${PORT_OPTIONS:MSHARED} -CONFIGURE_ARGS+= --disable-shared -.endif -.if ${PORT_OPTIONS:MSWAB} -CONFIGURE_ARGS+= --enable-swab -.endif -.if ${PORT_OPTIONS:MUYIELD} -CONFIGURE_ARGS+= --enable-uyield -.endif +LZMA_CONFIGURE_ENABLE= exlzma +LZMA_LIB_DEPENDS= liblzma.so.1:archivers/lzmalib +LZMA_PREVENTS= DEBUG + +LZO_CONFIGURE_ENABLE= exlzo +LZO_LIB_DEPENDS= liblzo2.so:archivers/lzo2 + +PTHREAD_CONFIGURE_ENABLE= pthread + +PROFILE_CONFIGURE_ENABLE= profile +PROFILE_PREVENTS= SHARED + +SHARED_CONFIGURE_ENABLE= shared +SHARED_PREVENTS= PROFILE + +SWAB_CONFIGURE_ENABLE= swab + +UYIELD_CONFIGURE_ENABLE= uyield SHLIB_VER= 9.11.0 SHLIB_VER_MAJ= 9 @@ -88,8 +73,13 @@ post-patch: -e 's|@datarootdir@|@datarootdir@/doc|' \ ${WRKSRC}/Makefile.in +post-patch-FASTEST-on: + ${REINPLACE_CMD} -e 's|-fforce-addr||' ${WRKSRC}/configure + post-install: - ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/* ${STAGEDIR}${PREFIX}/lib/*.so \ - ${STAGEDIR}${PREFIX}/libexec/tcawmgr.cgi + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/* ${STAGEDIR}${PREFIX}/libexec/tcawmgr.cgi + +post-install-SHARED-on: + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/*.so .include <bsd.port.mk> Modified: branches/2016Q2/databases/tokyocabinet/pkg-plist ============================================================================== --- branches/2016Q2/databases/tokyocabinet/pkg-plist Fri Apr 15 16:46:24 2016 (r413354) +++ branches/2016Q2/databases/tokyocabinet/pkg-plist Fri Apr 15 17:18:26 2016 (r413355) @@ -23,9 +23,9 @@ include/tchdb.h include/tcutil.h include/tctdb.h lib/libtokyocabinet.a -lib/libtokyocabinet.so -lib/libtokyocabinet.so.%%SHLIB_VER_MAJ%% -lib/libtokyocabinet.so.%%SHLIB_VER%% +%%SHARED%%lib/libtokyocabinet.so +%%SHARED%%lib/libtokyocabinet.so.%%SHLIB_VER_MAJ%% +%%SHARED%%lib/libtokyocabinet.so.%%SHLIB_VER%% libdata/pkgconfig/tokyocabinet.pc libexec/tcawmgr.cgi man/man1/tcamgr.1.gz
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201604151718.u3FHIRoA012165>