SUMMARY="The GNU Bourne Again Shell" DESCRIPTION="Bash is an sh-compatible command language interpreter that \ executes commands read from the standard input or from a file. Bash also \ incorporates useful features from the Korn and C shells (ksh and csh)." HOMEPAGE="https://www.gnu.org/software/bash/" COPYRIGHT="1987-2020 Free Software Foundation, Inc." LICENSE="GNU GPL v3" REVISION="1" SOURCE_URI="https://ftpmirror.gnu.org/bash/bash-5.1.tar.gz" for i in {001..008}; do eval "SOURCE_URI_$i=\"https://ftpmirror.gnu.org/bash/bash-5.1-patches/bash51-$i#noarchive\"" done CHECKSUM_SHA256="cc012bc860406dcf42f64431bcd3d2fa7560c02915a601aba9cd597a39329baa" CHECKSUM_SHA256_001="ebb07b3dbadd98598f078125d0ae0d699295978a5cdaef6282fe19adef45b5fa" CHECKSUM_SHA256_002="15ea6121a801e48e658ceee712ea9b88d4ded022046a6147550790caf04f5dbe" CHECKSUM_SHA256_003="22f2cc262f056b22966281babf4b0a2f84cb7dd2223422e5dcd013c3dcbab6b1" CHECKSUM_SHA256_004="9aaeb65664ef0d28c0067e47ba5652b518298b3b92d33327d84b98b28d873c86" CHECKSUM_SHA256_005="cccbb5e9e6763915d232d29c713007a62b06e65126e3dd2d1128a0dc5ef46da5" CHECKSUM_SHA256_006="75e17d937de862615c6375def40a7574462210dce88cf741f660e2cc29473d14" CHECKSUM_SHA256_007="acfcb8c7e9f73457c0fb12324afb613785e0c9cef3315c9bbab4be702f40393a" CHECKSUM_SHA256_008="f22cf3c51a28f084a25aef28950e8777489072628f972b12643b4534a17ed2d1" SOURCE_DIR="bash-5.1" PATCHES=" bash-kill_by_name.patch bash-5.0.patchset " ARCHITECTURES="all" PROVIDES=" bash = $portVersion cmd:bash = $portVersion cmd:bashbug = $portVersion cmd:sh " REQUIRES=" haiku lib:libhistory lib:libreadline lib:libncursesw lib:libintl lib:libiconv " BUILD_REQUIRES=" haiku_devel devel:libhistory >= 8 devel:libreadline >= 8 devel:libncursesw devel:libintl " BUILD_PREREQUIRES=" cmd:autoconf cmd:awk cmd:bison cmd:cmp cmd:gcc cmd:make cmd:patch cmd:sed " GLOBAL_WRITABLE_FILES="settings/bashrc keep-old" PATCH() { cd $sourceDir for i in {001..008}; do echo "Applying patch $i..." eval f=\$sourceDir$i/bash51-$i sed -e "s|\.\./bash-5.1/||" "$f" | patch -p0 done # store bash settings under ~/config/settings find -type f -name "*.c" -o -name "*.def" -o -name "*.h" -o -name "*.1" \ | xargs sed -i -e 's,~/\.,~/config/settings/,g' } BUILD() { CPPFLAGS="-DUSE_MKTEMP=1 -DUSE_MKSTEMP=1" runConfigure ./configure \ --without-bash-malloc --with-installed-readline make $jobArgs } INSTALL() { make install-strip ln -s bash $binDir/sh # Use bash-completion, if available cat <<'EOF' > $settingsDir/bashrc #!/bin/bash [[ $PS1 && -f /system/data/bash-completion/bash_completion ]] && \ . /system/data/bash-completion/bash_completion EOF } TEST() { make check }