diff options
author | Lee Starnes <lee@canned-death.us> | 2022-05-29 02:24:14 +0000 |
---|---|---|
committer | Zach van Rijn <me@zv.io> | 2022-10-21 18:34:01 -0500 |
commit | 8721370ccff353cf46c523529a475e364e857393 (patch) | |
tree | c914e623e7923390dfba72de31f8d4703ac1cbab /user/libffcall/APKBUILD | |
parent | e3fd275e9e2360ee4363e5656f89e691aa2b8e36 (diff) | |
download | packages-8721370ccff353cf46c523529a475e364e857393.tar.gz packages-8721370ccff353cf46c523529a475e364e857393.tar.bz2 packages-8721370ccff353cf46c523529a475e364e857393.tar.xz packages-8721370ccff353cf46c523529a475e364e857393.zip |
user/libffcall: 2.4 with Zach's patch
Diffstat (limited to 'user/libffcall/APKBUILD')
-rw-r--r-- | user/libffcall/APKBUILD | 36 |
1 files changed, 32 insertions, 4 deletions
diff --git a/user/libffcall/APKBUILD b/user/libffcall/APKBUILD index 48b16a78f..f3bc87e30 100644 --- a/user/libffcall/APKBUILD +++ b/user/libffcall/APKBUILD @@ -1,9 +1,8 @@ # Contributor: Carlo Landmeter <clandmeter@gmail.com> # Contributor: Will Sinatra <wpsinatra@gmail.com> -# Contributor: Lee Starnes <lee@canned-death.us> # Maintainer: Lee Starnes <lee@canned-death.us> pkgname=libffcall -pkgver=2.2 +pkgver=2.4 pkgrel=0 pkgdesc="C library for implementing foreign function calls in embedded interpreters" url="https://www.gnu.org/software/libffcall" @@ -16,6 +15,35 @@ source="https://ftp.gnu.org/gnu/libffcall/libffcall-$pkgver.tar.gz ppc64.patch " +prepare() { + default_prepare + case "${CARCH}" in + ppc64) + # C sources are patched, bundled .S need to be regenerated; + # recipes for *-powerpc64-elfv2-linux.S from Makefile.devel + temp=$(mktemp) + comm="-D__powerpc64__ -D__powerpc64_elfv2__ -O2 -fno-omit-frame-pointer -o ${temp}" + nxst="../common/noexecstack.h" + + flag="${comm} -I.. -I../dummy" + for k in avcall vacall; do + cd ${k} + gcc ${flag} -S ${k}-powerpc64.c + cat ${temp} ${nxst} > ${k}-powerpc64-elfv2-linux.S + cd - + done + + flag="${comm} -I. -I../.. -I../../dummy -fPIC -DREENTRANT" + cd callback/vacall_r + gcc ${flag} -S ../../vacall/vacall-powerpc64.c + cat ${temp} ../${nxst} > vacall-powerpc64-elfv2-linux.S + cd - + + rm ${temp} + ;; + esac +} + build() { ./configure \ --build=$CBUILD \ @@ -38,5 +66,5 @@ package() { } -sha512sums="b9d3ca4c67ab92915a8183d850153e585dcb58ceb2199a104426a7aae363d37017b1226440acd18a2db0cc207e044f71e932857189964261e8eaa6de5cef1731 libffcall-2.2.tar.gz -db7fae1d2f0d95003186671fd89b097b4abf6184d3001e34dd93419640502b9cd5cf32aef4839d6a4208f4aed793c70f9a4367f12adde21372dc131b111238fe ppc64.patch" +sha512sums="c9451662764a888e3be21499c29673bfb0e1df4915814da3506db5d395a2b00ea2f0c08d1c9dffebf030179f9347794876ec6ec9e6710b4fc70fd760960335e6 libffcall-2.4.tar.gz +7360a5bdea23dec4a84f9653e96540dcccfcce1214899c421ad66760aeffa6223eb1a2d9011a1e0cddb1027b90242518e37c45b12625f8ff9a276e181db278d3 ppc64.patch" |