[uClibc]compiling bash 1.14.7 with uClibc

Matthew Berg galt at gothpoodle.com
Sun Mar 4 15:26:45 UTC 2001


Has anyone successfully done this?  I've run into a few issues in my
attempts. 

The first problem is that it errors out on conflicting types in the uClibc
between stdlib.h and varargs.h (e.g. va_start, va_end, etc).  As a cheat
workaround, I just commented out the line in cpp-Makefile that defined
-DHAVE_VARARGS.

Next I ran into a problem with the built-in getopts support:

subst.c: In function `sv_opterr':
subst.c:4853: `sh_opterr' undeclared (first use in this function)
subst.c:4853: (Each undeclared identifier is reported only once
subst.c:4853: for each function it appears in.)

I assumed this was just something not implemented in uClibc yet, so I
disabled the getopts, seeing as I don't really need it.

Now the problem I'm having is that I can't generate the version.h
file.  This is supposed to be created by the newversion.aux program, which
*compiles* fine with uClibc, but fails to run.  The stace trace shows it
failing on an ioctl call:

personality(PER_LINUX)                  = 0
ioctl(1, TCGETS, 0xbffffa1c)            = -1 EINVAL (Invalid argument)
old_mmap(NULL, 14, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, 0,
0) = 0x40008000
old_mmap(NULL, 32, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, 0,
0) = 0x40009000
open(".distribution", O_RDONLY)         = 3
old_mmap(NULL, 512, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, 0,
0) = 0x4000a000
ioctl(3, TCGETS, 0xbffff938)            = -1 ENOTTY (Inappropriate ioctl
for device)
munmap(0x40008000, 0)                   = -1 EINVAL (Invalid argument)
read(3, "1.14\n", 512)                  = 5
write(2, "L", 1L)                        = 1
write(2, "I", 1I)                        = 1
write(2, "B", 1B)                        = 1
write(2, "C", 1C)                        = 1
write(2, ":", 1:)                        = 1
write(2, "S", 1S)                        = 1
write(2, "C", 1C)                        = 1
write(2, "A", 1A)                        = 1
write(2, "N", 1N)                        = 1
write(2, "F", 1F)                        = 1
_exit(-1)                               = ?

Any ideas?

Matt






More information about the uClibc mailing list