Le jeudi 9 janvier 2014, 14:14:52 Michael Matz a écrit : > Hi, > > On Thu, 9 Jan 2014, Thomas Preud'homme wrote: > > That's because GCC doesn't have any problem. The problem is in TinyCC. I > > was compiling mksh with TinyCC (I called it tcc in my initial mail) and > > it gave me linker error about undefined __va_arg if I remember > > correctly. > > Are you sure it's not a bug in mksh, and in which version anyway? The > stdarg testcases from the testsuite all work just fine. > > I can also build mksh-R48b with tcc just fine: > > % uname -a > % cd /matz/git/tinycc; git log --online HEAD^.. > 767410b Various Makefile fixes for cross-compilation > % ./configure; make; make test > ... all works ... > % cd /tmp/ > % tar xvf mksh-R48b.tgz > % mkdir mksh/build; cd mksh/build > % CC="/matz/git/tinycc/tcc -B/matz/git/tinycc/" /bin/sh ../Build.sh > ...
Oh I see. I compiled with --with-libgcc and gcc doesn't provide __va_* like libtcc1 does. So I guess either libgcc should not be proposed for x86-64 systems or libtcc1 should always be linked in as well as to fill in the blank. Or maybe now that arm can uses libtcc1 this option could be just removed. If there is some value in keeping it, it could also be nice that tcc can work directly with libgcc (and thus have va_* macros builtin, see stdarg.h from gcc and gcc's source code). Dear users, does any of you see value in the --with-libgcc switch of configure? Best regards, Thomas _______________________________________________ Tinycc-devel mailing list [email protected] https://lists.nongnu.org/mailman/listinfo/tinycc-devel
