diff options
author | Alexey Dokuchaev <danfe@FreeBSD.org> | 2014-07-23 16:49:42 +0000 |
---|---|---|
committer | Alexey Dokuchaev <danfe@FreeBSD.org> | 2014-07-23 16:49:42 +0000 |
commit | aea9f4fb4be6711ea15432a39cf89a7a81a3d1e5 (patch) | |
tree | 21d98bba0fac4a7765ad6dba4a35e7097f2f79e2 /ports-mgmt/pkg/files | |
parent | 9b85518f0031e8fbf6a6b8c5161c8474d1efa16c (diff) | |
download | ports-aea9f4fb4be6711ea15432a39cf89a7a81a3d1e5.tar.gz ports-aea9f4fb4be6711ea15432a39cf89a7a81a3d1e5.zip |
Fix the build on PowerPC: apparently it declares that it has atomic builtins,
but GCC 4.2 bombs with internal compiler error (= unrecognizable instruction)
when compiling libucl/src/ucl_util.c.
Approved by: bapt (portmgr, maintainer)
Notes
Notes:
svn path=/head/; revision=362707
Diffstat (limited to 'ports-mgmt/pkg/files')
-rw-r--r-- | ports-mgmt/pkg/files/patch-powerpc-no-atomic-builtins | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/ports-mgmt/pkg/files/patch-powerpc-no-atomic-builtins b/ports-mgmt/pkg/files/patch-powerpc-no-atomic-builtins new file mode 100644 index 000000000000..beb33dd46b78 --- /dev/null +++ b/ports-mgmt/pkg/files/patch-powerpc-no-atomic-builtins @@ -0,0 +1,29 @@ +--- external/libucl/src/ucl_util.c.orig 2014-06-12 01:37:02 +0800 ++++ external/libucl/src/ucl_util.c +@@ -160,7 +160,7 @@ static void + ucl_object_dtor_unref_single (ucl_object_t *obj) + { + if (obj != NULL) { +-#ifdef HAVE_ATOMIC_BUILTINS ++#if defined(HAVE_ATOMIC_BUILTINS) && !defined(__powerpc__) + unsigned int rc = __sync_sub_and_fetch (&obj->ref, 1); + if (rc == 0) { + #else +@@ -1850,7 +1850,7 @@ ucl_object_ref (const ucl_object_t *obj) + + if (obj != NULL) { + res = __DECONST (ucl_object_t *, obj); +-#ifdef HAVE_ATOMIC_BUILTINS ++#if defined(HAVE_ATOMIC_BUILTINS) && !defined(__powerpc__) + (void)__sync_add_and_fetch (&res->ref, 1); + #else + res->ref ++; +@@ -1863,7 +1863,7 @@ void + ucl_object_unref (ucl_object_t *obj) + { + if (obj != NULL) { +-#ifdef HAVE_ATOMIC_BUILTINS ++#if defined(HAVE_ATOMIC_BUILTINS) && !defined(__powerpc__) + unsigned int rc = __sync_sub_and_fetch (&obj->ref, 1); + if (rc == 0) { + #else |