diff options
author | David Seifert <soap@gentoo.org> | 2021-08-05 19:18:00 +0200 |
---|---|---|
committer | David Seifert <soap@gentoo.org> | 2021-08-05 19:18:00 +0200 |
commit | 6c663213e94bd5fe139c8f4c095ed5564c616df4 (patch) | |
tree | ef4b01147eefed5aedd90eef294c07f452ff0310 /dev-libs/libmemcached | |
parent | dev-util/pkgconf: point live ebuild at github (diff) | |
download | gentoo-6c663213e94bd5fe139c8f4c095ed5564c616df4.tar.gz gentoo-6c663213e94bd5fe139c8f4c095ed5564c616df4.tar.bz2 gentoo-6c663213e94bd5fe139c8f4c095ed5564c616df4.zip |
dev-libs/libmemcached: update EAPI 5 -> 8
Signed-off-by: David Seifert <soap@gentoo.org>
Diffstat (limited to 'dev-libs/libmemcached')
4 files changed, 128 insertions, 18 deletions
diff --git a/dev-libs/libmemcached/files/continuum-1.0.18.patch b/dev-libs/libmemcached/files/continuum-1.0.18.patch index 296978044311..17a8afd7ff98 100644 --- a/dev-libs/libmemcached/files/continuum-1.0.18.patch +++ b/dev-libs/libmemcached/files/continuum-1.0.18.patch @@ -1,7 +1,5 @@ -diff --git libmemcached/memcached.cc libmemcached/memcached.cc -index 337f918..6e88c25 100644 ---- libmemcached/memcached.cc -+++ libmemcached/memcached.cc +--- a/libmemcached/memcached.cc ++++ b/libmemcached/memcached.cc @@ -285,6 +285,8 @@ void memcached_servers_reset(memcached_st *shell) { libmemcached_free(self, self->ketama.continuum); @@ -11,10 +9,8 @@ index 337f918..6e88c25 100644 memcached_instance_list_free(memcached_instance_list(self), self->number_of_hosts); memcached_instance_set(self, NULL, 0); -diff --git tests/libmemcached-1.0/all_tests.h tests/libmemcached-1.0/all_tests.h -index b4abe9d..f89f007 100644 ---- tests/libmemcached-1.0/all_tests.h -+++ tests/libmemcached-1.0/all_tests.h +--- a/tests/libmemcached-1.0/all_tests.h ++++ b/tests/libmemcached-1.0/all_tests.h @@ -452,6 +452,7 @@ collection_st collection[] ={ {"hsieh_availability", 0, 0, hsieh_availability}, {"murmur_availability", 0, 0, murmur_availability}, @@ -23,10 +19,8 @@ index b4abe9d..f89f007 100644 {"memcached_server_add(MEMCACHED_DISTRIBUTION_CONSISTENT)", (test_callback_fn*)memcached_servers_reset_MEMCACHED_DISTRIBUTION_CONSISTENT_SETUP, 0, memcached_server_add_TESTS}, {"memcached_server_add(MEMCACHED_DISTRIBUTION_CONSISTENT_WEIGHTED)", (test_callback_fn*)memcached_servers_reset_MEMCACHED_DISTRIBUTION_CONSISTENT_WEIGHTED_SETUP, 0, memcached_server_add_TESTS}, {"block", 0, 0, tests}, -diff --git tests/libmemcached-1.0/setup_and_teardowns.cc tests/libmemcached-1.0/setup_and_teardowns.cc -index 4191c38..eb29128 100644 ---- tests/libmemcached-1.0/setup_and_teardowns.cc -+++ tests/libmemcached-1.0/setup_and_teardowns.cc +--- a/tests/libmemcached-1.0/setup_and_teardowns.cc ++++ b/tests/libmemcached-1.0/setup_and_teardowns.cc @@ -177,6 +177,16 @@ test_return_t memcached_servers_reset_SETUP(memcached_st *memc) return TEST_SUCCESS; } @@ -44,10 +38,8 @@ index 4191c38..eb29128 100644 test_return_t memcached_servers_reset_MEMCACHED_DISTRIBUTION_CONSISTENT_SETUP(memcached_st *memc) { test_compare(TEST_SUCCESS, memcached_servers_reset_SETUP(memc)); -diff --git tests/libmemcached-1.0/setup_and_teardowns.h tests/libmemcached-1.0/setup_and_teardowns.h -index 7610c5a..59b56f6 100644 ---- tests/libmemcached-1.0/setup_and_teardowns.h -+++ tests/libmemcached-1.0/setup_and_teardowns.h +--- a/tests/libmemcached-1.0/setup_and_teardowns.h ++++ b/tests/libmemcached-1.0/setup_and_teardowns.h @@ -64,3 +64,4 @@ test_return_t pre_buffer(memcached_st*); test_return_t memcached_servers_reset_MEMCACHED_DISTRIBUTION_CONSISTENT_SETUP(memcached_st *memc); test_return_t memcached_servers_reset_MEMCACHED_DISTRIBUTION_CONSISTENT_WEIGHTED_SETUP(memcached_st *memc); diff --git a/dev-libs/libmemcached/files/debug-disable-enable-1.0.18.patch b/dev-libs/libmemcached/files/debug-disable-enable-1.0.18.patch index ed87cbd7a1c1..fa483b52dcfb 100644 --- a/dev-libs/libmemcached/files/debug-disable-enable-1.0.18.patch +++ b/dev-libs/libmemcached/files/debug-disable-enable-1.0.18.patch @@ -1,7 +1,7 @@ Fixed a bug that caused configure to disobey the enable/disable debug flag. The debug flag will default to disabled if not specified. diff -ru libmemcached-1.0.18-orig/m4/ax_debug.m4 libmemcached-1.0.18/m4/ax_debug.m4 ---- libmemcached-1.0.18-orig/m4/ax_debug.m4 2014-11-05 14:43:53.720284916 -0600 -+++ libmemcached-1.0.18/m4/ax_debug.m4 2014-11-19 14:23:19.512482198 -0600 +--- a/m4/ax_debug.m4 ++++ b/m4/ax_debug.m4 @@ -49,16 +49,18 @@ [AC_PREREQ([2.63])dnl AC_ARG_ENABLE([debug], diff --git a/dev-libs/libmemcached/files/libmemcached-1.0.18-autotools.patch b/dev-libs/libmemcached/files/libmemcached-1.0.18-autotools.patch new file mode 100644 index 000000000000..9194539aeb53 --- /dev/null +++ b/dev-libs/libmemcached/files/libmemcached-1.0.18-autotools.patch @@ -0,0 +1,61 @@ +* Automake 1.14+ fix for AC_PROG_* instantiation +* Disable old GCC flags + +--- a/configure.ac ++++ b/configure.ac +@@ -13,10 +13,6 @@ m4_include([version.m4]) + AC_PREREQ([2.61]) + AC_INIT([libmemcached],VERSION_NUMBER,[http://libmemcached.org/]) + +-# Setup the compilers early on +-AC_PROG_CC([cc gcc clang]) +-AC_PROG_CXX([c++ g++ clang++]) +- + AC_CONFIG_AUX_DIR([build-aux]) + AC_CONFIG_MACRO_DIR([m4]) + +@@ -61,6 +57,10 @@ LT_LIB_M + + AC_SUBST([lt_cv_dlopen_libs]) + ++# Setup the compilers early on ++AC_PROG_CC([cc gcc clang]) ++AC_PROG_CXX([c++ g++ clang++]) ++ + + AC_PROG_CC_C99 + AS_IF([test "x${ac_cv_prog_cc_c99}" == "xno"],[AC_MSG_ERROR([No c99 compatible compiler found])]) +--- a/m4/ax_harden_compiler_flags.m4 ++++ b/m4/ax_harden_compiler_flags.m4 +@@ -138,7 +138,6 @@ + _APPEND_COMPILE_FLAGS_ERROR([-H]) + _APPEND_COMPILE_FLAGS_ERROR([-g]) + _APPEND_COMPILE_FLAGS_ERROR([-g3]) +- _APPEND_COMPILE_FLAGS_ERROR([-fmudflapth]) + _APPEND_COMPILE_FLAGS_ERROR([-fno-eliminate-unused-debug-types]) + _APPEND_COMPILE_FLAGS_ERROR([-fno-omit-frame-pointer]) + ],[ +@@ -213,7 +212,6 @@ + _APPEND_COMPILE_FLAGS_ERROR([-Wunused-local-typedefs]) + _APPEND_COMPILE_FLAGS_ERROR([-Wwrite-strings]) + _APPEND_COMPILE_FLAGS_ERROR([-fwrapv]) +- _APPEND_COMPILE_FLAGS_ERROR([-fmudflapt]) + _APPEND_COMPILE_FLAGS_ERROR([-pipe]) + _APPEND_COMPILE_FLAGS_ERROR([-fPIE -pie]) + _APPEND_COMPILE_FLAGS_ERROR([-Wsizeof-pointer-memaccess]) +@@ -247,7 +245,6 @@ + _APPEND_COMPILE_FLAGS_ERROR([-H]) + _APPEND_COMPILE_FLAGS_ERROR([-g]) + _APPEND_COMPILE_FLAGS_ERROR([-g3]) +- _APPEND_COMPILE_FLAGS_ERROR([-fmudflapth]) + _APPEND_COMPILE_FLAGS_ERROR([-fno-inline]) + _APPEND_COMPILE_FLAGS_ERROR([-fno-eliminate-unused-debug-types]) + _APPEND_COMPILE_FLAGS_ERROR([-fno-omit-frame-pointer]) +@@ -318,7 +315,6 @@ + _APPEND_COMPILE_FLAGS_ERROR([-Wwrite-strings]) + _APPEND_COMPILE_FLAGS_ERROR([-Wformat-security]) + _APPEND_COMPILE_FLAGS_ERROR([-fwrapv]) +- _APPEND_COMPILE_FLAGS_ERROR([-fmudflapt]) + _APPEND_COMPILE_FLAGS_ERROR([-pipe]) + _APPEND_COMPILE_FLAGS_ERROR([-fPIE -pie]) + _APPEND_COMPILE_FLAGS_ERROR([-Wsizeof-pointer-memaccess]) diff --git a/dev-libs/libmemcached/libmemcached-1.0.18-r4.ebuild b/dev-libs/libmemcached/libmemcached-1.0.18-r4.ebuild new file mode 100644 index 000000000000..013383193a6d --- /dev/null +++ b/dev-libs/libmemcached/libmemcached-1.0.18-r4.ebuild @@ -0,0 +1,57 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools + +DESCRIPTION="a C client library to the memcached server" +HOMEPAGE="https://libmemcached.org/libMemcached.html" +SRC_URI="https://launchpad.net/${PN}/1.0/${PV}/+download/${P}.tar.gz" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos" +IUSE="debug hsieh +libevent sasl" +# https://bugs.gentoo.org/498250 +# https://bugs.launchpad.net/gentoo/+bug/1278023 +RESTRICT="test" + +RDEPEND=" + net-misc/memcached + sasl? ( dev-libs/cyrus-sasl ) + libevent? ( dev-libs/libevent )" +DEPEND="${RDEPEND}" + +PATCHES=( + "${FILESDIR}"/debug-disable-enable-1.0.18.patch + "${FILESDIR}"/continuum-1.0.18.patch + "${FILESDIR}"/${P}-gcc7.patch + "${FILESDIR}"/${P}-autotools.patch +) + +src_prepare() { + default + rm README.win32 || die + eautoreconf +} + +src_configure() { + econf \ + --disable-dtrace \ + $(use_enable sasl sasl) \ + $(use_enable debug debug) \ + $(use_enable debug assert) \ + $(use_enable hsieh hsieh_hash) +} + +src_install() { + default + + # https://bugs.gentoo.org/299330 + # remove manpage to avoid collision + rm -f "${ED}"/usr/share/man/man1/memdump.* || die + newman man/memdump.1 memcached_memdump.1 + + find "${ED}" -name '*.la' -delete || die +} |