aboutsummaryrefslogtreecommitdiffstats
path: root/package/libs/pcre
diff options
context:
space:
mode:
authorRosen Penev <rosenp@gmail.com>2021-10-20 15:45:50 -0700
committerHauke Mehrtens <hauke@hauke-m.de>2021-11-20 21:08:24 +0100
commita3cd6c0b893473ed5fa62105f81d39e2ff780773 (patch)
tree63a57cfcf8c00063e5fb5a3c9acd9735ab0a3232 /package/libs/pcre
parenta24de8953971124ee752021e49b18bdf2ce5cc9c (diff)
downloadupstream-a3cd6c0b893473ed5fa62105f81d39e2ff780773.tar.gz
upstream-a3cd6c0b893473ed5fa62105f81d39e2ff780773.tar.bz2
upstream-a3cd6c0b893473ed5fa62105f81d39e2ff780773.zip
pcre: bring back C++ bindings
It seems some people use them privately. Reported-by: Jan Kardell <jan.kardell@telliq.com> Signed-off-by: Rosen Penev <rosenp@gmail.com>
Diffstat (limited to 'package/libs/pcre')
-rw-r--r--package/libs/pcre/Makefile17
1 files changed, 15 insertions, 2 deletions
diff --git a/package/libs/pcre/Makefile b/package/libs/pcre/Makefile
index db157ec1b4..42149fc511 100644
--- a/package/libs/pcre/Makefile
+++ b/package/libs/pcre/Makefile
@@ -24,6 +24,7 @@ PKG_INSTALL:=1
PKG_BUILD_PARALLEL:=1
PKG_CONFIG_DEPENDS:=\
+ CONFIG_PACKAGE_libpcrecpp \
CONFIG_PCRE_JIT_ENABLED
include $(INCLUDE_DIR)/package.mk
@@ -54,12 +55,18 @@ define Package/libpcre32
TITLE:=A Perl Compatible Regular Expression library (32bit support)
endef
+define Package/libpcrecpp
+ $(call Package/libpcre/default)
+ TITLE:=C++ wrapper for Perl Compatible Regular Expression library
+ DEPENDS:=+libpcre +libstdcpp
+endef
+
HOST_CONFIGURE_ARGS += \
--enable-utf8 \
--enable-unicode-properties \
--enable-pcre16 \
--with-match-limit-recursion=16000 \
- --disable-cpp
+ --enable-cpp
TARGET_CFLAGS += $(FPIC)
@@ -70,7 +77,7 @@ CONFIGURE_ARGS += \
--enable-pcre32 \
$(if $(CONFIG_PCRE_JIT_ENABLED),--enable-jit,--disable-jit) \
--with-match-limit-recursion=16000 \
- -disable-cpp
+ --$(if $(CONFIG_PACKAGE_libpcrecpp),en,dis)able-cpp
MAKE_FLAGS += \
CFLAGS="$(TARGET_CFLAGS)"
@@ -109,7 +116,13 @@ define Package/libpcre32/install
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libpcre32.so* $(1)/usr/lib/
endef
+define Package/libpcrecpp/install
+ $(INSTALL_DIR) $(1)/usr/lib
+ $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpcrecpp.so.* $(1)/usr/lib/
+endef
+
$(eval $(call BuildPackage,libpcre))
$(eval $(call BuildPackage,libpcre16))
$(eval $(call BuildPackage,libpcre32))
+$(eval $(call BuildPackage,libpcrecpp))
$(eval $(call HostBuild))