0
0
mirror of https://github.com/termux/termux-packages.git synced 2025-05-10 01:06:12 +00:00
Files
termux-packages/scripts/build/termux_step_elf_cleaner.sh
agnostic-apollo 71057fadd8 enhance(build-package.sh): add termux_step_strip_elf_symbols and termux_step_elf_cleaner for packages to hook into
Packages may not want specific elf files to be stripped, like for debug `-g` test binaries, or may have elf files under different non-standard directories.
2025-03-22 05:45:48 +05:00

10 lines
349 B
Bash

termux_step_elf_cleaner() {
termux_step_elf_cleaner__from_paths . \( -path "./bin/*" -o -path "./lib/*" -o -path "./libexec/*" -o -path "./opt/*" \)
}
termux_step_elf_cleaner__from_paths() {
# Remove entries unsupported by Android's linker:
find "$@" -type f -print0 | xargs -r -0 \
"$TERMUX_ELF_CLEANER" --api-level "$TERMUX_PKG_API_LEVEL"
}