Busybox make, modify my /dev/null on host

Christian MICHON christian.michon at gmail.com
Wed Feb 13 22:30:42 UTC 2008


On Feb 13, 2008 10:55 PM, Martinb_ARM_NOMMU_KISSDVD
<martinb at zeelandnet.nl> wrote:
> anyhow, I will have the rest (remnant?) of my life to find a solution on the
> toolchain

time to jump into this thread.

personally: I'm tired of this constant "your toolchain is too old"
"please upgrade", etc...
it's counter productive: some of us in the industry have sometimes to
support old code on old toolchains.

seriously, back to the issue. I understand from the thread:
1) gcc used to work
2) something happened
3) building busybox from then on give the "/dev/null" crap
4) you're clueless.

It just happened to me too. But I'm sure my toolchain is not broken,
because it's working fine usually.

So I did some bisect to figure out what I introduced in the system
that "broke" the toolchain...
And I believe I found it.

1) was your original toolchain built without nls and gettext ?
  if yes -> 2

2) did you build gettext and libintl recently ?
 if yes -> 3

3) did you get error messages since (/dev/null is just one symptom out of many)
if yes, then I've a fix for you.

the truth is that your toolchain is not broken.
But now busybox sees libintl & gettext and *assumes* (hint: the pb is
in busybox) that your toolchain will link versus libintl.

2 ways out:

1) remove libintl & gettext (but this is not the right fix). if you
erase libintl.h in /include or /usr/include, the /dev/null error
disappears

2) modify the specs file of your toolchain (that is the so called
breakage, but no recompilation is needed) and perform this

sed -e 's/%{shared:-lc}/%{!nointl: -lintl} &/' \
	-i `${target}-gcc --print-file specs`

this line above is from
http://www.linuxfromscratch.org/hints/downloads/files/uclibc.txt

from now on, not only the "/dev/null" problem goes away, but also link
problems around gettext api.
even better: nobody shall tell you pointlessly to upgrade what you
value so much and trust more than new code: your favorite toolchain.

my 2 cents. and this fix will be in the next release of DetaolB (based
on old but reliable gcc-3.4.6, link in my signature)

-- 
Christian
--
http://detaolb.sourceforge.net/, a linux distribution for Qemu with Git inside !



More information about the busybox mailing list