autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Making configure.in so the good compiler is choose


From: David Burg
Subject: Making configure.in so the good compiler is choose
Date: Wed, 30 May 2001 17:29:11 +0200

Hello,

I hope outlook will let this real plain text ! ;-) Well, I'm trying to make
a configure.in file that support Canadian Cross compiling with the help of
the autobook 1.3.

First, I just would like to signal I was a bit surprised by this
AC_CANONICAL_SYSTEM macro that does crash when you provide a cross-compiler
as CC. Isn't possible to make it run better ? Or did I something wrong ?

bash-2.04# rm config.cache

bash-2.04# autoconf

bash-2.04# CC=arm-linux-gcc ./configure --target=arm-linux

creating cache ./config.cache

checking host system type... ./config.guess: ./dummy: cannot execute binary
file

./config.guess: ./dummy: cannot execute binary file

configure: error: can not guess host type; you must specify one



Ok, ok, then I try :

bash-2.04# rm config.cache

bash-2.04# autoconf

bash-2.04# CC=arm-linux-gcc
./configure --target=arm-linux --host=i686-pc-linux-gnu

creating cache ./config.cache

checking host system type... i686-pc-linux-gnu

checking target system type... arm-unknown-linux-gnu

checking build system type... i686-pc-linux-gnu

checking how to run the C preprocessor... arm-linux-gcc -E

checking for c++... c++

(No, no, no I don't want to test c++, I want to test arm-linux-gcc ! )

checking whether the C++ compiler (c++ ) works... yes

checking whether the C++ compiler (c++ ) is a cross-compiler... no

checking whether we are using GNU C++... yes

checking whether c++ accepts -g... yes

checking for a BSD compatible install... /usr/bin/install -c

checking whether byte ordering is bigendian... no

checking Adding -DBIGENDIAN to PORTABILITYFLAGS... no

checking Target Operating-System... linux

This is the result will a configure.in file with :

dnl file generated by autoscan, then modifiy and merged

dnl with previous tests ...

dnl Process this file with autoconf to produce a configure script.

AC_INIT(confdefs.h)

dnl determine the target system

AC_CANONICAL_SYSTEM

dnl Checks for programs.

AC_PROG_CPP

AC_PROG_CXX

AC_PROG_INSTALL

etc...

How to make it test the cross-compiler we provide and not erase $CC by "c++"
??

Best regards,

David Burg.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]