Overview
Request 1008386 accepted
- Add upstream patches
* bash52-001
Expanding unset arrays in an arithmetic context can cause a
segmentation fault.
* bash52-002
Starting bash with an invalid locale specification for
LC_ALL/LANG/LC_CTYPE can cause the shell to crash.
- Do not run checks in parallel as it eats memory, a lot of memory
- Disable alternate array implementation as it eats a lot of memory
- Update to final bash 5.2
a. When replacing a history entry, make sure the existing entry has a non-NULL
timestamp before copying it; it may have been added by the application, not
the history library.
- Modernize run-tests
- add checks
- Enable parallel builds by splitting clean and all at make time
- Update to bash 5.2 rc4
Pos. aa is now enabled by default.
m. Readline now checks for changes to locale settings (LC_ALL/LC_CTYPE/LANG)
each time it is called, and modifies the appropriate locale-specific display
- Port patches
* bash-2.03-manual.patch
* bash-5.2.dif
- Update to bash 5.2 rc2
gg. Since there is no `declare -' equivalent of `local -', make sure to use
- Created by WernerFink
- In state accepted
- Supersedes 1006370
Please use readline from SR#1006359 for testing, otherwise bash 5.2 does not build
Moving this and readline into Staging:L because it seems to break tcsh and tre and parking it in L will leave you the buildlogs while we get the rest of :C moving.
tcsh does not use (lib)readline ... clisp does ... and
NetworkManager bc parted libisoburn1 libgjs0 socat lua53 lua51 usbprog perl-TermReadLine-Gnu x3270 unixODBC multipath-tools ntp ipmitool OpenIPMI fontforge clisp texlive-asymptote-bin pipewire-tools libvirt-client libvirt-daemon fvwm2 gnuplot keepassxc nftables hunspell python python3 augeas gpg2 libxml2-tools util-linux zypper bluez bluez-test lvm2 samba-client gdb ruby2.5-stdlib
Well then if I'm wrong then the outcome of this shuffling of stagings will be bash and readline will get in Factory faster than :C which will still be broken after the rebuild..time will tell, comments will follow :)
I debugged the tcsh issue. It's because bash 5.2 uses implicit exec in more cases now:
Before:
abuild@fussheizung:~/rpmbuild/BUILD/tcsh-6.24.01> (SHLVL=5 printenv SHLVL) 4 abuild@fussheizung:~/rpmbuild/BUILD/tcsh-6.24.01> (:; SHLVL=5 printenv SHLVL) 5 abuild@fussheizung:~/rpmbuild/BUILD/tcsh-6.24.01> bash --version GNU bash, version 5.1.16(1)-release (x86_64-suse-linux)
After:
abuild@fussheizung:~/rpmbuild/BUILD/tcsh-6.24.01> (SHLVL=5 printenv SHLVL) 4 abuild@fussheizung:~/rpmbuild/BUILD/tcsh-6.24.01> (:; SHLVL=5 printenv SHLVL) 4 abuild@fussheizung:~/rpmbuild/BUILD/tcsh-6.24.01> bash --version GNU bash, version 5.2.0(1)-release (x86_64-suse-linux)
Using env
to avoid the SHLVL decrement makes it work. The GH fork accepts PRs apparently, so I opened https://github.com/tcsh-org/tcsh/pull/53
See SR#1007204 with patch tcsh-6.24.01-bash52.dif
erner/tcsh> cat tcsh-6.24.01-bash52.dif --- tcsh-6.24.01/tests/variables.at +++ tcsh-6.24.01/tests/variables.at 2022-09-30 08:56:23.296533116 +0000 @@ -964,7 +964,7 @@ tcsh -f -c 'tcsh -f -c "printenv SHLVL"' tcsh -f -c 'exec tcsh -f -c "printenv SHLVL"' tcsh -f -c '(exec tcsh -f -c "printenv SHLVL")' ]]) -AT_CHECK([SHLVL=5 tcsh -f shlvl.csh], , +AT_CHECK([SHLVL=5 tcsh -f shlvl.csh;:], , [6 8 2
The tre
failure is weird. The testsuite is wrong and it should actually fail!
exitstatus.args
:
# Some errors which should give exit status 2. -d .* dummy
But: exitstatus.ok
has:
#### TEST: agrep -d .* dummy exitstatus.in Exit status 1.
It should actually fail with Exit status 2
because .*
should trigger this error:
abuild@fussheizung:~/rpmbuild/BUILD/tre-0.8.0_git201402282055> src/agrep -d .* dummy exitstatus.in; echo $? agrep: Record delimiter pattern must not match an empty string 2
Those lines
[ 72s] -/usr/src/debug/tre-0.8.0_git201402282055/src/agrep.c 0 (none) 100644 root root 0 4294967295 [...] [ 72s] +/usr/src/debug/tre-@ VERSION@-@ RELEASE_LONG@ .x86_64/src/agrep.c 0 (none) 100644 root root 0 4294967295
are also fishy
It's a bug in the test script that it works at all...
The root cause is a behaviour change in bash 5.2. Before:
abuild@fussheizung:~> echo .* . .. .bash_history .lesshst .rpmmacros .rpmrc .viminfo abuild@fussheizung:~> bash --version GNU bash, version 5.1.16(1)-release (x86_64-suse-linux)
With bash 5.2, it no longer matches .
and ..
!
abuild@fussheizung:~> echo .* .bash_history .lesshst .rpmmacros .rpmrc .viminfo abuild@fussheizung:~> bash --version GNU bash, version 5.2.0(1)-release (x86_64-suse-linux)
The bug in the tre test script is as follows: exitstatus.args
contains the line -d .* dummy
. This is meant to be passed as three separate arguments to agrep. To achieve that, run-tests.sh
does:
for arg in `cat $args`; do ... $agrep $extra $arg $input >> $out ...
However, this causes glob expansion, so .*
is expanded to . ..
. This totally changes the result... With bash 5.2, there are no matches so .*
stays as-is. Question is how to escape this properly so that glob expansion doesn't happen. Or just skip this case, tre is dead anyway.
shopt -u globskipdots
does shwitch back
... a line like
shopt -u globskipdots 2> /dev/null || :
will help here
Maybe replacing /bin/sh with an other shell will help as this where the new bash is used in e.g. tests/agrep/run-tests.sh
Request History
WernerFink created request
- Add upstream patches
* bash52-001
Expanding unset arrays in an arithmetic context can cause a
segmentation fault.
* bash52-002
Starting bash with an invalid locale specification for
LC_ALL/LANG/LC_CTYPE can cause the shell to crash.
- Do not run checks in parallel as it eats memory, a lot of memory
- Disable alternate array implementation as it eats a lot of memory
- Update to final bash 5.2
a. When replacing a history entry, make sure the existing entry has a non-NULL
timestamp before copying it; it may have been added by the application, not
the history library.
- Modernize run-tests
- add checks
- Enable parallel builds by splitting clean and all at make time
- Update to bash 5.2 rc4
Pos. aa is now enabled by default.
m. Readline now checks for changes to locale settings (LC_ALL/LC_CTYPE/LANG)
each time it is called, and modifies the appropriate locale-specific display
- Port patches
* bash-2.03-manual.patch
* bash-5.2.dif
- Update to bash 5.2 rc2
gg. Since there is no `declare -' equivalent of `local -', make sure to use
factory-auto added opensuse-review-team as a reviewer
Please review sources
factory-auto accepted review
Check script succeeded
staging-bot set openSUSE:Factory:Staging:A as a staging project
Being evaluated by staging project "openSUSE:Factory:Staging:A"
staging-bot accepted review
Picked "openSUSE:Factory:Staging:A"
licensedigger accepted review
The legal review is accepted preliminary. The package may require actions later on.
RBrownSUSE accepted review
RBrownFactory accepted review
Staging Project openSUSE:Factory:Staging:A got accepted.
RBrownFactory approved review
Staging Project openSUSE:Factory:Staging:A got accepted.
RBrownFactory accepted request
Staging Project openSUSE:Factory:Staging:A got accepted.
Fix for tre: https://build.opensuse.org/request/show/1009751