[oe] [PATCH] [RFC][PATCH] autotools: don't specify --target when configuring gmp
Ben Gardiner
bengardiner at nanometrics.ca
Wed Oct 13 16:42:20 UTC 2010
When trying to build angstrom-2008.1 from
f58a5d59b755bdb725497f574a8059529c134c27 of master or from
b78fc95424b5f0fb28246e8c61bb8b4d6a9d733a of stable/2009 the builds failed on
gmp-native (then later gmp). The error was that "--target is not appropriate
for GMP".
This patch adds an exception to the packages for which --target will be passed
to configure. The do_configure stage of the autotools class is modified to not
pass --target if the package is "gmp" or "gmp-native".
Signed-off-by: Ben Gardiner <bengardiner at nanometrics.ca>
---
A similar change was needed also for the stable/2009 branch -- but this patch
is not applicable to that branch as-is.
Checking the PN for a blacklist of names seems very ugly -- I am open to
suggestions on how this might be better accomplished. Also, I think that the
supressing --target may be applicable to anything that is not a cross-development
tool in general [1]; this is the minimum to get a build without errors so far.
[1] http://sourceware.org/autobook/autobook/autobook_259.html#SEC259
---
classes/autotools.bbclass | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/classes/autotools.bbclass b/classes/autotools.bbclass
index b2de2b1..d9c1d70 100644
--- a/classes/autotools.bbclass
+++ b/classes/autotools.bbclass
@@ -61,7 +61,6 @@ def autotools_set_crosscompiling(d):
CONFIGUREOPTS = " --build=${BUILD_SYS} \
--host=${HOST_SYS} \
- --target=${TARGET_SYS} \
--prefix=${prefix} \
--exec_prefix=${exec_prefix} \
--bindir=${bindir} \
@@ -79,7 +78,11 @@ CONFIGUREOPTS = " --build=${BUILD_SYS} \
oe_runconf () {
if [ -x ${S}/configure ] ; then
- ${S}/configure ${CONFIGUREOPTS} ${EXTRA_OECONF} "$@"
+ if [ "${PN}" != "gmp" ] && [ "${PN}" != "gmp-native" ]; then
+ CONFIGURETARGETOPTS="--target=${TARGET_SYS}"
+ fi
+
+ ${S}/configure ${CONFIGURETARGETOPTS} ${CONFIGUREOPTS} ${EXTRA_OECONF} "$@"
else
oefatal "no configure script found"
fi
--
1.7.0.4
More information about the Openembedded-devel
mailing list