Browse Source

Fix termux-elf-cleaner breakage

When separating out termux-elf-cleaner into its own repository the
way of building a native binary failed. Fixes #906.
android-5
Fredrik Fornwall 8 years ago
parent
commit
bd54a46a80
  1. 7
      build-package.sh
  2. 3
      packages/termux-elf-cleaner/build.sh

7
build-package.sh

@ -348,7 +348,12 @@ termux_step_start_build() {
# scripts can assume that it works on both builder and host later on:
ln -f -s /bin/sh "$TERMUX_PREFIX/bin/sh"
TERMUX_ELF_CLEANER_SRC=$TERMUX_SCRIPTDIR/packages/termux-elf-cleaner/termux-elf-cleaner.cpp
local TERMUX_ELF_CLEANER_SRC=$TERMUX_COMMON_CACHEDIR/termux-elf-cleaner.cpp
local TERMUX_ELF_CLEANER_VERSION=$(bash -c ". $TERMUX_SCRIPTDIR/packages/termux-elf-cleaner/build.sh; echo \$TERMUX_PKG_VERSION")
termux_download \
https://raw.githubusercontent.com/termux/termux-elf-cleaner/v$TERMUX_ELF_CLEANER_VERSION/termux-elf-cleaner.cpp \
$TERMUX_ELF_CLEANER_SRC \
11a38372f4d0e36b7556382c7ecffecae35cee8b68daaee2dbee025f758e17ee
if [ "$TERMUX_ELF_CLEANER_SRC" -nt "$TERMUX_ELF_CLEANER" ]; then
g++ -std=c++11 -Wall -Wextra -pedantic -Os "$TERMUX_ELF_CLEANER_SRC" -o "$TERMUX_ELF_CLEANER"
fi

3
packages/termux-elf-cleaner/build.sh

@ -1,5 +1,8 @@
TERMUX_PKG_HOMEPAGE=https://github.com/termux/termux-elf-cleaner
TERMUX_PKG_DESCRIPTION="Cleaner of ELF files for Android"
# NOTE: The termux-elf-cleaner.cpp file is used by build-package.sh
# to create a native binary. Bumping this version will need
# updating the checksum used there.
TERMUX_PKG_VERSION=1.1
TERMUX_PKG_SRCURL=https://github.com/termux/termux-elf-cleaner/archive/v${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=66612b294e197ab7bfac807e497581df58424af6a7c855f89fc12eafa3dc1b8c

Loading…
Cancel
Save