commit: a2c5745da40c327b9410095079feadb529d102c4
parent 31caabdeef3b54aaac351ef5c1782b28cae229ac
Author: Andrius Štikonas <andrius@stikonas.eu>
Date: Mon, 3 May 2021 23:48:06 +0100
helpers.sh: Add a helper function to call appropriate default stage function.
Diffstat:
34 files changed, 60 insertions(+), 50 deletions(-)
diff --git a/sysa/autoconf-2.53/stage1.sh b/sysa/autoconf-2.53/stage1.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
rm Makefile.in */Makefile.in */*/Makefile.in aclocal.m4 configure
rm doc/standards.info doc/autoconf.info
diff --git a/sysa/automake-1.10.3/automake-1.10.3.sh b/sysa/automake-1.10.3/automake-1.10.3.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
./bootstrap
}
diff --git a/sysa/automake-1.11.2/automake-1.11.2.sh b/sysa/automake-1.11.2/automake-1.11.2.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
./bootstrap
}
diff --git a/sysa/automake-1.15.1/automake-1.15.1.sh b/sysa/automake-1.15.1/automake-1.15.1.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
./bootstrap
diff --git a/sysa/binutils-2.14/binutils-2.14.sh b/sysa/binutils-2.14/binutils-2.14.sh
@@ -4,7 +4,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
rm configure Makefile.in
diff --git a/sysa/bison-3.4.1/stage1.sh b/sysa/bison-3.4.1/stage1.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
mv lib/textstyle.in.h lib/textstyle.h
diff --git a/sysa/bison-3.4.1/stage2.sh b/sysa/bison-3.4.1/stage2.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
mv lib/textstyle.in.h lib/textstyle.h
diff --git a/sysa/bison-3.4.1/stage3.sh b/sysa/bison-3.4.1/stage3.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
mv lib/textstyle.in.h lib/textstyle.h
diff --git a/sysa/coreutils-6.10/coreutils-6.10.sh b/sysa/coreutils-6.10/coreutils-6.10.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
mv lib/fnmatch.in.h lib/fnmatch.h
# Rebuild bison pre-generated file
diff --git a/sysa/diffutils-2.7/diffutils-2.7.sh b/sysa/diffutils-2.7/diffutils-2.7.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
touch config.h
}
diff --git a/sysa/flex-2.5.11/flex-2.5.11.sh b/sysa/flex-2.5.11/flex-2.5.11.sh
@@ -5,7 +5,7 @@
# When we rebuild flex it no longer needs patching
# and can use simplified makefile
src_prepare() {
- default_src_prepare
+ default
touch config.h
rm parse.c parse.h scan.c skel.c
@@ -19,5 +19,5 @@ src_install() {
rm -f "${PREFIX}/lib/libl.a"
fi
- default_src_install
+ default
}
diff --git a/sysa/flex-2.6.4/flex-2.6.4.sh b/sysa/flex-2.6.4/flex-2.6.4.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
mv Makefile src/
touch src/config.h
@@ -12,13 +12,13 @@ src_prepare() {
src_compile() {
cd src
- default_src_compile
+ default
cd ..
}
src_install() {
cd src
- default_src_install
+ default
cd ..
# Remove yacc, we won't need it any longer
diff --git a/sysa/gawk-3.0.4/gawk-3.0.4.sh b/sysa/gawk-3.0.4/gawk-3.0.4.sh
@@ -3,12 +3,12 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
rm awktab.c
}
src_install() {
- default_src_install
+ default
# Install data files
install -d "${DESTDIR}${PREFIX}/share/awk/"
diff --git a/sysa/gcc-4.0.4/pass1.sh b/sysa/gcc-4.0.4/pass1.sh
@@ -4,11 +4,11 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_unpack() {
- default_src_unpack
+ default
}
src_prepare() {
- default_src_prepare
+ default
# This is needed for building with TCC
sed -i 's/ix86_attribute_table\[\]/ix86_attribute_table\[10\]/' gcc/config/i386/i386.c
# Needed for musl
diff --git a/sysa/gcc-4.0.4/pass2.sh b/sysa/gcc-4.0.4/pass2.sh
@@ -4,11 +4,11 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_unpack() {
- default_src_unpack
+ default
}
src_prepare() {
- default_src_prepare
+ default
# Needed for musl
sed -i 's/struct siginfo/siginfo_t/' gcc/config/i386/linux-unwind.h
diff --git a/sysa/gmp-6.2.1/gmp-6.2.1.sh b/sysa/gmp-6.2.1/gmp-6.2.1.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
# Remove bison and flex generated files
rm demos/calc/calc.{c,h} demos/calc/calclex.c
diff --git a/sysa/helpers.sh b/sysa/helpers.sh
@@ -40,21 +40,26 @@ build () {
fi
echo "${pkg}: unpacking source."
- call src_unpack
+ build_stage=src_unpack
+ call $build_stage
cd "${pkg}" || (echo "Cannot cd into build/${pkg}!"; kill $$)
echo "${pkg}: preparing source."
- call src_prepare
+ build_stage=src_prepare
+ call $build_stage
echo "${pkg}: configuring source."
- call src_configure
+ build_stage=src_configure
+ call $build_stage
echo "${pkg}: compiling source."
- call src_compile
+ build_stage=src_compile
+ call $build_stage
echo "${pkg}: installing."
- call src_install
+ build_stage=src_install
+ call $build_stage
cd ../..
@@ -139,3 +144,8 @@ call() {
default_"${1}"
fi
}
+
+# Call default build stage function
+default() {
+ "default_${build_stage}"
+}
diff --git a/sysa/libtool-1.4/libtool-1.4.sh b/sysa/libtool-1.4/libtool-1.4.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
AUTOCONF=autoconf-2.13 AUTOHEADER=autoheader-2.13 ACLOCAL=aclocal-1.4 AUTOMAKE=automake-1.4 ./bootstrap
diff --git a/sysa/mpc-1.2.1/mpc-1.2.1.sh b/sysa/mpc-1.2.1/mpc-1.2.1.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
find . -name '*.info' -delete
autoreconf-2.69 -fi
diff --git a/sysa/mpfr-4.1.0/mpfr-4.1.0.sh b/sysa/mpfr-4.1.0/mpfr-4.1.0.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
find . -name '*.info' -delete
autoreconf-2.69 -fi
diff --git a/sysa/musl-1.1.24/binutils-rebuild.sh b/sysa/musl-1.1.24/binutils-rebuild.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
# tcc does not support complex types
rm -rf src/complex
diff --git a/sysa/musl-1.1.24/musl-1.1.24.sh b/sysa/musl-1.1.24/musl-1.1.24.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
# tcc does not support complex types
rm -rf src/complex
diff --git a/sysa/perl-5.000/perl-5.000.sh b/sysa/perl-5.000/perl-5.000.sh
@@ -3,13 +3,13 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_unpack() {
- default_src_unpack
+ default
mv perl5-perl-5.000 perl-5.000
}
src_prepare() {
- default_src_prepare
+ default
# Remove and regenerate bison files
rm perly.c perly.h
diff --git a/sysa/perl-5.003/perl-5.003.sh b/sysa/perl-5.003/perl-5.003.sh
@@ -3,13 +3,13 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_unpack() {
- default_src_unpack
+ default
mv perl5-perl-5.003 perl-5.003
}
src_prepare() {
- default_src_prepare
+ default
# Regenerate bison files
rm perly.c perly.h
diff --git a/sysa/perl-5.6.2/perl-5.6.2.sh b/sysa/perl-5.6.2/perl-5.6.2.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
# Regenerate bison files
sed -i '/yydestruct/d' perly.y
@@ -37,5 +37,5 @@ src_install() {
# Remove old perl
rm -rf "${PREFIX}"/lib/perl5/
- default_src_install
+ default
}
diff --git a/sysa/perl5.004_05/perl5.004_05.sh b/sysa/perl5.004_05/perl5.004_05.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
# Regenerate bison files
rm perly.c perly.h
@@ -22,5 +22,5 @@ src_install() {
# Remove old perl
rm -rf "${PREFIX}"/lib/perl5/
- default_src_install
+ default
}
diff --git a/sysa/perl5.005_03/perl5.005_03.sh b/sysa/perl5.005_03/perl5.005_03.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
# Regenerate bison files
rm perly.c perly.h
@@ -26,5 +26,5 @@ src_install() {
# Remove old perl
rm -rf "${PREFIX}"/lib/perl5/
- default_src_install
+ default
}
diff --git a/sysa/sed-4.0.9/sed-4.0.9.sh b/sysa/sed-4.0.9/sed-4.0.9.sh
@@ -3,12 +3,12 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
cp lib/regex_.h lib/regex.h
touch config.h
}
src_install() {
- default_src_install
+ default
}
diff --git a/sysa/tar-1.34/tar-1.34.sh b/sysa/tar-1.34/tar-1.34.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
. ../../import-gnulib.sh
diff --git a/sysa/tcc-0.9.27/tcc-meslibc-rebuild.sh b/sysa/tcc-0.9.27/tcc-meslibc-rebuild.sh
@@ -4,7 +4,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
touch config.h
}
diff --git a/sysa/tcc-0.9.27/tcc-musl-pass1.sh b/sysa/tcc-0.9.27/tcc-musl-pass1.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
touch config.h
}
diff --git a/sysa/tcc-0.9.27/tcc-musl-pass2.sh b/sysa/tcc-0.9.27/tcc-musl-pass2.sh
@@ -4,7 +4,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
touch config.h
}
diff --git a/sysa/tcc-0.9.27/tcc-musl-pass3.sh b/sysa/tcc-0.9.27/tcc-musl-pass3.sh
@@ -4,7 +4,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
touch config.h
}
diff --git a/sysa/xz-5.0.5/xz-5.0.5.sh b/sysa/xz-5.0.5/xz-5.0.5.sh
@@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
- default_src_prepare
+ default
autoreconf-2.65 -f
}