From 3a038312c42c098e5d9d46e7e4e5497270e8fa39 Mon Sep 17 00:00:00 2001 From: its-pointless Date: Fri, 29 Sep 2017 08:15:27 +1000 Subject: [PATCH] libgc fix for x86 need it for guile (#1588) --- packages/libgc/build.sh | 2 +- packages/libgc/os_dep.c.patch | 14 ++++++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) create mode 100644 packages/libgc/os_dep.c.patch diff --git a/packages/libgc/build.sh b/packages/libgc/build.sh index dd407f640..5c0dcf5fa 100644 --- a/packages/libgc/build.sh +++ b/packages/libgc/build.sh @@ -4,7 +4,7 @@ TERMUX_PKG_VERSION=7.6.0 TERMUX_PKG_SRCURL=http://www.hboehm.info/gc/gc_source/gc-${TERMUX_PKG_VERSION}.tar.gz TERMUX_PKG_SHA256=a14a28b1129be90e55cd6f71127ffc5594e1091d5d54131528c24cd0c03b7d90 TERMUX_PKG_RM_AFTER_INSTALL="share/gc" - +TERMUX_PKG_REVISION=1 termux_step_post_extract_package () { LIBATOMIC_VERSION=7.4.6 LIBATOMIC_FILE=libatomic_ops-${LIBATOMIC_VERSION}.tar.gz diff --git a/packages/libgc/os_dep.c.patch b/packages/libgc/os_dep.c.patch new file mode 100644 index 000000000..0e7dd8c35 --- /dev/null +++ b/packages/libgc/os_dep.c.patch @@ -0,0 +1,14 @@ +--- ../cache/gc-7.6.0/os_dep.c 2016-08-02 19:36:14.000000000 +0000 ++++ ./os_dep.c 2017-09-27 01:02:30.156628565 +0000 +@@ -426,7 +426,10 @@ + + # if (defined(LINUX) || defined(HURD)) && !defined(IGNORE_PROG_DATA_START) + /* Try the easy approaches first: */ +-# ifdef PLATFORM_ANDROID ++ /* this workaround for gold linker when only aarch64 is using it in ++ termux breaks x86_64 and x86 builds */ ++ ++# if defined(PLATFORM_ANDROID) && !defined(__x86_64__) && !defined(__i386__) + /* Workaround for "gold" (default) linker (as of Android NDK r10e). */ + if ((word)__data_start < (word)_etext + && (word)_etext < (word)__dso_handle) {