aboutsummaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-extended/zsh/files/pcre-pkgconfig.patch
diff options
context:
space:
mode:
authorDan McGregor <dan.mcgregor@usask.ca>2017-08-10 14:15:11 -0600
committerDan McGregor <dan.mcgregor@usask.ca>2017-08-22 09:14:19 -0600
commit681d12f8bf04a403d6e692cbe0ceebad932b0731 (patch)
treee90e95df7820892273c68f446e4460cd8a9e5269 /meta-oe/recipes-extended/zsh/files/pcre-pkgconfig.patch
parent1ce7c78756539126eb7a9037ac257b91c07312a5 (diff)
downloadmeta-openembedded-contrib-681d12f8bf04a403d6e692cbe0ceebad932b0731.tar.gz
zsh: update to 5.4.1dankm/zsh
Also fix up autoconf to use pkg-config, and properly detect pcre. Signed-off-by: Dan McGregor <dan.mcgregor@usask.ca>
Diffstat (limited to 'meta-oe/recipes-extended/zsh/files/pcre-pkgconfig.patch')
-rw-r--r--meta-oe/recipes-extended/zsh/files/pcre-pkgconfig.patch49
1 files changed, 49 insertions, 0 deletions
diff --git a/meta-oe/recipes-extended/zsh/files/pcre-pkgconfig.patch b/meta-oe/recipes-extended/zsh/files/pcre-pkgconfig.patch
new file mode 100644
index 0000000000..ebbd03f071
--- /dev/null
+++ b/meta-oe/recipes-extended/zsh/files/pcre-pkgconfig.patch
@@ -0,0 +1,49 @@
+diff --git a/Src/Modules/pcre.mdd b/Src/Modules/pcre.mdd
+index 6eb3c691b..12c10704e 100644
+--- a/Src/Modules/pcre.mdd
++++ b/Src/Modules/pcre.mdd
+@@ -1,5 +1,5 @@
+ name=zsh/pcre
+-link=`if test x$enable_pcre = xyes && (pcre-config --version >/dev/null 2>/dev/null); then echo dynamic; else echo no; fi`
++link=`if test x$enable_pcre = xyes ; then echo dynamic; else echo no; fi`
+ load=no
+
+ autofeatures="b:pcre_compile b:pcre_study b:pcre_match"
+diff --git a/configure.ac b/configure.ac
+index 920c2fc17..d1512291c 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -671,17 +671,15 @@ AC_HEADER_TIME
+ AC_HEADER_STAT
+ AC_HEADER_SYS_WAIT
+
+-oldcflags="$CFLAGS"
+ if test x$enable_pcre = xyes; then
+-AC_CHECK_PROG([PCRECONF], pcre-config, pcre-config)
+-dnl Typically (meaning on this single RedHat 9 box in front of me)
+-dnl pcre-config --cflags produces a -I output which needs to go into
+-dnl CPPFLAGS else configure's preprocessor tests don't pick it up,
+-dnl producing a warning.
+-if test "x$ac_cv_prog_PCRECONF" = xpcre-config; then
+- CPPFLAGS="$CPPFLAGS `pcre-config --cflags`"
+-fi
++PKG_CHECK_MODULES(PCREPKG, [libpcre], [
++ PCRE_LIB="${PCREPKG_LIBS}"
++ CPPFLAGS="$CPPFLAGS ${PCREPKG_CFLAGS}"
++ ], [
++ AC_MSG_ERROR([pcre not found, install the pcre-devel package or build with --disable-pcre])
++ ])
+ fi
++oldcflags="$CFLAGS"
+
+ AC_CHECK_HEADERS(sys/time.h sys/times.h sys/select.h termcap.h termio.h \
+ termios.h sys/param.h sys/filio.h string.h memory.h \
+@@ -935,7 +933,7 @@ fi
+ if test x$enable_pcre = xyes; then
+ dnl pcre-config should probably be employed here
+ dnl AC_SEARCH_LIBS(pcre_compile, pcre)
+- LIBS="`$ac_cv_prog_PCRECONF --libs` $LIBS"
++ LIBS="$PCRE_LIB $LIBS"
+ fi
+
+ dnl ---------------------