diff mbox series

[03/17] swig: update 4.0.2 -> 4.1.0

Message ID 20221120133122.2464634-3-alex@linutronix.de
State New
Headers show
Series [01/17] elfutils: update 0.187 -> 0.188 | expand

Commit Message

Alexander Kanavin Nov. 20, 2022, 1:31 p.m. UTC
swig has transitioned pcre -> pcre2
Update 0001-configure-use-pkg-config-for-pcre-detection.patch
accordingly.

Signed-off-by: Alexander Kanavin <alex@linutronix.de>
---
 meta/recipes-devtools/swig/swig.inc           |  2 +-
 ...re-use-pkg-config-for-pcre-detection.patch | 44 ++++++++++---------
 .../swig/{swig_4.0.2.bb => swig_4.1.0.bb}     |  2 +-
 3 files changed, 26 insertions(+), 22 deletions(-)
 rename meta/recipes-devtools/swig/{swig_4.0.2.bb => swig_4.1.0.bb} (72%)
diff mbox series

Patch

diff --git a/meta/recipes-devtools/swig/swig.inc b/meta/recipes-devtools/swig/swig.inc
index 13470c1094..7a6c4d7359 100644
--- a/meta/recipes-devtools/swig/swig.inc
+++ b/meta/recipes-devtools/swig/swig.inc
@@ -10,7 +10,7 @@  LIC_FILES_CHKSUM = "file://LICENSE;md5=e7807a6282784a7dde4c846626b08fc6 \
 
 SECTION = "devel"
 
-DEPENDS = "libpcre bison-native"
+DEPENDS = "libpcre2 bison-native"
 
 SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.gz"
 UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/swig/files/swig/"
diff --git a/meta/recipes-devtools/swig/swig/0001-configure-use-pkg-config-for-pcre-detection.patch b/meta/recipes-devtools/swig/swig/0001-configure-use-pkg-config-for-pcre-detection.patch
index fdb9760e89..cfcbd8c73a 100644
--- a/meta/recipes-devtools/swig/swig/0001-configure-use-pkg-config-for-pcre-detection.patch
+++ b/meta/recipes-devtools/swig/swig/0001-configure-use-pkg-config-for-pcre-detection.patch
@@ -1,52 +1,56 @@ 
-From 5c4d6d8538994d5fe9b3b46bfafaf0a605e3bda6 Mon Sep 17 00:00:00 2001
+From ffb785ed8d3cac3c28e014b1238d93e2bc1f0c01 Mon Sep 17 00:00:00 2001
 From: Koen Kooi <koen.kooi@linaro.org>
 Date: Tue, 17 Jun 2014 08:18:17 +0200
 Subject: [PATCH] configure: use pkg-config for pcre detection
 
 Signed-off-by: Koen Kooi <koen.kooi@linaro.org>
 Upstream-Status: Pending
+
 ---
- configure.ac | 38 +++++++-------------------------------
- 1 file changed, 7 insertions(+), 31 deletions(-)
+ configure.ac | 39 +++++++--------------------------------
+ 1 file changed, 7 insertions(+), 32 deletions(-)
 
+diff --git a/configure.ac b/configure.ac
+index f88004a..3a2b47c 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -52,38 +52,14 @@ AC_MSG_RESULT([$with_pcre])
+@@ -57,39 +57,14 @@ AC_MSG_RESULT([$with_pcre])
  
  dnl To make configuring easier, check for a locally built PCRE using the Tools/pcre-build.sh script
  if test x"${with_pcre}" = xyes ; then
--  AC_MSG_CHECKING([whether to use local PCRE])
+-  AC_MSG_CHECKING([whether to use local PCRE2])
 -  local_pcre_config=no
--  if test -z $PCRE_CONFIG; then
--    if test -f `pwd`/pcre/pcre-swig-install/bin/pcre-config; then
--      PCRE_CONFIG=`pwd`/pcre/pcre-swig-install/bin/pcre-config
--      local_pcre_config=$PCRE_CONFIG
+-  if test -z "$PCRE2_CONFIG"; then
+-    if test -f `pwd`/pcre/pcre-swig-install/bin/pcre2-config; then
+-      PCRE2_CONFIG=`pwd`/pcre/pcre-swig-install/bin/pcre2-config
+-      local_pcre_config=$PCRE2_CONFIG
 -    fi
 -  fi
 -  AC_MSG_RESULT([$local_pcre_config])
 -fi
 -AS_IF([test "x$with_pcre" != xno],
--  [AX_PATH_GENERIC([pcre],
+-  [AX_PATH_GENERIC([pcre2],
 -    [], dnl Minimal version of PCRE we need -- accept any
 -    [], dnl custom sed script for version parsing is not needed
--    [AC_DEFINE([HAVE_PCRE], [1], [Define if you have PCRE library])
--     LIBS="$LIBS $PCRE_LIBS"
--     CPPFLAGS="$CPPFLAGS $PCRE_CFLAGS"
+-    [AC_DEFINE([HAVE_PCRE], [1], [Define if you have PCRE2 library])
+-     LIBS="$LIBS $PCRE2_LIBS"
+-     CPPFLAGS="$CPPFLAGS $PCRE2_CFLAGS"
 -    ],
 -    [AC_MSG_FAILURE([
--        Cannot find pcre-config script from PCRE (Perl Compatible Regular Expressions)
+-        Cannot find pcre2-config script from PCRE2 (Perl Compatible Regular Expressions)
 -        library package. This dependency is needed for configure to complete,
 -        Either:
--        - Install the PCRE developer package on your system (preferred approach).
--        - Download the PCRE source tarball, build and install on your system
+-        - Install the PCRE2 developer package on your system (preferred approach).
+-        - Download the PCRE2 source tarball, build and install on your system
 -          as you would for any package built from source distribution.
--        - Use the Tools/pcre-build.sh script to build PCRE just for SWIG to statically
+-        - Use the Tools/pcre-build.sh script to build PCRE2 just for SWIG to statically
 -          link against. Run 'Tools/pcre-build.sh --help' for instructions.
--          (quite easy and does not require privileges to install PCRE on your system)
+-          (quite easy and does not require privileges to install PCRE2 on your system)
 -        - Use configure --without-pcre to disable regular expressions support in SWIG
 -          (not recommended).])
--    ])
-+  PKG_CHECK_MODULES([PCRE], [libpcre], [
+-    ],
+-    [],[],[--libs8])
++  PKG_CHECK_MODULES([PCRE], [libpcre2], [
 +    AC_DEFINE([HAVE_PCRE], [1], [Define if you have PCRE library])
 +    LIBS="$LIBS $PCRE_LIBS"
 +    CPPFLAGS="$CPPFLAGS $PCRE_CFLAGS"
diff --git a/meta/recipes-devtools/swig/swig_4.0.2.bb b/meta/recipes-devtools/swig/swig_4.1.0.bb
similarity index 72%
rename from meta/recipes-devtools/swig/swig_4.0.2.bb
rename to meta/recipes-devtools/swig/swig_4.1.0.bb
index 718ad89a5d..0eabd8ed60 100644
--- a/meta/recipes-devtools/swig/swig_4.0.2.bb
+++ b/meta/recipes-devtools/swig/swig_4.1.0.bb
@@ -4,4 +4,4 @@  SRC_URI += "file://0001-Use-proc-self-exe-for-swig-swiglib-on-non-Win32-plat.pat
             file://0001-configure-use-pkg-config-for-pcre-detection.patch \
             file://determinism.patch \
            "
-SRC_URI[sha256sum] = "d53be9730d8d58a16bf0cbd1f8ac0c0c3e1090573168bfa151b01eb47fa906fc"
+SRC_URI[sha256sum] = "d6a9a8094e78f7cfb6f80a73cc271e1fe388c8638ed22668622c2c646df5bb3d"