void-packages/srcpkgs/libmemcached/patches/musl-fixes.patch
2015-08-26 11:57:19 -04:00

51 lines
1.2 KiB
Diff

diff --git libhashkit/fnv_64.cc libhashkit/fnv_64.cc
index 68e4dd0..88bbace 100644
--- libhashkit/fnv_64.cc
+++ libhashkit/fnv_64.cc
@@ -37,6 +37,9 @@
#include <libhashkit/common.h>
+#ifndef __GLIBC__
+#include <sys/reg.h>
+#endif
#if __WORDSIZE == 64 && defined(HAVE_FNV64_HASH)
diff --git libhashkit/has.cc libhashkit/has.cc
index 843e32e..7dbadc3 100644
--- libhashkit/has.cc
+++ libhashkit/has.cc
@@ -37,6 +37,9 @@
#include <libhashkit/common.h>
+#ifndef __GLIBC__
+#include <sys/reg.h>
+#endif
bool libhashkit_has_algorithm(const hashkit_hash_algorithm_t algo)
{
diff --git libtest/cmdline.cc libtest/cmdline.cc
index 29a22de..161c646 100644
--- libtest/cmdline.cc
+++ libtest/cmdline.cc
@@ -61,7 +61,7 @@ using namespace libtest;
#include <algorithm>
#include <stdexcept>
-#ifndef __USE_GNU
+#ifndef _GNU_SOURCE
static char **environ= NULL;
#endif
@@ -201,7 +201,7 @@ Application::error_t Application::run(const char *args[])
fatal_assert(posix_spawnattr_setsigmask(&spawnattr, &mask) == 0);
-#if defined(POSIX_SPAWN_USEVFORK) || defined(__linux__)
+#if defined(POSIX_SPAWN_USEVFORK) || defined(__GLIBC__)
// Use USEVFORK on linux
flags |= POSIX_SPAWN_USEVFORK;
#endif