ladybird/Ports/bzip2/package.sh
Daniel Bertalan 34ae69b99d Ports/bzip2: Set AR and RANLIB
bzip2's Makefile uses the '=' operator to set these variables so they
cannot be overridden by just the environment variables; we have to pass
them on the command line.

This change ensures that the system ar/ranlib are no longer used, so the
port can be build on macOS or non-x86 Linux.
2022-08-04 02:54:19 +02:00

15 lines
536 B
Bash
Executable file

#!/usr/bin/env -S bash ../.port_include.sh
port=bzip2
version=1.0.8
files="https://sourceware.org/pub/bzip2/bzip2-${version}.tar.gz bzip2-${version}.tar.gz ab5a03176ee106d3f0fa90e381da478ddae405918153cca248e682cd0c4a2269"
auth_type=sha256
makeopts=("bzip2")
installopts=("PREFIX=${SERENITY_INSTALL_ROOT}/usr/local")
build() {
run make CC="${CC}" AR="${AR}" RANLIB="${RANLIB}" "${makeopts[@]}" bzip2
}
install() {
run make DESTDIR=${SERENITY_INSTALL_ROOT} CC="${CC}" AR="${AR}" RANLIB="${RANLIB}" "${installopts[@]}" install
}