summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel McGregor <daniel.mcgregor@vecima.com>2021-01-06 16:03:19 -0600
committerDaniel McGregor <daniel.mcgregor@vecima.com>2021-05-17 09:44:48 -0600
commit29ffd277addd24309dbaf09728dd83ce596657c3 (patch)
treeb918b2bf111d59517a80236b295947df483bb6e5
parent87f0b45a307bb47df5a68d6649fe5625f2dd0775 (diff)
downloadopenembedded-core-contrib-29ffd277addd24309dbaf09728dd83ce596657c3.tar.gz
bison-native: disable libtextstyle
Bison opportunistically enables libtextstyle support if it's installed on the build host. Since libtextstyle isn't in oe-core, avoid host contamination by unconditionally disabling support for libtextstyle. Signed-off-by: Daniel McGregor <daniel.mcgregor@vecima.com>
-rw-r--r--meta/recipes-devtools/bison/bison_3.7.6.bb20
1 files changed, 19 insertions, 1 deletions
diff --git a/meta/recipes-devtools/bison/bison_3.7.6.bb b/meta/recipes-devtools/bison/bison_3.7.6.bb
index a7f01c3299..8a0f7755df 100644
--- a/meta/recipes-devtools/bison/bison_3.7.6.bb
+++ b/meta/recipes-devtools/bison/bison_3.7.6.bb
@@ -16,7 +16,25 @@ SRC_URI = "${GNU_MIRROR}/bison/bison-${PV}.tar.xz \
SRC_URI[sha256sum] = "67d68ce1e22192050525643fc0a7a22297576682bef6a5c51446903f5aeef3cf"
# No point in hardcoding path to m4, just use PATH
-EXTRA_OECONF += "M4=m4"
+CACHED_CONFIGUREVARS = "ac_cv_path_M4=m4"
+
+PACKAGECONFIG ??= "readline"
+PACKAGECONFIG_class-native ??= ""
+
+# Make readline optional. There is a recipe for this, but leave it disabled
+# for the native recipe. This prevents host contamination of the native tool.
+PACKAGECONFIG[readline] = "--with-libreadline-prefix,--without-libreadline-prefix,readline"
+
+# Also make libtextstyle optional. This is provided by gettext, but leave it disabled
+# to avoid host contamination.
+PACKAGECONFIG[textstyle] = "--with-libtextstyle-prefix,--without-libtextstyle-prefix,gettext"
+
+# Include the cached configure variables, configure is really good at finding
+# libreadline, even if we don't want it.
+CACHED_CONFIGUREVARS += "${@bb.utils.contains('PACKAGECONFIG', 'readline', '', ' \
+ ac_cv_header_readline_history_h=no \
+ ac_cv_header_readline_readline_h=no \
+ gl_cv_lib_readline=no', d)}"
inherit autotools gettext texinfo