This is the mail archive of the
automake@gnu.org
mailing list for the automake project.
crosscompile, libtools aund buildtools
- From: Benedikt Spranger <b dot spranger at pengutronix dot de>
- To: automake <automake at gnu dot org>
- Date: Wed, 23 Jun 2004 00:55:36 +0200
- Subject: crosscompile, libtools aund buildtools
Hi,
During crosscompile I often have a problem: I need some to build
build-tools like rpcgen. How can I do it the right way?
Until now I use the following code:
configure.in:
----8<----
if test -z "$CC_FOR_BUILD"; then
# to avoid recursive substitution
# if test "x$cross_compiling" = "xno"; then
# CC_FOR_BUILD='$(CC)'
# else
CC_FOR_BUILD=gcc
# fi
fi
----8<----
Makefile.am:
----8<----
CC=$(CC_FOR_BUILD)
CFLAGS=$(CFLAGS_FOR_BUILD)
LDFLAGS=$(LDFLAGS_FOR_BUILD)
LIBTOOL = @LIBTOOL@ --tag=CC
----8<----
Is there a better way to do it?
Benedikt Spranger
--
Benedikt Spranger| http://www.pengutronix.de
Pengutronix - Linux Solutions for Science and Industry
Handelsregister: Amtsgericht Hildesheim, HRA 2686
Hornemannstraße 12, 31137 Hildesheim, Germany
Phone: +49-5121-28619-0 | Fax: +49-5121-28619-4