You are not logged in.
I'm building Arch Linux on embedded system which CPU is sh4.
I found there is a problem of bash package.
It creates /bin/sh as a symbolic link to /usr/bin/bash.
But my /bin/sh is busybox.
1. I'm wonder how could I keep /bin/sh to busybox's /bin/sh? Or, it could set on pacman.conf?
2. Could my root account still use 'sh' as its shell? I wish busybox could still exist as the basement.
3. Is makepkg or yaourt based on root's shell must be bash?
Running 4 ArchLinux including sh4twbox,server,notebook,desktop. my AUR packages
Offline
IIRC, pacman requires bash. It doesn't have to be the login shell, but it has to exist. The login shell can be whatever you want.
Edit, let me clarify that a bit. Anything that needs bash calls bash specifically, so it doesn't matter what the root login shell is.
Last edited by Scimmia (2013-01-31 05:53:57)
Offline
Many of the Arch package post_install scriptlets are written assuming bash, and pacman uses /bin/sh as its shell. In 4.1, this will be configurable. Makepkg uses /bin/bash.
Offline
Thank you Allan,
I have this question is because /usr/bin/bash require many dynamic library and I just failed login my embedded system after upgrade bash with pacman -Udd option.
Am I right of the following assumption (Sorry, I can not 100% understand your meaning, require double confirm.).
1. I can keep my root's shell as /bin/sh (it's busybox version).
2. I can config pacman to use /bin/bash for install (I've compiled brand new pacman)
3. makepkg have forced to use /bin/bash for install
BTW, I found it is required bash 4.0 (declare function) My embedded system's original linux only provide bash 3.0. So, it took me a while to prepare bash 4.0.
Last edited by dlin (2013-01-31 06:42:22)
Running 4 ArchLinux including sh4twbox,server,notebook,desktop. my AUR packages
Offline
1 and 3 are right. 2 is only possible with the developmental version of pacman.
Offline
2. I can config pacman to use /bin/bash for install (I've compiled brand new pacman)
Since you are compiling pacman, you can simply replace /bin/sh with /usr/bin/bash in the source. And add /bin/sh to NoExtract in pacman.conf
| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |
Offline
Instead of assign /bin/bash, is it possible check do following to provide minimal dependency?
if /bin/bash exist and workable (link successful) then
call /bin/bash.
else
call /bin/sh
fi
Running 4 ArchLinux including sh4twbox,server,notebook,desktop. my AUR packages
Offline
where to found out the code of development pacman?
I've try search /bin/sh on the current downloaded pacman 4.0.3-5 source.
And the founding can not help to modify the source to force it to use /bin/bash.
The only line mentioned about /bin/sh is in download_with_xfercommand() of src/pacman/conf.c
But, I don't think it is correct place to modify it.
pm_printf(ALPM_LOG_DEBUG, "running command: %s\n", parsedcmd);
retval = system(parsedcmd);
I try to modify as
char buf[1024];
sprintf(buf, "/bin/bash -c %s", parsedcmd)
pm_printf(ALPM_LOG_DEBUG, "running command: %s\n", buf);
retval = system(buf);
Last edited by dlin (2013-02-04 05:58:05)
Running 4 ArchLinux including sh4twbox,server,notebook,desktop. my AUR packages
Offline