summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYi Zhao <yi.zhao@windriver.com>2019-06-18 08:26:19 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2019-06-18 11:34:24 +0100
commita86da25d620aa9a2fd832ffe12816e7670b43633 (patch)
tree84e12129c2c8fc33c68bee53b21041abb8b21112
parentc8900a7e79976b044791a2d58d5e24f05b1690d5 (diff)
downloadopenembedded-core-contrib-a86da25d620aa9a2fd832ffe12816e7670b43633.tar.gz
shadow: fix configure error with dash
A configure error occurs when /bin/sh -> dash: checking for is_selinux_enabled in -lselinux... yes checking for semanage_connect in -lsemanage... yes configure: 16322: test: yesyes: unexpected operator Use "=" instead of "==" since dash doesn't support the latter. Signed-off-by: Yi Zhao <yi.zhao@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-extended/shadow/files/0001-configure.ac-fix-configure-error-with-dash.patch36
-rw-r--r--meta/recipes-extended/shadow/shadow.inc1
2 files changed, 37 insertions, 0 deletions
diff --git a/meta/recipes-extended/shadow/files/0001-configure.ac-fix-configure-error-with-dash.patch b/meta/recipes-extended/shadow/files/0001-configure.ac-fix-configure-error-with-dash.patch
new file mode 100644
index 0000000000..a74cbb0c0e
--- /dev/null
+++ b/meta/recipes-extended/shadow/files/0001-configure.ac-fix-configure-error-with-dash.patch
@@ -0,0 +1,36 @@
+From 3c52a84ff8775590e7e9da9c0d4408c23494305e Mon Sep 17 00:00:00 2001
+From: Yi Zhao <yi.zhao@windriver.com>
+Date: Mon, 17 Jun 2019 15:36:34 +0800
+Subject: [PATCH] configure.ac: fix configure error with dash
+
+A configure error occurs when /bin/sh -> dash:
+ checking for is_selinux_enabled in -lselinux... yes
+ checking for semanage_connect in -lsemanage... yes
+ configure: 16322: test: yesyes: unexpected operator
+
+Use "=" instead of "==" since dash doesn't support this operator.
+
+Upstream-Status: Backport
+[https://github.com/shadow-maint/shadow/commit/3c52a84ff8775590e7e9da9c0d4408c23494305e]
+
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index 6762556..1907afb 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -500,7 +500,7 @@ if test "$with_selinux" != "no"; then
+ AC_MSG_ERROR([libsemanage not found])
+ fi
+
+- if test "$selinux_lib$semanage_lib" == "yesyes" ; then
++ if test "$selinux_lib$semanage_lib" = "yesyes" ; then
+ AC_DEFINE(WITH_SELINUX, 1,
+ [Build shadow with SELinux support])
+ LIBSELINUX="-lselinux"
+--
+2.7.4
+
diff --git a/meta/recipes-extended/shadow/shadow.inc b/meta/recipes-extended/shadow/shadow.inc
index 831751d6de..7f82d20826 100644
--- a/meta/recipes-extended/shadow/shadow.inc
+++ b/meta/recipes-extended/shadow/shadow.inc
@@ -13,6 +13,7 @@ SRC_URI = "https://github.com/shadow-maint/shadow/releases/download/${PV}/${BP}.
file://shadow-4.1.3-dots-in-usernames.patch \
file://0001-Make-the-sp_lstchg-shadow-field-reproducible-re.-71.patch \
file://0002-gettime-Use-secure_getenv-over-getenv.patch \
+ file://0001-configure.ac-fix-configure-error-with-dash.patch \
${@bb.utils.contains('PACKAGECONFIG', 'pam', '${PAM_SRC_URI}', '', d)} \
"