From 67af9bbff2bbeb6f06035f3307871118f2b04358 Mon Sep 17 00:00:00 2001 From: jklos Date: Thu, 6 Oct 2011 05:34:00 +0000 Subject: Atomic operations via gcc are not supported on many archs. Allow them only on amd64, powerpc, i386 and alpha. --- lang/php53/patches/patch-as | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 lang/php53/patches/patch-as (limited to 'lang/php53/patches') diff --git a/lang/php53/patches/patch-as b/lang/php53/patches/patch-as new file mode 100644 index 00000000000..c037a728a70 --- /dev/null +++ b/lang/php53/patches/patch-as @@ -0,0 +1,14 @@ +$NetBSD: patch-as,v 1.1 2011/10/06 05:34:00 jklos Exp $ + +--- ext/standard/php_crypt_r.c.orig 2011-10-06 05:25:16.000000000 +0000 ++++ ext/standard/php_crypt_r.c +@@ -94,7 +94,8 @@ void _crypt_extended_init_r(void) + if (!initialized) { + #ifdef PHP_WIN32 + InterlockedIncrement(&initialized); +-#elif (defined(__GNUC__) && !defined(__hpux) && (__GNUC__ > 4 || \ ++#elif (defined(__GNUC__) && (defined(__amd64__) || defined(__alpha__) || \ ++ defined(__i386__) || defined(__powerpc__)) && (__GNUC__ > 4 || \ + (__GNUC__ == 4 && (__GNUC_MINOR__ > 1 || (__GNUC_MINOR__ == 1 && __GNUC_PATCHLEVEL__ > 1))))) + __sync_fetch_and_add(&initialized, 1); + #elif defined(HAVE_ATOMIC_H) /* Solaris 10 defines atomic API within */ -- cgit v1.2.3