From 003a5bc19e8e307f6d3bb130ecb7ac799fa8108c Mon Sep 17 00:00:00 2001 From: Shiz Date: Tue, 16 May 2017 02:59:32 +0200 Subject: community/llvm-libunwind: upgrade to 4.0.0 --- community/llvm-libunwind/APKBUILD | 40 ++++++++++++---------------- community/llvm-libunwind/no-exec-stack.patch | 19 +++++++++++++ 2 files changed, 36 insertions(+), 23 deletions(-) create mode 100644 community/llvm-libunwind/no-exec-stack.patch (limited to 'community/llvm-libunwind') diff --git a/community/llvm-libunwind/APKBUILD b/community/llvm-libunwind/APKBUILD index b5491cbeab..4aaeb5d093 100644 --- a/community/llvm-libunwind/APKBUILD +++ b/community/llvm-libunwind/APKBUILD @@ -2,9 +2,9 @@ # Maintainer: Jakub Jirutka pkgname=llvm-libunwind _pkgname=libunwind -pkgver=3.9.1 -_llvmver=3.9 -pkgrel=1 +pkgver=4.0.0 +_llvmver=${pkgver%%.*} +pkgrel=0 pkgdesc="LLVM version of libunwind library" url="http://llvm.org/" arch="all !ppc64le !s390x" @@ -12,37 +12,31 @@ license="BSD" depends_dev="!libunwind-dev" makedepends="cmake llvm$_llvmver-dev" subpackages="$pkgname-dev" -source="http://www.llvm.org/releases/$pkgver/$_pkgname-$pkgver.src.tar.xz" +source="http://www.llvm.org/releases/$pkgver/$_pkgname-$pkgver.src.tar.xz + no-exec-stack.patch" builddir="$srcdir/$_pkgname-$pkgver.src" options="!check" build() { - local flag; for flag in 0 1; do - mkdir -p "$builddir"/build-$flag - cd "$builddir"/build-$flag + cd "$builddir" - cmake .. \ - -DCMAKE_BUILD_TYPE=MinSizeRel \ - -DCMAKE_INSTALL_PREFIX=/usr \ - -DCMAKE_CXX_FLAGS="$CXXFLAGS" \ - -DCMAKE_C_FLAGS="$CFLAGS" \ - -DCMAKE_VERBOSE_MAKEFILE=ON \ - -DLIBUNWIND_ENABLE_SHARED=$flag \ - -DLIBUNWIND_HAS_NODEFAULTLIBS_FLAG=0 \ - -DLLVM_CONFIG="/usr/bin/llvm-config-$_llvmver" - make - done + cmake \ + -DCMAKE_BUILD_TYPE=MinSizeRel \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DCMAKE_CXX_FLAGS="$CXXFLAGS" \ + -DCMAKE_C_FLAGS="$CFLAGS" \ + -DLLVM_CONFIG_PATH="/usr/lib/llvm$_llvmver/bin/llvm-config" \ + -DLIBUNWIND_HAS_NODEFAULTLIBS_FLAG=OFF + make } package() { - local flag; for flag in 0 1; do - make install -C "$builddir"/build-$flag DESTDIR="$pkgdir" - done - cd "$builddir" + make install DESTDIR="$pkgdir" mkdir -p "$pkgdir"/usr/include cp include/*.h "$pkgdir"/usr/include/ } -sha512sums="a80f5d0660e209f5bf709316b5df2ca63b9f0db49f5f74dfe9c9e580c654f61a15acc071a739fdb84baf5ffa9420b92498f8560331173642d80f6b74e1e2afb7 libunwind-3.9.1.src.tar.xz" +sha512sums="c3c934b70830ef5496c9d24c469b702eb4408abd4fe4dd9e0832230b064dc78d23b02ed2a5ce9a099dea76c3d43cbf41d59c6cda189f990d5593c7d3cd5c79dd libunwind-4.0.0.src.tar.xz +2a61580331a9c8e5f9d4a12a845be187db65434257bb635eb509db43355709de0f17ddd8a589e0c8ee89ed29c0dc1cefd0fd9d11e4a0eb875b14ad4833063d11 no-exec-stack.patch" diff --git a/community/llvm-libunwind/no-exec-stack.patch b/community/llvm-libunwind/no-exec-stack.patch new file mode 100644 index 0000000000..6220e946b3 --- /dev/null +++ b/community/llvm-libunwind/no-exec-stack.patch @@ -0,0 +1,19 @@ +Remove the gatekeeping to set a non-executable stack for libunwind, +as we don't define any of these directives but still want it. + +diff -Nru a/src/assembly.h b/src/assembly.h +--- a/src/assembly.h 2016-10-23 21:48:47.000000000 +0000 ++++ b/src/assembly.h 2017-05-16 12:38:47.209169931 +0000 +@@ -47,12 +47,7 @@ + #define SYMBOL_IS_FUNC(name) .type name,@function + #endif + +-#if defined(__GNU__) || defined(__ANDROID__) || defined(__FreeBSD__) || \ +- defined(__Fuchsia__) + #define NO_EXEC_STACK_DIRECTIVE .section .note.GNU-stack,"",%progbits +-#else +-#define NO_EXEC_STACK_DIRECTIVE +-#endif + + #else + -- cgit v1.2.3