Nao:      «Cross GCC for OS X»


Compiling gcc on OS X for Geode

This is only required if you feel like compiling native local programs and libraries for Nao on OS X. The Linux binaries are available at Aldebaran. If you work on MS Windows, I can't help you.

You must have Xcode installed

500 export CC=/usr/bin/gcc-4.2 501 export CXX=/usr/bin/g++-4.2 502 export CPP=/usr/bin/cpp-4.2 503 export LD=/usr/bin/ld 504 export PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/texbin:/usr/X11/bin 505 cd 506 mkdir mygcc 507 cd mygcc 508 wget ftp://ftp.gnu.org/gnu/gmp/gmp-5.0.2.tar.gz 509 /sw/bin/wget ftp://ftp.gnu.org/gnu/gmp/gmp-5.0.2.tar.gz 510 /sw/bin/wget http://www.mpfr.org/mpfr-current/mpfr-3.0.1.tar.gz 511 /sw/bin/wget http://www.mpfr.org/mpfr-3.0.1/mpfr-3.0.1.tar.gz 512 /sw/bin/wget http://www.multiprecission.org/mpc/download/mpc-0.9.tar.gz 513 /sw/bin/wget http://www.multiprecision.org/mpc/download/mpc-0.9.tar.gz 514 wget ftp://ftp.fu-berlin.de/unix/languages/gcc/releases/gcc-4.6.1/gcc-4.6.1.tar.gz 515 /sw/bin/wget ftp://ftp.fu-berlin.de/unix/languages/gcc/releases/gcc-4.6.1/gcc-4.6.1.tar.gz 516 ls 517 tar xfz gcc-4.6.1.tar.gz 518 tar xfz gmp-5.0.2.tar.gz 519 tar xfz mpc-0.9.tar.gz 520 tar xfz mpfr-3.0.1.tar.gz 521 ls 522 cd gcc-4.6.1 523 ln -s ../gmp-5.0.2 gmp 524 ln -s ../mpc-0.9 mpc 525 ln -s ../mpfr-3.0.1 mpfr 526 cd .. 527 mkdir build 528 cd build 529 ../gcc-4.6.1/configure 530 make 531 ls 532 pwd 533 ls 534 gcc/cpp 535 gcc/g++ 536 gcc/g++ -v 537 gcc/as 538 gcc/as -v 539 make distclean 540 ../gcc-4.6.1/configure --target=i686-linux-elf 541 ../gcc-4.6.1/configure --help 542 make distclean 543 ../gcc-4.6.1/configure --bindir=/usr/i386-apple-darwin/i686-pc-linux-gnu/gcc-bin/4.4.3 --includedir=/usr/lib/gcc/i686-pc-linux-gnu/4.4.3/include --datadir=/usr/share/gcc-data/i686-pc-linux-gnu/4.4.3 --mandir=/usr/share/gcc-data/i686-pc-linux-gnu/4.4.3/man --infodir=/usr/share/gcc-data/i686-pc-linux-gnu/4.4.3/info --with-gxx-include-dir=/usr/lib/gcc/i686-pc-linux-gnu/4.4.3/include/g++-v4 --host=i386-apple-darwin --target=i686-pc-linux-gnu --build=i386-apple-darwin --disable-altivec --disable-fixed-point --without-ppl --without-cloog --enable-nls --without-included-gettext --with-system-zlib --disable-werror --enable-secureplt --disable-multilib --disable-libmudflap --disable-libssp --enable-libgomp --enable-cld --with-python-dir=/share/gcc-data/i686-pc-linux-gnu/4.4.3/python --enable-checking=release --disable-libgcj --with-arch=i686 --enable-languages=c,c++,fortran --with-sysroot=/usr/i686-pc-linux-gnu --disable-bootstrap --enable-__cxa_atexit 544 history

../gcc-4.6.1/configure --target=i686-pc-linux-gnu --disable-altivec --disable-fixed-point --without-ppl --without-cloog --enable-nls --without-included-gettext --with-system-zlib --disable-werror --enable-secureplt --disable-multilib --disable-libmudflap --disable-libssp --enable-libgomp --enable-cld --enable-checking=release --disable-libgcj --with-arch=i686 --enable-languages=c,c++,fortran --disable-bootstrap --enable-__cxa_atexit

make CFLAGS="-Os -w"

cd mkdir crossgcc-4.4.3-i686-elf cd crossgcc-4.4.3-i686-elf wget ftp://ftp.gnu.org/gnu/gmp/gmp-5.0.2.tar.gz tar xfz gmp-5.0.2.tar.gz cd gmp-5.0.2 mkdir build cd build ../configure --prefix=$HOME/crossgcc-4.4.3-i686-elf/gcc-4.6.2 make make install

# make your directories as needed cd dev mkdir crossgcc-4.4.3 cd crossgcc-4.4.3

# get, unpack, build, and install binutils wget ftp://ftp.gnu.org/gnu/binutils/binutils-2.19.1.tar.bz2 tar xvfz binutils-2.19.1.tar.bz2 mkdir binutils-obj cd binutils-obj ../binutils-2.19.1/configure --target=i686-pc-linux-gnu --prefix=/usr make CFLAGS="-Os -w" cd ..

# build gmp 116 21:19 wget ftp://ftp.gnu.org/gnu/gmp/gmp-4.3.2.tar.gz 117 21:19 rm gmp-4.1 118 21:19 rm gmp-4.1.tar.gz 119 21:19 rm -r gmp-4.1/ 120 21:19 tar xvfz gmp-4.3.2.tar.gz 121 21:19 cd gmp-4.3.2 122 21:20 mkdir build 123 21:20 cd build 124 21:20 ../configure --prefix=$HOME/crossgcc-4.4.3/gcc-4.4. 125 21:20 ../configure --prefix=$HOME/crossgcc-4.4.3/gcc-4.4.3 126 21:21 make 127 21:23 cd ../..

# get, unpack, build, and install gcc wget ftp://ftp.fu-berlin.de/unix/languages/gcc/releases/gcc-4.4.3/gcc-4.4.3.tar.gz tar xvfz gcc-4.4.3.tar.gz --target=i686-pc-linux-gnu mkdir gcc-obj cd gcc-obj