Date: Tue, 9 May 2017 03:52:02 +0000 (UTC) From: Bryan Drewery <bdrewery@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r440469 - in head/devel/ccache: . files Message-ID: <201705090352.v493q2oL020625@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: bdrewery Date: Tue May 9 03:52:02 2017 New Revision: 440469 URL: https://svnweb.freebsd.org/changeset/ports/440469 Log: Fix ccache-memcached-static build with libmemcached+sasl support. Now that libmemcached supports/requires sasl, we must link it and its dependencies in. Use an awful hack due to the lack of sane pkgconf files. Modified: head/devel/ccache/Makefile head/devel/ccache/files/extra-patch-memcached-configure.ac Modified: head/devel/ccache/Makefile ============================================================================== --- head/devel/ccache/Makefile Tue May 9 03:37:22 2017 (r440468) +++ head/devel/ccache/Makefile Tue May 9 03:52:02 2017 (r440469) @@ -43,6 +43,8 @@ MEMCACHED_LIB_DEPENDS= libmemcached.so: MEMCACHED_LDFLAGS= -L${LOCALBASE}/lib MEMCACHED_CFLAGS= -I${LOCALBASE}/include +STATIC_CONFIGURE_ENABLE= static + .if defined(WITH_CCACHE_BUILD) && empty(OPTIONS_SLAVE:MMEMCACHED) && \ !defined(NO_CCACHE_DEPEND) # Don't allow autoreconf. We want no dependencies on this to keep @@ -59,8 +61,6 @@ NO_CCACHE_DEPEND= yes OPTIONS_SUB= yes -STATIC_LDFLAGS= -static - .include <bsd.port.pre.mk> . if ${COMPILER_TYPE} == clang Modified: head/devel/ccache/files/extra-patch-memcached-configure.ac ============================================================================== --- head/devel/ccache/files/extra-patch-memcached-configure.ac Tue May 9 03:37:22 2017 (r440468) +++ head/devel/ccache/files/extra-patch-memcached-configure.ac Tue May 9 03:52:02 2017 (r440469) @@ -1,5 +1,5 @@ ---- configure.ac.orig 2017-03-09 12:57:19.209816000 -0800 -+++ configure.ac 2017-03-09 13:00:24.478539000 -0800 +--- configure.ac.orig 2017-05-08 20:36:24.922407000 -0700 ++++ configure.ac 2017-05-08 20:39:41.725107000 -0700 @@ -28,6 +28,10 @@ AC_PROG_CC_C99 if test "$ac_cv_prog_cc_c99" = no; then AC_MSG_ERROR(cannot find a C99-compatible compiler) @@ -11,7 +11,7 @@ AC_PROG_CPP AC_PROG_INSTALL -@@ -97,6 +101,9 @@ AC_ARG_ENABLE(memcached, +@@ -97,19 +101,36 @@ AC_ARG_ENABLE(memcached, [AS_HELP_STRING([--enable-memcached], [enable memcached as a cache backend])]) @@ -20,9 +20,34 @@ +AC_LANG(C++) dnl enable-memcached: Check if -lmemcached is needed. if test x${enable_memcached} != x; then - if test x${enable_static} != x; then -@@ -110,6 +117,7 @@ if test x${enable_memcached} != x; then - ]) +- if test x${enable_static} != x; then ++ if false && test x${enable_static} != x; then + AC_CHECK_LIB(stdc++, __gxx_personality_v0,[]) + fi + AC_CHECK_LIB(pthread, pthread_once) +- AC_CHECK_LIB(memcached, memcached,[],[ +- echo ' WARNING: recent version libmemcached not found' +- echo ' please install libmemcached > 1.0 with development files' +- exit 1 +- ]) ++ if test x${enable_static} != x; then ++ AC_CHECK_LIB(sasl2, sasl_version, ac_cv_have_libsasl2=yes, ++ ac_cv_have_libsasl2=no, -lcrypto -lopie -lmd) ++ fi ++ if test x$ac_cv_have_libsasl2 = xyes; then ++ AC_CHECK_LIB(memcached, memcached,[],[ ++ echo ' WARNING: recent version libmemcached not found' ++ echo ' please install libmemcached > 1.0 with development files' ++ exit 1 ++ ], -lsasl2 -lcrypto -lopie -lmd) ++ extra_ldflags="${extra_ldflags} -lcrypto -lopie -lmd" ++ else ++ AC_CHECK_LIB(memcached, memcached,[],[ ++ echo ' WARNING: recent version libmemcached not found' ++ echo ' please install libmemcached > 1.0 with development files' ++ exit 1 ++ ]) ++ fi ccache_memcached='CCACHE_MEMCACHED=1 ' fi +AC_LANG(C)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201705090352.v493q2oL020625>