|
From: | Dan Kegel |
Subject: | Re: cross-compiling, gcc-3.3, and --with-build-cc |
Date: | Wed, 27 Aug 2003 01:36:38 -0700 |
User-agent: | Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030624 |
Dan Kegel wrote:
ncurses-5.3 seems to be smart about not using strstream, but this fails when you specify a cross-compiler with --build-cc ... I gather the "right" way to configure ncurses is to override CC and HOSTCC on the commandline, and ignore the --with-build-cc option.
I posted too quickly, apologies. The following script seems to successfully configure and cross-compile ncurses-5.3 with my local gcc-3.3.1 crosstoolchain: ------------------ snip ---------------- #!/bin/sh TARGET=powerpc-750-linux-gnu CROSS=/opt/cegl-2.0/${TARGET}/gcc-3.3.1-glibc-2.3.2/bin/${TARGET}- # Fetch ncurses and rollup patch (patch needed to cross-compile!), unpack, patch wget -c ftp://invisible-island.net/ncurses/ncurses-5.3.tar.gz wget -c ftp://invisible-island.net/ncurses/5.3/ncurses-5.3-20030719-patch.sh.bz2 tar -xzvf ncurses-5.3.tar.gz cd ncurses-5.3 bzcat ../ncurses-5.3-20030719-patch.sh.bz2 | patch -p1 cd .. rm -rf ncurses-demo mkdir ncurses-demo cd ncurses-demo # Configure and build # Note: in previous releases, had to specify --target. Now it's --host for some reason. # Note: do not use --with-build-cc, it doesn't interact properly with autoconf ../ncurses-5.3/configure BUILD_CC=gcc CC=${CROSS}gcc CXX=${CROSS}g++ AR=${CROSS}ar LD=${CROSS}ld --host=$TARGET --with-shared make -j2 ------------------ snip ---------------- . - Dan -- Dan Kegel http://www.kegel.com http://counter.li.org/cgi-bin/runscript/display-person.cgi?user=78045
[Prev in Thread] | Current Thread | [Next in Thread] |