Browse Source

coreutils: disallow on-device build

It can delete utility 'ln' in the process of installation:

 make  install-exec-hook
 make[4]: Entering directory '/data/data/com.termux/files/home/.termux-build/coreutils/build'
 /bin/sh: 12: ln: not found
android-5
Leonid Plyushch 6 years ago
parent
commit
d8ac768369
No known key found for this signature in database GPG Key ID: 45F2964132545795
  1. 6
      packages/coreutils/build.sh

6
packages/coreutils/build.sh

@ -28,4 +28,10 @@ ac_cv_func_mbsrtowcs=no
termux_step_pre_configure() {
CPPFLAGS+=" -DDEFAULT_TMPDIR=\\\"$TERMUX_PREFIX/tmp\\\""
CPPFLAGS+=" -D__USE_FORTIFY_LEVEL=0"
# On device build is unsupported as it removes utility 'ln' (and maybe
# something else) in the installation process.
if [ -n "$TERMUX_ON_DEVICE_BUILD" ]; then
termux_error_exit "Package '$TERMUX_PKG_NAME' is not safe for on-device builds."
fi
}

Loading…
Cancel
Save