bash/PKGBUILD

110 lines
3.4 KiB
Bash
Raw Normal View History

2018-06-13 12:35:29 +02:00
# Maintainer: Bernhard Landauer <oberon@manjaro.org>
2018-06-03 16:18:25 +02:00
# Maintainer: Bartłomiej Piotrowski <bpiotrowski@archlinux.org>
# Contributor: Allan McRae <allan@archlinux.org>
# Contributor: Aaron Griffin <aaron@archlinux.org>
2018-06-13 12:35:29 +02:00
pkgbase=bash
pkgname=('bash' 'bashrc-manjaro')
2019-01-13 16:57:28 +01:00
_basever=5.0
2019-08-20 17:14:03 +02:00
_patchlevel=009
2018-06-03 16:18:25 +02:00
pkgver=${_basever}.${_patchlevel}
2019-05-11 18:19:02 +02:00
pkgrel=1
2018-06-13 13:22:55 +02:00
arch=('i686' 'x86_64')
2018-06-03 16:18:25 +02:00
license=('GPL')
url='http://www.gnu.org/software/bash/bash.html'
groups=('base')
2018-06-13 12:35:29 +02:00
source=(https://ftp.gnu.org/gnu/bash/bash-$_basever.tar.gz{,.sig}
'dot.bashrc'
'dot.bash_profile'
'dot.bash_logout'
'system.bashrc'
'system.bash_logout')
2019-01-13 16:57:28 +01:00
md5sums=('2b44b47b905be16f45709648f671820b'
'SKIP'
2019-08-20 17:14:03 +02:00
'f6d012f6bed87567b0df448a5a3a78f2'
2019-01-13 16:57:28 +01:00
'2902e0fee7a9168f3a4fd2ccd60ff047'
'42f4400ed2314bd7519c020d0187edc5'
'd8f3f334e72c0e30032eae1a1229aef1'
2019-04-15 00:16:09 +02:00
'472f536d7c9e8250dc4568ec4cfaf294'
'b026862ab596a5883bb4f0d1077a3819'
'SKIP'
'2f4a7787365790ae57f36b311701ea7e'
'SKIP'
'af7f2dd93fd5429fb5e9a642ff74f87d'
2019-05-11 18:19:02 +02:00
'SKIP'
'b60545b273bfa4e00a760f2c648bed9c'
'SKIP'
'875a0bedf48b74e453e3997c84b5d8a4'
'SKIP'
'4a8ee95adb72c3aba03d9e8c9f96ece6'
'SKIP'
'411560d81fde2dc5b17b83c3f3b58c6f'
2019-08-20 17:14:03 +02:00
'SKIP'
'dd7cf7a784d1838822cad8d419315991'
'SKIP'
'c1b3e937cd6dccbb7fd772f32812a0da'
2019-04-15 00:16:09 +02:00
'SKIP')
2018-06-13 12:35:29 +02:00
validpgpkeys=('7C0135FB088AAF6C66C650B9BB5869F064EA74AB') # Chet Ramey
if [[ $((10#${_patchlevel})) -gt 0 ]]; then
for (( _p=1; _p<=$((10#${_patchlevel})); _p++ )); do
source=(${source[@]} https://ftp.gnu.org/gnu/bash/bash-$_basever-patches/bash${_basever//.}-$(printf "%03d" $_p){,.sig})
done
fi
prepare() {
2018-06-13 13:22:55 +02:00
cd $pkgbase-$_basever
2018-06-13 12:35:29 +02:00
for (( _p=1; _p<=$((10#${_patchlevel})); _p++ )); do
msg "applying patch bash${_basever//.}-$(printf "%03d" $_p)"
patch -p0 -i ../bash${_basever//.}-$(printf "%03d" $_p)
done
}
build() {
2018-06-13 13:22:55 +02:00
cd $pkgbase-$_basever
2018-06-13 12:35:29 +02:00
_bashconfig=(-DDEFAULT_PATH_VALUE=\'\"/usr/local/sbin:/usr/local/bin:/usr/bin\"\'
-DSTANDARD_UTILS_PATH=\'\"/usr/bin\"\'
-DSYS_BASHRC=\'\"/etc/bash.bashrc\"\'
-DSYS_BASH_LOGOUT=\'\"/etc/bash.bash_logout\"\'
-DNON_INTERACTIVE_LOGIN_SHELLS)
export CFLAGS="${CFLAGS} ${_bashconfig[@]}"
./configure --prefix=/usr --with-curses --enable-readline \
--without-bash-malloc --with-installed-readline
make
}
check() {
make -C $pkgname-$_basever check
}
package_bash() {
2018-06-13 12:51:15 +02:00
pkgdesc='The GNU Bourne Again shell'
2018-06-13 18:55:02 +02:00
backup=(etc/bash.bash_logout etc/skel/.bash{_profile,_logout})
2018-06-13 20:59:36 +02:00
depends=('bashrc'
'glibc'
2018-06-13 12:35:29 +02:00
'ncurses'
'readline>=7.0')
optdepends=('bash-completion: for tab completion')
provides=('sh')
make -C $pkgname-$_basever DESTDIR="$pkgdir" install
ln -s bash "$pkgdir"/usr/bin/sh
# system-wide configuration files
install -Dm644 system.bash_logout "$pkgdir"/etc/bash.bash_logout
# user configuration file skeletons
install -Dm644 dot.bash_profile "$pkgdir"/etc/skel/.bash_profile
install -m644 dot.bash_logout "$pkgdir"/etc/skel/.bash_logout
}
2018-06-13 18:55:02 +02:00
package_bashrc-manjaro() {
2018-06-13 13:22:55 +02:00
pkgdesc="Manjaro's default bashrc"
2018-06-13 12:51:15 +02:00
arch=('any')
2019-04-29 21:11:24 +02:00
backup=('etc/bash.bashrc' 'etc/skel/.bashrc')
2018-06-13 12:35:29 +02:00
depends=('bash')
provides=('bashrc')
2018-06-13 13:22:55 +02:00
install -Dm644 system.bashrc "$pkgdir"/etc/bash.bashrc
2018-06-13 12:35:29 +02:00
install -Dm644 dot.bashrc "$pkgdir"/etc/skel/.bashrc
}