2013-12-27

Slitaz -- core64 / uclibc

uclibc-cross-compiler-x86_64

Toolchain for uclibc/x86_64.

/usr/share/uclibc-cross-compiler-x86_64/bin/../cc/lib/libgcc.a: could not read symbols: Archive has no index; run ranlib to add one

1.
http://cook.slitaz.org/cooker.cgi?receipt=linux

    # Build bzImage64 with modules
    cp -f $stuff/$PACKAGE-slitaz.config64 .config
    #make ARCH=x86_64 oldconfig
    make -j 4 ARCH=x86_64 CROSS_COMPILE=uclibc-x86_64- bzImage &&
    make -j 4 ARCH=x86_64 CROSS_COMPILE=uclibc-x86_64- modules &&

2.
tux@slitaz:~$ echo 'int main() { return 0; }' > test.c

tux@slitaz:~$ ARCH=x86_64 uclibc-x86_64-gcc -v -Wall -o test.o test.c
Invoked as uclibc-x86_64-gcc
Reference path: /usr/share/uclibc-cross-compiler-x86_64/bin/..
arg[ 0] = rawcc
arg[ 1] = -nostdlib
arg[ 2] = -Wl,--dynamic-linker,/lib/ld-uClibc.so.0
arg[ 3] = -Wl,-rpath-link,/usr/share/uclibc-cross-compiler-x86_64/bin/../lib
arg[ 4] = -L/usr/share/uclibc-cross-compiler-x86_64/bin/../lib
arg[ 5] = -L/usr/share/uclibc-cross-compiler-x86_64/bin/../cc/lib
arg[ 6] = -nostdinc
arg[ 7] = -isystem
arg[ 8] = /usr/share/uclibc-cross-compiler-x86_64/bin/../include
arg[ 9] = -isystem
arg[10] = /usr/share/uclibc-cross-compiler-x86_64/bin/../cc/include
arg[11] = -U__nptl__
arg[12] = /usr/share/uclibc-cross-compiler-x86_64/bin/../lib/crti.o
arg[13] = /usr/share/uclibc-cross-compiler-x86_64/bin/../cc/lib/crtbegin.o
arg[14] = /usr/share/uclibc-cross-compiler-x86_64/bin/../lib/crt1.o
arg[15] = -v
arg[16] = -Wall
arg[17] = -o
arg[18] = test.o
arg[19] = test.c
arg[20] = -Wl,--start-group,--as-needed
arg[21] = -lgcc
arg[22] = -lgcc_s
arg[23] = -lc
arg[24] = -Wl,--no-as-needed,--end-group
arg[25] = /usr/share/uclibc-cross-compiler-x86_64/bin/../cc/lib/crtend.o
arg[26] = /usr/share/uclibc-cross-compiler-x86_64/bin/../lib/crtn.o
Using built-in specs.
Target: x86_64-unknown-linux
Configured with: /home/landley/work/ab7/build/temp-x86_64/gcc-core/configure --target=x86_64-unknown-linux --prefix=/home/landley/work/ab7/build/cross-compiler-x86_64 --disable-multilib --disable-nls --enable-c99 --enable-long-long --enable-__cxa_atexit --enable-languages=c,c++ --disable-libstdcxx-pch --program-prefix=x86_64- --enable-threads=posix --enable-shared --build=x86_64-walrus-linux --host=x86_64-unknown-linux
Thread model: posix
gcc version 4.2.1
 cc1 -quiet -nostdinc -v -iprefix /usr/share/uclibc-cross-compiler-x86_64/x86_64-unknown-linux/bin/../lib/gcc/x86_64-unknown-linux/4.2.1/ -U__nptl__ -isystem /usr/share/uclibc-cross-compiler-x86_64/bin/../include -isystem /usr/share/uclibc-cross-compiler-x86_64/bin/../cc/include test.c -quiet -dumpbase test.c -mtune=generic -auxbase test -Wall -version -o /tmp/cc4IJKwh.s
#include "..." search starts here:
#include <...> search starts here:
 /usr/share/uclibc-cross-compiler-x86_64/bin/../include
 /usr/share/uclibc-cross-compiler-x86_64/bin/../cc/include
End of search list.
GNU C version 4.2.1 (x86_64-unknown-linux)
    compiled by GNU C version 4.2.1.
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
Compiler executable checksum: be2919982cb57ffe1dc597edcbdc600c
 as --traditional-format -V -Qy -o /tmp/cc84z8vp.o /tmp/cc4IJKwh.s
GNU assembler version 2.17 (x86_64-unknown-linux) using BFD version 2.17
 ld --eh-frame-hdr -m elf_x86_64 -dynamic-linker /lib64/ld-linux-x86-64.so.2 -o test.o -L/usr/share/uclibc-cross-compiler-x86_64/bin/../lib -L/usr/share/uclibc-cross-compiler-x86_64/bin/../cc/lib --dynamic-linker /lib/ld-uClibc.so.0 -rpath-link /usr/share/uclibc-cross-compiler-x86_64/bin/../lib /usr/share/uclibc-cross-compiler-x86_64/bin/../lib/crti.o /usr/share/uclibc-cross-compiler-x86_64/bin/../cc/lib/crtbegin.o /usr/share/uclibc-cross-compiler-x86_64/bin/../lib/crt1.o /tmp/cc84z8vp.o --start-group --as-needed -lgcc -lgcc_s -lc --no-as-needed --end-group /usr/share/uclibc-cross-compiler-x86_64/bin/../cc/lib/crtend.o /usr/share/uclibc-cross-compiler-x86_64/bin/../lib/crtn.o
/usr/share/uclibc-cross-compiler-x86_64/bin/../cc/lib/libgcc.a: could not read symbols: Archive has no index; run ranlib to add one
tux@slitaz:~$



3.
root@slitaz:/usr/src/qtfm-5.5# ARCH=x86_64 CROSS_COMPILE=uclibc-x86_64- make
uclibc-x86_64-g++ -c -pipe -O2 -D_REENTRANT -w -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I../../share/qt/mkspecs/linux-g++ -I. -I../../include/QtCore -I../../include/QtNetwork -I../../include/QtGui -I../../include -I. -Isrc -Ibuild -o build/main.o src/main.cpp
In file included from ../../include/QtCore/qobject.h:48,
                 from ../../include/QtCore/qcoreapplication.h:45,
                 from ../../include/QtGui/qapplication.h:45,
                 from ../../include/QtGui/QApplication:1,
                 from src/main.cpp:23:
/usr/share/uclibc-cross-compiler-x86_64/bin/../c++/include/string: In instantiation of 'std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >':
../../include/QtCore/qstring.h:1051:   instantiated from here
/usr/share/uclibc-cross-compiler-x86_64/bin/../c++/include/string:57: error: no type named 'char_type' in 'struct std::char_traits<wchar_t>'
/usr/share/uclibc-cross-compiler-x86_64/bin/../c++/include/string: In copy constructor 'std::basic_string<Ch, Tr, A>::basic_string(const std::basic_string<Ch, Tr, A>&, typename A::size_type, typename A::size_type, const A&) [with Ch = wchar_t, Tr = std::char_traits<wchar_t>, A = std::allocator<wchar_t>]':
../../include/QtCore/qstring.h:1063:   instantiated from here
/usr/share/uclibc-cross-compiler-x86_64/bin/../c++/include/string:689: error: 'copy' is not a member of 'std::char_traits<wchar_t>'
make: *** [build/main.o] Error 1
root@slitaz:/usr/src/qtfm-5.5#


4.
root@slitaz:/usr/src/zlib-1.2.6# ARCH=x86_64 CROSS_COMPILE=uclibc-x86_64- make
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1 -I. -c -o example.o test/example.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o adler32.o adler32.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o crc32.o crc32.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o deflate.o deflate.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o infback.o infback.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o inffast.o inffast.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o inflate.o inflate.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o inftrees.o inftrees.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o trees.o trees.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o zutil.o zutil.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o compress.o compress.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o uncompr.o uncompr.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o gzclose.o gzclose.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o gzlib.o gzlib.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o gzread.o gzread.c
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1   -c -o gzwrite.o gzwrite.c
uclibc-x86_64-ar rc libz.a adler32.o crc32.o deflate.o infback.o inffast.o inflate.o inftrees.o trees.o zutil.o compress.o uncompr.o gzclose.o gzlib.o gzread.o gzwrite.o
uclibc-x86_64-gcc -O3  -D_LARGEFILE64_SOURCE=1 -o example example.o -L. libz.a
/usr/share/uclibc-cross-compiler-x86_64/bin/../cc/lib/libgcc.a: could not read symbols: Archive has no index; run ranlib to add one
make: *** [example] Error 1
root@slitaz:/usr/src/zlib-1.2.6#