Overview
Request 683701 accepted
- Update temporary patch from upstream to make sed testsuite
work again
- Requires(postun) -> Requires(preun)
- Do not link /bin/sh as slave alternative to /usr/bin/sh
- Add temporary patch from upstream to fix boo#1127700
- Refine and harden update-alternatives work flow
- Move header and Makefile from bash-loadables to bash-devel
- Make update-alternatives work flawless
- Put "sh" under control of update-alternatives
- Created by WernerFink
- In state accepted
- Supersedes 681811
With this submit there is the (old) new issue that to get /bin/sh, one always needs to have bash.rpm installed. It is no longer possible that dash provide this entity (by way of using e.g. u-a).
Hmmm ... maybe the link from /usr/bin/sh to /bin/sh should be part of the package aaa_base or an other base package required by every bourne shell clone. Nevertheless I in doubt that there would be an installation without an installed bash package as many basic scripts are bash scriptrs in their shebang as well as the common login shell is the bash ..
Maybe it would an idea that ervery package, which provides a bourne shell clone and does use update-alternatives to fulfil the /usr/bin/sh link., should provide the tag e.g. bourne-shell (or simply /usr/bin/sh). Then it would be possible that bash.spec includes a further package "sh" which requires then exactly this tag and only consists of the /bin/sh -> /usr/bin/sh link in its %file section ...
That was the original thought. I would generate that "sh" package from filesystem.spec however, so it does not build-depend on bash (basically just a time saver not waiting for the build to finish).
OK ... that requires that bash depends on the version of the package filesystem (or (build)requires its self /bin/sh). This works however if filesystem is ready and does not conflict with (old) package bash ;)
sed's test suite also fails:
https://build.opensuse.org/package/live_build_log/openSUSE:Factory:Staging:B/sed/standard/x86_64
Hmmm .. is this coincidence a causal with the /bin/sh change or casual
I only have bash in this staging - so co-incidence does not sound right... I'll try to extract better info from the logs and the test cases to see what goes wrong
ok - I think the swed failure is actually a consequence of the patch added here - NOT the update-alternatives change.
The test does, in summary:
echo > in printf '\233\375\200\n' > exp-out LC_ALL=en_US.utf8 sed $(printf 's/^/\\L\233\375\\\200/') in > out
and then compare in and out... in case of 'previous' bash, this was correct and matched.
NEW bash, as submitted here, get's a diff as the 'L' is preceeding the output
Ouch ... YaOB (Yet an Other Bug) with the new bash 5.0 line parser ;)
Request History
WernerFink created request
- Update temporary patch from upstream to make sed testsuite
work again
- Requires(postun) -> Requires(preun)
- Do not link /bin/sh as slave alternative to /usr/bin/sh
- Add temporary patch from upstream to fix boo#1127700
- Refine and harden update-alternatives work flow
- Move header and Makefile from bash-loadables to bash-devel
- Make update-alternatives work flawless
- Put "sh" under control of update-alternatives
factory-auto added opensuse-review-team as a reviewer
Please review sources
factory-auto accepted review
Check script succeeded
licensedigger accepted review
ok
dimstar_suse set openSUSE:Factory:Staging:B as a staging project
Being evaluated by staging project "openSUSE:Factory:Staging:B"
dimstar_suse accepted review
Picked openSUSE:Factory:Staging:B
dimstar accepted review
dimstar_suse accepted review
ready to accept
dimstar_suse approved review
ready to accept
dimstar_suse accepted request
Accept to openSUSE:Factory
I don't think we should be pushing update-alternatives here until the build process is able to warn developers when they are using bashism's in #!/bin/sh