added gawk toolchain step

This commit is contained in:
ag-tsotetsi
2026-02-08 11:54:33 +02:00
parent 01eea68c24
commit 1f0a0d700b
2 changed files with 56 additions and 0 deletions

49
build/gawk/build.bash Normal file
View File

@@ -0,0 +1,49 @@
. "$PROJECTDIR/build/gawk/package.env"
fetch $GAWK_URL
cd "$SOURCES" && tar xf gawk-$GAWK_VERSION.tar.xz && cd gawk-$GAWK_VERSION
bootstrap() {
echo bootstrap
}
toolchain() {
sed -i 's/extras//' Makefile.in
./configure \
--prefix=/usr \
--host=$TARGET \
--build=$(build-aux/config.guess) > /dev/null
make > /dev/null && make DESTDIR="$SYSROOT" install > /dev/null
}
setup() {
echo setup
}
final() {
echo final
}
case $1 in
bootstrap)
bootstrap
;;
toolchain)
toolchain
;;
setup)
setup
;;
final)
final
;;
esac
rm -rf "$SOURCES/gawk-$GAWK_VERSION"

7
build/gawk/package.env Normal file
View File

@@ -0,0 +1,7 @@
export GAWK_VERSION=5.3.2
IFS='.' read -r GAWK_VERSION_MAJOR GAWK_VERSION_MINOR GAWK_VERSION_PATCH <<< $GAWK_VERSION
export GAWK_VERSION_MAJOR GAWK_VERSION_MINOR GAWK_VERSION_PATCH
export GAWK_URL=https://mirror.ufs.ac.za/gnu/gawk/gawk-$GAWK_VERSION.tar.xz