scripts(toolchain_26b): only append `-fno-openmp-implicit-rpath` if cross-compiling

This commit is contained in:
Chongyun Lee 2024-02-28 00:34:20 +08:00 committed by GitHub
parent 2f8860fd5f
commit c1e20b09f0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 1 deletions

View File

@ -67,7 +67,10 @@ termux_setup_toolchain_26b() {
# -static-openmp requires -fopenmp in LDFLAGS to work; hopefully this won't be problematic
# even when we don't have -fopenmp in CFLAGS / when we don't want to enable OpenMP
# We might also want to consider shipping libomp.so instead; since r21
LDFLAGS+=" -fopenmp -static-openmp -fno-openmp-implicit-rpath"
LDFLAGS+=" -fopenmp -static-openmp"
if [ "$TERMUX_ON_DEVICE_BUILD" = "false" ]; then
LDFLAGS+=" -fno-openmp-implicit-rpath"
fi
# Android 7 started to support DT_RUNPATH (but not DT_RPATH).
LDFLAGS+=" -Wl,--enable-new-dtags"