aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAriadne Conill <ariadne@dereferenced.org>2021-06-29 09:26:12 -0600
committerAriadne Conill <ariadne@dereferenced.org>2021-06-29 09:27:53 -0600
commit2dbf2a4ef48f890ce1d0bda392f309b7a24eaca5 (patch)
tree4e19c81dc95938fedbcfb7b182d1585069996570
parent8a4851a18b4832f5643915f9ae8e5cb77ddbfd3d (diff)
downloadaports-2dbf2a4ef48f890ce1d0bda392f309b7a24eaca5.tar.gz
aports-2dbf2a4ef48f890ce1d0bda392f309b7a24eaca5.tar.bz2
aports-2dbf2a4ef48f890ce1d0bda392f309b7a24eaca5.tar.xz
main/zstd: backport compile fixes from 3.14
-rw-r--r--main/zstd/APKBUILD7
1 files changed, 7 insertions, 0 deletions
diff --git a/main/zstd/APKBUILD b/main/zstd/APKBUILD
index 9613807271..c105adbaa9 100644
--- a/main/zstd/APKBUILD
+++ b/main/zstd/APKBUILD
@@ -19,6 +19,13 @@ source="zstd-$pkgver.tar.gz::https://github.com/facebook/zstd/archive/v$pkgver.t
# 1.3.8-r0:
# - CVE-2019-11922
+unset CPPFLAGS
+export CFLAGS="$CFLAGS -O2 -fno-strict-aliasing -fPIC"
+case "$CARCH" in
+ # avoid memory copy hack that violates C standard
+ armhf) export CFLAGS="$CFLAGS -DMEM_FORCE_MEMORY_ACCESS=0" ;;
+esac
+
build() {
cd "$builddir"
unset CPPFLAGS