From: voidlinux-github@inbox.vuxu.org
To: ml@inbox.vuxu.org
Subject: Re: [PR PATCH] [Updated] memcached: update to 1.5.19
Date: Fri, 01 Nov 2019 02:26:39 +0100 [thread overview]
Message-ID: <20191101012639.QF__AkJwa7LCGNNtb_hN6CkpFw-2LLGD-S41pPNgH6U@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-16008@inbox.vuxu.org>
[-- Attachment #1: Type: text/plain, Size: 319 bytes --]
There is an updated pull request by ndowens against master on the void-packages repository
https://github.com/ndowens/void-packages memcached
https://github.com/void-linux/void-packages/pull/16008
memcached: update to 1.5.19
A patch file from https://github.com/void-linux/void-packages/pull/16008.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-memcached-16008.patch --]
[-- Type: text/x-diff, Size: 6279 bytes --]
From b786efc129b8bc12a4f83f3847dd7a0c22bfe295 Mon Sep 17 00:00:00 2001
From: Nathan Owens <ndowens04@gmail.com>
Date: Thu, 31 Oct 2019 14:03:10 -0500
Subject: [PATCH] memcached: update to 1.5.19
---
...nfigure-Fix-cross-compilation-errors.patch | 127 ++++++++++++++++++
srcpkgs/memcached/patches/termios.patch | 12 --
srcpkgs/memcached/template | 12 +-
3 files changed, 136 insertions(+), 15 deletions(-)
create mode 100644 srcpkgs/memcached/patches/0001-configure-Fix-cross-compilation-errors.patch
delete mode 100644 srcpkgs/memcached/patches/termios.patch
diff --git a/srcpkgs/memcached/patches/0001-configure-Fix-cross-compilation-errors.patch b/srcpkgs/memcached/patches/0001-configure-Fix-cross-compilation-errors.patch
new file mode 100644
index 00000000000..1f2275c1802
--- /dev/null
+++ b/srcpkgs/memcached/patches/0001-configure-Fix-cross-compilation-errors.patch
@@ -0,0 +1,127 @@
+From 779e1e751e6cced9ac3a5160f2a991c47e0fa2ef Mon Sep 17 00:00:00 2001
+From: Ola Jeppsson <ola.jeppsson@gmail.com>
+Date: Mon, 7 Oct 2019 18:07:30 -0400
+Subject: [PATCH] configure: Fix cross-compilation errors
+
+AC_RUN_IFELSE does not work when cross-compiling so we need to provide
+fallback methods for those cases.
+
+I tried to use constructs that work with Autoconf 2.52.
+Alas, I wasn't able to generate a working build system with that version.
+
+Autoconf 2.58 / Automake 1.7.9 is the earliest combo that I could get
+to work (with and without this patch).
+Perhaps it's time for a slight bump for the required version numbers?
+
+Cross-compiles sucessfully against:
+riscv64-unknown-linux-gnu
+---
+ configure.ac | 59 +++++++++++++++-------------------------------------
+ restart.h | 2 +-
+ 2 files changed, 18 insertions(+), 43 deletions(-)
+
+diff --git configure.ac configure.ac
+index fb78fc5..7e5bd5d 100644
+--- configure.ac
++++ configure.ac
+@@ -264,23 +264,15 @@ return sizeof(void*) == 8 ? 0 : 1;
+ ],[
+ CFLAGS="-m64 $org_cflags"
+ ],[
+- AC_MSG_ERROR([Don't know how to build a 64-bit object.])
++ AC_MSG_ERROR([Don't know how to build a 64-bit object.])
++ ],[
++ dnl cross compile
++ AC_MSG_WARN([Assuming no extra CFLAGS are required for cross-compiling 64bit version.])
+ ])
+ fi
+
+-dnl If data pointer is 64bit or not.
+-AC_RUN_IFELSE(
+- [AC_LANG_PROGRAM([], [dnl
+-return sizeof(void*) == 8 ? 0 : 1;
+- ])
+-],[
+- have_64bit_ptr=yes
+-],[
+-])
+-
+-if test $have_64bit_ptr = yes; then
+- AC_DEFINE(HAVE_64BIT_PTR, 1, [data pointer is 64bit])
+-fi
++dnl Check if data pointer is 64bit or not
++AC_CHECK_SIZEOF([void *])
+
+ # Issue 213: Search for clock_gettime to help people linking
+ # with a static version of libevent
+@@ -570,30 +562,10 @@ fi
+ AC_C_SOCKLEN_T
+
+ dnl Check if we're a little-endian or a big-endian system, needed by hash code
+-AC_DEFUN([AC_C_ENDIAN],
+-[AC_CACHE_CHECK(for endianness, ac_cv_c_endian,
+-[
+- AC_RUN_IFELSE(
+- [AC_LANG_PROGRAM([], [dnl
+- long val = 1;
+- char *c = (char *) &val;
+- exit(*c == 1);
+- ])
+- ],[
+- ac_cv_c_endian=big
+- ],[
+- ac_cv_c_endian=little
+- ])
+-])
+-if test $ac_cv_c_endian = big; then
+- AC_DEFINE(ENDIAN_BIG, 1, [machine is bigendian])
+-fi
+-if test $ac_cv_c_endian = little; then
+- AC_DEFINE(ENDIAN_LITTLE, 1, [machine is littleendian])
+-fi
+-])
+-
+-AC_C_ENDIAN
++AC_C_BIGENDIAN(
++ [AC_DEFINE(ENDIAN_BIG, 1, [machine is bigendian])],
++ [AC_DEFINE(ENDIAN_LITTLE, 1, [machine is littleendian])],
++ [AC_MSG_ERROR([Cannot detect endianness. Must pass ac_cv_c_bigendian={yes,no} to configure.])])
+
+ AC_DEFUN([AC_C_HTONLL],
+ [
+@@ -670,12 +642,15 @@ AC_DEFUN([AC_C_ALIGNMENT],
+ ],[
+ ac_cv_c_alignment=need
+ ],[
+- ac_cv_c_alignment=need
++ dnl cross compile
++ ac_cv_c_alignment=maybe
+ ])
+ ])
+-if test $ac_cv_c_alignment = need; then
+- AC_DEFINE(NEED_ALIGN, 1, [Machine need alignment])
+-fi
++AS_IF([test $ac_cv_c_alignment = need],
++ [AC_DEFINE(NEED_ALIGN, 1, [Machine need alignment])])
++AS_IF([test $ac_cv_c_alignment = maybe],
++ [AC_MSG_WARN([Assuming aligned access is required when cross-compiling])
++ AC_DEFINE(NEED_ALIGN, 1, [Machine need alignment])])
+ ])
+
+ AC_C_ALIGNMENT
+diff --git restart.h restart.h
+index 76cd0a8..9de5096 100644
+--- restart.h
++++ restart.h
+@@ -4,7 +4,7 @@
+ #define RESTART_TAG_MAXLEN 255
+
+ // Track the pointer size for restart fiddling.
+-#ifdef HAVE_64BIT_PTR
++#if SIZEOF_VOID_P == 8
+ typedef uint64_t mc_ptr_t;
+ #else
+ typedef uint32_t mc_ptr_t;
+--
+2.23.0
+
diff --git a/srcpkgs/memcached/patches/termios.patch b/srcpkgs/memcached/patches/termios.patch
deleted file mode 100644
index ed45d1975d0..00000000000
--- a/srcpkgs/memcached/patches/termios.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-This fixes build (errors about an incomplete struct) as the
-code uses TCGETS.
---- linux_priv.c 2019-02-10 17:37:43.939089097 +0100
-+++ linux_priv.c 2019-02-10 17:37:31.180435066 +0100
-@@ -3,6 +3,7 @@
- #include <errno.h>
- #include <stdlib.h>
- #include <sys/ioctl.h>
-+#include <termios.h>
- #include "memcached.h"
-
- // If anything crosses the policy, kill the process.
diff --git a/srcpkgs/memcached/template b/srcpkgs/memcached/template
index 8dfd0095a83..6203f0286df 100644
--- a/srcpkgs/memcached/template
+++ b/srcpkgs/memcached/template
@@ -1,9 +1,10 @@
# Template file for 'memcached'
pkgname=memcached
-version=1.5.16
-revision=2
+version=1.5.19
+revision=1
build_style=gnu-configure
configure_args="--enable-seccomp"
+hostmakedepends="autoconf automake"
makedepends="libevent-devel libseccomp-devel"
short_desc="Distributed memory object caching system"
maintainer="Orphaned <orphan@voidlinux.org>"
@@ -11,7 +12,12 @@ license="BSD-3-Clause"
homepage="http://www.memcached.org"
changelog="https://github.com/memcached/memcached/wiki/ReleaseNotes${version//./}"
distfiles="http://memcached.org/files/${pkgname}-${version}.tar.gz"
-checksum=45a22c890dc1edb27db567fb4c9c25b91bfd578477c08c5fb10dca93cc62cc5a
+checksum=3ddcdaa2d14d215f3111a7448b79c889c57618a26e97ad989581f1880a5a4be0
+
+# Rebuild configure script, due to patching configure.ac
+pre_configure() {
+ autoreconf -fi
+}
post_install() {
vlicense COPYING LICENSE
next prev parent reply other threads:[~2019-11-01 1:26 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-31 19:49 [PR PATCH] " voidlinux-github
2019-10-31 21:22 ` voidlinux-github
2019-11-01 1:03 ` voidlinux-github
2019-11-01 1:26 ` voidlinux-github [this message]
2019-11-01 1:26 ` [PR PATCH] [Updated] " voidlinux-github
2019-11-01 17:51 ` [PR PATCH] [Closed]: " voidlinux-github
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20191101012639.QF__AkJwa7LCGNNtb_hN6CkpFw-2LLGD-S41pPNgH6U@z \
--to=voidlinux-github@inbox.vuxu.org \
--cc=ml@inbox.vuxu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).