summaryrefslogtreecommitdiff
path: root/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD19
1 files changed, 15 insertions, 4 deletions
diff --git a/PKGBUILD b/PKGBUILD
index fde48c0..bfbe5a8 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -20,11 +20,22 @@ prepare() {
}
build() {
+ local _platform_flags=()
+
+ case $CARCH in
+ x86_64)
+ _platform_flags=(PLATFORM=x64 IS_X64=1 MY_ASM=uasm USE_ASM=1)
+ ;;
+ i686)
+ _platform_flags=(PLATFORM=x86 IS_X86=1 MY_ASM=uasm USE_ASM=1)
+ ;;
+ aarch64)
+ _platform_flags=(PLATFORM=arm64 IS_ARM64=1 MY_ASM=uasm USE_ASM=1)
+ ;;
+ esac
+
for component in Bundles/{Alone,Alone7z,Format7zF,SFXCon} UI/Console; do
- make -C CPP/7zip/$component -f ../../cmpl_gcc.mak \
- MY_ASM=uasm \
- USE_ASM=1 \
- IS_X64=1 \
+ make -C CPP/7zip/$component -f ../../cmpl_gcc.mak "${_platform_flags[@]}" \
CC="cc $CPPFLAGS $CFLAGS $LDFLAGS" \
CXX="g++ $CPPFLAGS $CXXFLAGS $LDFLAGS"
done