musl-cross: pin to a specific checkout (#617)

Add `--strip 1` to tar file extraction in the `Makefile`,
which ensures that the directory name in `build/` will
match the one listed in `$($(MODULE)_dir)`.

Signed-off-by: Trammell hudson <hudson@trmm.net>
This commit is contained in:
Trammell hudson 2019-10-29 13:15:56 +01:00
parent 4f0e778582
commit 56aa508b8d
No known key found for this signature in database
GPG Key ID: 0F948052DDECBE68
3 changed files with 21 additions and 6 deletions

View File

@ -264,9 +264,10 @@ define define_module =
# Unpack the tar file and touch the canary so that we know # Unpack the tar file and touch the canary so that we know
# that the files are all present # that the files are all present
$(build)/$($1_base_dir)/.canary: $(packages)/.$1-$($1_version)_verify $(build)/$($1_base_dir)/.canary: $(packages)/.$1-$($1_version)_verify
tar -xf "$(packages)/$($1_tar)" -C "$(build)" mkdir -p "$$(dir $$@)"
tar -xf "$(packages)/$($1_tar)" --strip 1 -C "$$(dir $$@)"
if [ -r patches/$1-$($1_version).patch ]; then \ if [ -r patches/$1-$($1_version).patch ]; then \
( cd $(build)/$($1_base_dir) ; patch -p1 ) \ ( cd $$(dir $$@) ; patch -p1 ) \
< patches/$1-$($1_version).patch \ < patches/$1-$($1_version).patch \
|| exit 1 ; \ || exit 1 ; \
fi fi
@ -274,7 +275,7 @@ define define_module =
[ -r patches/$1-$($1_version) ] ; then \ [ -r patches/$1-$($1_version) ] ; then \
for patch in patches/$1-$($1_version)/*.patch ; do \ for patch in patches/$1-$($1_version)/*.patch ; do \
echo "Applying patch file : $$$$patch " ; \ echo "Applying patch file : $$$$patch " ; \
( cd $(build)/$($1_base_dir) ; patch -p1 ) \ ( cd $$(dir $$@) ; patch -p1 ) \
< $$$$patch \ < $$$$patch \
|| exit 1 ; \ || exit 1 ; \
done ; \ done ; \

View File

@ -23,9 +23,11 @@ else
# Force a full build of the cross compiler # Force a full build of the cross compiler
modules-y += musl-cross modules-y += musl-cross
musl-cross_version := git musl-cross_version := 81d563e
musl-cross_dir := musl-cross-$(musl-cross_version) musl-cross_dir := musl-cross
musl-cross_repo := https://github.com/GregorR/musl-cross musl-cross_url := https://github.com/GregorR/musl-cross/archive/$(musl-cross_version).tar.gz
musl-cross_tar := musl-cross-$(musl-cross_version).tar.gz
musl-cross_hash := 6362751b2442dc273c0889e5ef3ce6306a38b9c415cbe8cb4cfe3b8c6d776e96
CROSS_TOP := crossgcc/x86_64-linux-musl/bin/x86_64-musl-linux- CROSS_TOP := crossgcc/x86_64-linux-musl/bin/x86_64-musl-linux-
CROSS := $(build)/../$(CROSS_TOP) CROSS := $(build)/../$(CROSS_TOP)

View File

@ -36,3 +36,15 @@ index ec3c1ce..844fb3d 100644
# uncomment these to get smaller/stripped binaries # uncomment these to get smaller/stripped binaries
#export CFLAGS="-Os -g0 -s" #export CFLAGS="-Os -g0 -s"
#export CXXFLAGS="-Os -g0" #export CXXFLAGS="-Os -g0"
--- /dev/null 2019-10-28 16:42:28.211999999 +0100
+++ musl-cross/hashes/gmp-6.1.0.tar.bz2.sha256 2019-10-29 13:08:53.288687684 +0100
@@ -0,0 +1 @@
+498449a994efeba527885c10405993427995d3f86b8768d8cdf8d9dd7c6b73e8 gmp-6.1.0.tar.bz2
--- /dev/null 2019-10-28 16:42:28.211999999 +0100
+++ musl-cross/hashes/mpfr-3.1.4.tar.bz2.sha256 2019-10-29 13:08:53.292687684 +0100
@@ -0,0 +1 @@
+d3103a80cdad2407ed581f3618c4bed04e0c92d1cf771a65ead662cc397f7775 mpfr-3.1.4.tar.bz2
--- /dev/null 2019-10-28 16:42:28.211999999 +0100
+++ musl-cross/hashes/mpc-1.0.3.tar.gz.sha256 2019-10-29 13:08:53.296687684 +0100
@@ -0,0 +1 @@
+617decc6ea09889fb08ede330917a00b16809b8db88c29c31bfbb49cbf88ecc3 mpc-1.0.3.tar.gz