All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
To: openembedded-devel@lists.openembedded.org
Subject: [PATCH 1/3] autotools.bbclass: pass distro_imposed_configure_flags
Date: Wed, 12 Jan 2011 21:15:50 +0100	[thread overview]
Message-ID: <1294863352-1486-2-git-send-email-rep.dot.nop@gmail.com> (raw)
In-Reply-To: <1294863352-1486-1-git-send-email-rep.dot.nop@gmail.com>

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
---
 classes/autotools.bbclass |   17 +++++++++++++++++
 1 files changed, 17 insertions(+), 0 deletions(-)

diff --git a/classes/autotools.bbclass b/classes/autotools.bbclass
index 247e21d..77bd37d 100644
--- a/classes/autotools.bbclass
+++ b/classes/autotools.bbclass
@@ -65,6 +65,22 @@ def append_libtool_sysroot(d):
 			return '--with-libtool-sysroot=${STAGING_DIR_HOST}'
 	return ''
 
+def distro_imposed_configure_flags(d):
+	distro_features = bb.data.getVar('DISTRO_FEATURES', d, True) or ""
+	distro_features = distro_features.split()
+	flags = set()
+	features = (('largefile', 'largefile'),
+		('ipv6'     , 'ipv6'),
+		('nls'      , 'nls'))
+
+	for knob, cfgargs in features:
+		if isinstance(cfgargs, basestring):
+			cfgargs = [cfgargs]
+		en_or_dis = knob in distro_features and "enable" or "disable"
+		for flg in cfgargs:
+			flags.add("--%s-%s" % (en_or_dis, flg))
+	return " ".join(flags)
+
 # EXTRA_OECONF_append = "${@autotools_set_crosscompiling(d)}"
 
 CONFIGUREOPTS = " --build=${BUILD_SYS} \
@@ -85,6 +101,7 @@ CONFIGUREOPTS = " --build=${BUILD_SYS} \
 		  --infodir=${infodir} \
 		  --mandir=${mandir} \
 		  ${@append_libtool_sysroot(d)} \
+		  ${@distro_imposed_configure_flags(d)} \
 		"
 
 oe_runconf () {
-- 
1.7.2.3




  reply	other threads:[~2011-01-12 20:16 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-12 20:15 [PATCH 0/3] autotools.bbclass misc trivia Bernhard Reutner-Fischer
2011-01-12 20:15 ` Bernhard Reutner-Fischer [this message]
2011-01-12 20:15 ` [PATCH 2/3] autotools.bblass: mkdir also AC_CONFIG_MACRO_DIR Bernhard Reutner-Fischer
2011-01-12 20:15 ` [PATCH 3/3] autotools.bbclass: use grep -q Bernhard Reutner-Fischer
2011-01-12 20:41 ` [PATCH 0/3] autotools.bbclass misc trivia Khem Raj
2011-01-13  0:29   ` Tom Rini
2013-07-09  8:30     ` [oe] " Bernhard Reutner-Fischer
2013-07-09  8:30       ` Bernhard Reutner-Fischer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1294863352-1486-2-git-send-email-rep.dot.nop@gmail.com \
    --to=rep.dot.nop@gmail.com \
    --cc=openembedded-devel@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.