[pocket-linux] Problems compiling static BASH on FC3 (& fix!)
Ian McCrum
IJ.McCrum at ulster.ac.uk
Sun May 1 07:11:35 CDT 2005
I am using Fedora core 3, kept up to date as at mid april.
When I try to compile BASH statically as per section 2.3.9 in Pocket
Linux 3-1 I get an error.
The fix for this is to use the flags below, these add two extra options
to ./configure, --disable-nls disables international language support,
the README in the BASH tar file mentions it needing dynamic libraries.
The --without-bash-malloc option forces gcc to use the glibc malloc
routines instead of the ones built in to BASH - there was a warning in
the Linux-From-Scratch notes that gave me the clue to that one.
- - - - 8< - - - - 8< - - - - 8< - - - - 8<- - - - 8< - - - - 8<- - - -
8< - - - - 8<
2.3.9
...
bash# cd /usr/src/bash-3.0
bash# export CC="gcc -mcpu=i386"
bash# ./configure --enable-static-link \
--enable-minimal-config --host=i386-pc-linux-gnu \
--disable-nls --without-bash-malloc
bash# make
bash# strip bash
- - - - 8< - - - - 8< - - - - 8< - - - - 8<- - - - 8< - - -
I also found other alternatives such as SASH a statically compiled BASH and busybox, but there is
more education in doing it the pocket linux guide way.
I have used Pocket Linunx guide to give my students a better (and quick) understanding of how Linux works,
from switch on. It is an excellent guide. It complements nicely Linux_from_scratch, which is more
interesting but takes a long time to work through.
We used Kernel 2.6 and had a lot of bother getting a Kernel to fit on a
floppy - at least a kernel with much functionality. In hindsight I think
I would have recommended they use a 2.4 kernel. It would also be useful
if someone could post a .config with more explanation.
Regards to the list, and David, good job!
Ian McCrum
More information about the Pocket-Linux
mailing list