Hi Lance,
Lance Fredrickson wrote,

> On 10/6/2016 10:43 AM, Waldemar Brodkorb wrote:
> >Hi,
> >Lance Fredrickson wrote,
> >
> >>Using uclibc-ng 1.0.18, binaries linked against dynamic libc.so seems to
> >>work just fine.  Binaries created completely statically are non-responsive,
> >>and freeze up on the console.  A few binaries I've tried are openvpn, tinc,
> >>transmission-daemon.  I have to send SIGKILL to terminate the process.  A
> >>simple hello world did compile and run fine though, so possibly having to do
> >>with additional functionality placed into libc.a.
> >>
> >>Here's a strace of one binary if that offers any insight.
> >>
> >>root@R7000:~/src/tinc-1.1pre14/src# strace ./tinc --version
> >>execve("./tinc", ["./tinc", "--version"], [/* 24 vars */]) = 0
> >>brk(NULL)                               = 0x1ef000
> >>brk(0x1efcb4)                           = 0x1efcb4
> >>set_tls(0x1ef490, 0x1c4220, 0x1e9418, 0x1e8bd8, 0x4) = 0
> >>set_tid_address(0x1ef068)               = 9961
> >>set_robust_list(0x1ef070, 12)           = -1 ENOSYS (Function not
> >>implemented)
> >>rt_sigaction(SIGRTMIN, {0x165014, [], SA_RESTORER|SA_SIGINFO, 0x14f058},
> >>NULL, 8) = 0
> >>rt_sigaction(SIGRT_1, {0x164ea0, [], SA_RESTORER|SA_RESTART|SA_SIGINFO,
> >>0x14f058}, NULL, 8) = 0
> >>rt_sigprocmask(SIG_UNBLOCK, [RTMIN RT_1], NULL, 8) = 0
> >>ugetrlimit(RLIMIT_STACK, {rlim_cur=8192*1024, rlim_max=RLIM_INFINITY}) = 0
> >>open("/dev/urandom", O_RDONLY)          = 3
> >>read(3, "\\\177t)", 4)                  = 4
> >>close(3)                                = 0
> >>ioctl(0, TCGETS, {B38400 opost isig icanon echo ...}) = 0
> >>ioctl(1, TCGETS, {B38400 opost isig icanon echo ...}) = 0
> >>rt_sigprocmask(SIG_SETMASK, ~[ILL TRAP BUS FPE SEGV RTMIN RT_1], [], 8) = 0
> >>rt_sigaction(SIGILL, {0x98734, ~[ILL TRAP BUS FPE SEGV RTMIN RT_1],
> >>SA_RESTORER, 0x14f04c}, {SIG_DFL, [], 0}, 8) = 0
> >>rt_sigprocmask(SIG_BLOCK, NULL, ~[ILL TRAP BUS FPE KILL SEGV STOP RTMIN
> >>RT_1], 8) = 0
> >>--- SIGILL {si_signo=SIGILL, si_code=ILL_ILLOPC, si_addr=0x98800} ---
> >>futex(0x1e5df0, FUTEX_WAIT_PRIVATE, 2, NULL
> >Hmm, illegal instruction.
> >Could you show gcc -v and sent me the binary, please.
> >Which architecture exactly?
> 
> # gcc -v
> Using built-in specs.
> COLLECT_GCC=gcc
> COLLECT_LTO_WRAPPER=/mmc/libexec/gcc/arm-buildroot-linux-uclibcgnueabi/6.1.0/lto-wrapper
> Target: arm-buildroot-linux-uclibcgnueabi
> Configured with: ../gcc-6.1.0/configure --prefix=/mmc
> --host=arm-buildroot-linux-uclibcgnueabi
> --target=arm-buildroot-linux-uclibcgnueabi
> --with-mpc-include=/home/tomato/tomatoware/mmc/include
> --with-mpc-lib=/home/tomato/tomatoware/mmc/lib
> --with-mpfr-include=/home/tomato/tomatoware/mmc/include
> --with-mpfr-lib=/home/tomato/tomatoware/mmc/lib
> --with-gmp-include=/home/tomato/tomatoware/mmc/include
> --with-gmp-lib=/home/tomato/tomatoware/mmc/lib --enable-languages=c,c++
> --enable-shared --enable-static --enable-threads=posix --enable-tls
> --enable-version-specific-runtime-libs --with-float=soft --with-gnu-as
> --with-gnu-ld --disable-__cxa_atexit --disable-decimal-float
> --disable-libgomp --disable-libmudflap --disable-libsanitizer
> --disable-libssp --disable-libstdcxx-pch --disable-multilib --disable-nls
> --disable-werror --without-cloog --without-isl --with-abi=aapcs-linux
> --with-cpu=cortex-a9 --with-mode=arm
> Thread model: posix
> gcc version 6.1.0 (GCC)
> 
> arm, soft-float, no fpu
> 
> Here's a link to download a sample binary
> https://files.lancethepants.com/files/tincd

Thanks for the bug report I can fully reproduce problems with static
binaries and looking into this now.

best regards
 Waldemar
_______________________________________________
devel mailing list
[email protected]
http://mailman.uclibc-ng.org/cgi-bin/mailman/listinfo/devel

Reply via email to