puke: build script can now be in any language.

This commit is contained in:
Dylan Araps 2019-05-13 15:37:14 +03:00
parent 5f1cd7924d
commit fa0e65e1b0
8 changed files with 14 additions and 14 deletions

4
puke
View File

@ -27,7 +27,7 @@ pkg_setup() {
cd "$rep_dir/$1" || die "Package '$1' not in repository."
[ -f version ] || die "Version file not found."
[ -f sources ] || die "Sources file not found."
[ -f build ] || die "Build file not found."
[ -x build ] || die "Build file not found or not executable."
read -r version release < version
pkg=${name:=$1}\#$version-$release
@ -107,7 +107,7 @@ pkg_extract() {
pkg_build() {
log "Building $pkg."
(set -e errexit; cd "$mak_dir"; . "$OLDPWD/build") ||
(set -e errexit; cd "$mak_dir"; "$OLDPWD/build" "$pkg_dir" ) ||
die "Build failed."
cp -R "$rep_dir/$name" "$pkg_dir/$dbs_dir"

View File

@ -7,7 +7,7 @@ sed -i mozilla/Makefile \
patch -p1 -i update-ca-certificates-destdir.patch
make
cd "$pkg_dir" || return 1
cd "$1" || return 1
install -m0755 -d usr/share/ca-certificates
install -m0755 -d usr/bin
@ -16,7 +16,7 @@ install -m0755 -d etc/ssl/certs
cd - || return 1
make DESTDIR="$pkg_dir" install
make DESTDIR="$1" install
cd "$pkg_dir/usr/share/ca-certificates" || return 1
find . -name '*.crt' | sort | cut -b3- > "$pkg_dir/etc/ca-certificates.conf"
cd "$1/usr/share/ca-certificates" || return 1
find . -name '*.crt' | sort | cut -b3- > "$1/etc/ca-certificates.conf"

View File

@ -1,5 +1,5 @@
make
make DESTDIR="$pkg_dir" install
make DESTDIR="$1" install
install -Dm755 ./etc/rc.init "$pkg_dir/etc/rc.init"
install -Dm755 ./etc/rc.shutdown "$pkg_dir/etc/rc.shutdown"
install -Dm755 ./etc/rc.init "$1/etc/rc.init"
install -Dm755 ./etc/rc.shutdown "$1/etc/rc.shutdown"

View File

@ -4,4 +4,4 @@ patch -p1 -i fix-glibc-2.28.patch
--prefix=/usr
make
make DESTDIR="$pkg_dir" install
make DESTDIR="$1" install

View File

@ -1,4 +1,4 @@
./configure
make
make DESTDIR="$pkg_dir" install
make DESTDIR="$1" install

View File

@ -19,4 +19,4 @@
-Wa,--noexecstack
make
make DESTDIR="$pkg_dir" install_sw
make DESTDIR="$1" install_sw

View File

@ -32,4 +32,4 @@ BUILD_BZIP2=0
-Dusenm
make
make DESTDIR="$pkg_dir" install
make DESTDIR="$1" install

View File

@ -4,4 +4,4 @@
--shared
make
make DESTDIR="$pkg_dir" install
make DESTDIR="$1" install