* updated linux (6.11.3 -> 6.11.4)
[t2sde.git] / package / shells / bash / bash.conf
blobde041754a9505c11f82cdd92782ec63feec9419f
1 # --- T2-COPYRIGHT-NOTE-BEGIN ---
2 # T2 SDE: package/*/bash/bash.conf
3 # Copyright (C) 2004 - 2024 The T2 SDE Project
4 # Copyright (C) 1998 - 2003 ROCK Linux Project
5
6 # This Copyright note is generated by scripts/Create-CopyPatch,
7 # more information can be found in the files COPYING and README.
8
9 # This program is free software; you can redistribute it and/or modify
10 # it under the terms of the GNU General Public License version 2.
11 # --- T2-COPYRIGHT-NOTE-END ---
13 bash_which=1
15 # work around erros such as: -ReneR
16 # mkbuiltins.o:(.text+0x768): undefined reference to `x__nldbl_fprintf'
17 # mkbuiltins.o:(.text+0x9e8): undefined reference to `x__nldbl_sprintf'
18 atstage native || var_append makeopt ' ' 'CFLAGS_FOR_BUILD='
20 if ! atstage native; then
21         var_append confopt ' ' '--without-emacs' # tries to run it anyway, so:
22         export EMACS=false
25 pkg_bash_postmake() {
26         if [ "$bash_which" = "1" ]; then
27                 echo "Creating 'usr/bin/which' and 'bin/sh' ..."
28                 echo -e '#!/bin/bash\ntype -p "$@"' > $root/usr/bin/which
29                 chmod +x $root/usr/bin/which
30         fi
32         mkdir -pv $root$datadir/bash-completion/completions
34         [ -f $root/usr/bin/bash ] && mv -v $root/usr/bin/bash $root/bin/bash
35         pkginstalled mksh || ln -sfv bash $root/bin/sh
38 pkg_bash_preconf() {
39         for x in `match_source_file -p 'bash..-...'`; do
40                 echo "Applying patch ${x##*/} ..."
41                 patch -p0 < $x
42         done
45 atstage native || var_append confopt ' ' '--without-lispdir'
46 atstage native || hook_add preconf 5 "echo 'bash_cv_job_control_missing=present' >> config.cache"
47 var_append confopt " " "--without-bash-malloc"
49 [ "$SDECFG_PKG_BASH_PROGCOMP" = 0 ] &&
50         var_append confopt " " "--disable-progcomp"
51 [ "$SDECFG_PKG_BASH_HELP_CMD" = 0 ] &&
52         var_append confopt " " "--disable-help-builtin"
54 hook_add preconf 5 "pkg_bash_preconf"
55 hook_add premake 5 "eval $MAKE $makeopt builtins/builtext.h" # parallel make
56 hook_add postmake 5 "pkg_bash_postmake"