Merge pull request #56 from pder/bash

bash-3.2.57: Build new package to replace bash 2.05b
This commit is contained in:
fosslinux 2021-03-06 10:17:03 +11:00 committed by GitHub
commit 6eb8d05e77
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 57 additions and 4 deletions

View File

@ -28,8 +28,9 @@ Get me started!
some other device and boot from bare metal.
5. Wait.
6. If you can, observe the many binaries in ``/after/bin``! (Soon, you will
also have an interactive bash shell to play around in).
6. If you can, observe the many binaries in ``/after/bin``! When the
bootstrap is completed ``bash`` is launched providing a shell to
explore the system.
Background
----------

View File

@ -3,6 +3,7 @@ f0611136bee505811e9ca11ca7ac188ef5323a8e2ef19cffd3edb3cf08fd791e autoconf-2.13.
534e99b61b81e79327b6d08f1a3edb0755ac246e1249009b0e1bf5887b60d7a9 autoconf-2.52.tar.gz
503cdc2b0992a4309545d17f462cb15f99bb57b7161dfc4082b2e7188f2bcc0f automake-1.4-p6.tar.gz
ba03d412998cc54bd0b0f2d6c32100967d3137098affdc2d32e6e7c11b163fe4 bash-2.05b.tar.gz
3fa9daf85ebf35068f090ce51283ddeeb3c75eb5bc70b1a4a7cb05868bfe06a4 bash-3.2.57.tar.gz
e20bdd49a0fb317959b410c1fe81269a620ec21207045d8a37cadea621be4b59 binutils-2.14.tar.bz2
7007fc89c216fbfaff5525359b02a7e5b612694df5168c74673f67055f015095 bison-3.4.1.tar.gz
ab5a03176ee106d3f0fa90e381da478ddae405918153cca248e682cd0c4a2269 bzip2-1.0.8.tar.gz

View File

@ -419,3 +419,12 @@ tcc 0.9.27 (musl v3)
====================
We rebuild tcc against new musl and without a patch to ignore duplicate symbols.
bash 3.2.57
===========
Up to this point, our build of ``bash`` could run scripts but could not be used
interactively. This newer version of ``bash`` compiles without any patches,
provides new features, and is built with GNU readline support so it can be used
as an interactive shell. autoconf 2.52 is used to regenerate the configure
script and bison is used to recreate some included generated files.

View File

@ -79,7 +79,7 @@ mkdir -p tmp/tmp
cp after.kaem tmp/
cp after.kaem.run tmp/after/kaem.run
cp mescc-tools-seed/checksums tmp/after/mescc-tools-seed-checksums
cp helpers.sh run.sh pre-sha.sha256sums tmp/after/
cp helpers.sh run.sh run2.sh pre-sha.sha256sums tmp/after/
# mescc-tools-extra
cp -r mescc-tools-extra tmp/after/
@ -219,6 +219,9 @@ get_file https://ftp.gnu.org/gnu/autoconf/autoconf-2.12.tar.gz
# binutils 2.14
get_file https://ftp.gnu.org/gnu/binutils/binutils-2.14.tar.bz2
# bash 3.2.57
get_file https://ftp.gnu.org/gnu/bash/bash-3.2.57.tar.gz
# General cleanup
find tmp -name .git -exec rm -rf \;

24
sysa/bash-3.2.57/bash-3.2.57.sh Executable file
View File

@ -0,0 +1,24 @@
# SPDX-FileCopyrightText: 2021 Paul Dersey <pdersey@gmail.com>
#
# SPDX-License-Identifier: GPL-3.0-or-later
src_prepare() {
# Remove bison generated files
rm y.tab.c y.tab.h
# Rebuild configure script
# Ignore harmless error from autoconf for now
rm configure
autoconf-2.52 || true
}
src_configure() {
CC=tcc CPPFLAGS="-D HAVE_ALLOCA_H" \
./configure --prefix=/after \
--without-bash-malloc \
--build=i386-unknown-linux
}
src_install() {
install bash ${bindir}
}

View File

@ -0,0 +1 @@
0d6cbaa5f93fa4c2186ef40dd834b47841b3bf70f6183cfdb6ada38fdb835c5a /after/bin/bash

View File

@ -91,4 +91,6 @@ populate_device_nodes
# Rebuild tcc-musl using new musl
build tcc-0.9.27 tcc-musl-pass3.sh checksums/tcc-musl-pass3
echo "Bootstrapping completed."
build bash-3.2.57
exec bash run2.sh

12
sysa/run2.sh Executable file
View File

@ -0,0 +1,12 @@
#!/bin/bash
# SPDX-FileCopyrightText: 2021 Andrius Štikonas <andrius@stikonas.eu>
# SPDX-FileCopyrightText: 2021 fosslinux <fosslinux@aussies.space>
# SPDX-FileCopyrightText: 2021 Paul Dersey <pdersey@gmail.com>
#
# SPDX-License-Identifier: GPL-3.0-or-later
set -e
. helpers.sh
echo "Bootstrapping completed."