diff --git a/README.md b/README.md index 20c45df9c..291faca3b 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ Install necessary distribution packages. For example on debian/ubuntu: ``` apt update -y apt upgrade -y -apt install -y git autoconf automake m4 make bison flex binutils libtool gcc g++ libc-dev libpam0g-dev python3 psmisc libtokyocabinet-dev libssl-dev libpcre3-dev default-jre-headless build-essential fakeroot ntp dpkg-dev debhelper pkg-config nfs-common sudo apt-utils wget libncurses5 rsync libexpat1-dev libexpat1 curl +apt install -y git autoconf automake m4 make bison flex binutils libtool gcc g++ libc-dev libpam0g-dev python3 psmisc libtokyocabinet-dev libssl-dev libpcre2-dev default-jre-headless build-essential fakeroot ntp dpkg-dev debhelper pkg-config nfs-common sudo apt-utils wget libncurses5 rsync libexpat1-dev libexpat1 curl apt purge -y emacs emacs24 libltdl-dev libltdl7 ``` @@ -138,7 +138,8 @@ File `install-dependencies` and the relevant subdirectories in `deps-packaging` | [LMDB](https://github.com/LMDB/lmdb/) | 0.9.30 | 0.9.30 | 0.9.30 | | | [OpenLDAP](http://www.openldap.org/software/download/OpenLDAP/openldap-release/) | 2.6.4 | 2.6.4 | 2.6.4 | Enterprise agent only | | [OpenSSL](http://openssl.org/) | 1.1.1t | 3.0.8 | 3.1.1 | | -| [PCRE](http://ftp.csx.cam.ac.uk/pub/software/programming/pcre/) | 8.45 | 8.45 | 8.45 | | +| [PCRE](http://ftp.csx.cam.ac.uk/pub/software/programming/pcre/) | 8.45 | 8.45 | - | | +| [PCRE2](https://github.com/PCRE2Project/pcre2/releases/) | - | - | 10.42 | | | [pthreads-w32](ftp://sourceware.org/pub/pthreads-win32/) | 2-9-1 | 2-9-1 | 2-9-1 | Windows Enterprise agent | | [SASL2](https://cyrusimap.org/mediawiki/index.php/Downloads) | 2.1.28 | 2.1.28 | 2.1.28 | Solaris Enterprise agent | | [zlib](http://www.zlib.net/) | 1.2.13 | 1.2.13 | 1.2.13 | | diff --git a/build-scripts/compile-options b/build-scripts/compile-options index c1f3093c8..11b091805 100644 --- a/build-scripts/compile-options +++ b/build-scripts/compile-options @@ -108,7 +108,7 @@ case "$OS_FAMILY" in solaris|aix) var_append DEPS "libgcc" ;; esac -var_append DEPS "$EMBEDDED_DB pcre" +var_append DEPS "$EMBEDDED_DB pcre2" if ! [ x"$SYSTEM_SSL" = x1 ] then diff --git a/build-scripts/configure b/build-scripts/configure index 2b9ae3d91..e113aac0d 100755 --- a/build-scripts/configure +++ b/build-scripts/configure @@ -15,7 +15,7 @@ esac P=$BUILDPREFIX -ARGS="--prefix=$P --libdir=$P/lib --with-workdir=$P --sysconfdir=/etc --with-openssl=$P --with-pcre=$P --with-init-script" +ARGS="--prefix=$P --libdir=$P/lib --with-workdir=$P --sysconfdir=/etc --with-openssl=$P --with-pcre2=$P --with-init-script" if [ $EMBEDDED_DB = lmdb ] then diff --git a/build-scripts/configure-docs b/build-scripts/configure-docs index 6af241e97..4b080834f 100755 --- a/build-scripts/configure-docs +++ b/build-scripts/configure-docs @@ -6,6 +6,6 @@ P=/var/cfengine -ARGS="--prefix=$P --with-openssl=$P --with-pcre=$P --with-lmdb=$P --enable-docs=all" +ARGS="--prefix=$P --with-openssl=$P --with-pcre2=$P --with-lmdb=$P --enable-docs=all" cd $BASEDIR/core && env $OPTS ./configure $ARGS diff --git a/deps-packaging/apache/cfbuild-apache.spec b/deps-packaging/apache/cfbuild-apache.spec index 8ce13d9c0..1b493b8ae 100644 --- a/deps-packaging/apache/cfbuild-apache.spec +++ b/deps-packaging/apache/cfbuild-apache.spec @@ -35,7 +35,7 @@ CPPFLAGS=-I%{buildprefix}/include --with-ldap=%{prefix} \ --with-apr=%{prefix} \ --with-apr-util=%{prefix} \ - --with-pcre=%{prefix}/bin/pcre-config \ + --with-pcre=%{prefix}/bin/pcre2-config \ --with-mpm=prefork \ CPPFLAGS="$CPPFLAGS" diff --git a/deps-packaging/apache/debian/rules b/deps-packaging/apache/debian/rules index 0f8cf53e1..504541046 100755 --- a/deps-packaging/apache/debian/rules +++ b/deps-packaging/apache/debian/rules @@ -23,7 +23,7 @@ build-stamp: --with-ldap=$(PREFIX) \ --with-apr=$(PREFIX) \ --with-apr-util=$(PREFIX) \ ---with-pcre=$(PREFIX)/bin/pcre-config \ +--with-pcre=$(PREFIX)/bin/pcre2-config \ --with-mpm=prefork \ CPPFLAGS="$(CPPFLAGS)" make diff --git a/deps-packaging/pcre/cfbuild-pcre.spec b/deps-packaging/pcre/cfbuild-pcre.spec deleted file mode 100644 index 1c6a36564..000000000 --- a/deps-packaging/pcre/cfbuild-pcre.spec +++ /dev/null @@ -1,102 +0,0 @@ -%define pcre_version 8.45 - -Summary: CFEngine Build Automation -- pcre -Name: cfbuild-pcre -Version: %{version} -Release: 1 -Source0: pcre-%{pcre_version}.tar.gz -License: MIT -Group: Other -Url: http://example.com/ -BuildRoot: %{_topdir}/BUILD/%{name}-%{version}-%{release}-buildroot - -AutoReqProv: no - -%define prefix %{buildprefix} - -%prep -mkdir -p %{_builddir} -%setup -q -n pcre-%{pcre_version} - -./configure --prefix=%{prefix} --enable-unicode-properties --disable-cpp --enable-shared - -%build - -if [ -z $MAKE ]; then - MAKE_PATH=`which MAKE` - export MAKE=$MAKE_PATH -fi - -$MAKE - -SYS=`uname -s` -if ! [ "z$SYS" = "zAIX" ]; then -%if %{?with_testsuite:1}%{!?with_testsuite:0} -$MAKE check -%endif -fi - -%install -rm -rf ${RPM_BUILD_ROOT} - -$MAKE install DESTDIR=${RPM_BUILD_ROOT} - -# Removing unused files - -rm -f ${RPM_BUILD_ROOT}%{prefix}/bin/pcregrep -rm -f ${RPM_BUILD_ROOT}%{prefix}/bin/pcretest -rm -f ${RPM_BUILD_ROOT}%{prefix}/lib/libpcre.a -rm -f ${RPM_BUILD_ROOT}%{prefix}/lib/libpcre.la -rm -f ${RPM_BUILD_ROOT}%{prefix}/lib/libpcreposix.a -rm -f ${RPM_BUILD_ROOT}%{prefix}/lib/libpcreposix.la -# Do not merge those lines into single one -- any new file in share should trigger an error -rm -rf ${RPM_BUILD_ROOT}%{prefix}/share/man -rm -rf ${RPM_BUILD_ROOT}%{prefix}/share/doc -rmdir ${RPM_BUILD_ROOT}%{prefix}/share - -%clean -rm -rf $RPM_BUILD_ROOT - -%package devel -Summary: CFEngine Build Automation -- pcre -- development files -Group: Other -AutoReqProv: no - -%description -CFEngine Build Automation -- pcre - -%description devel -CFEngine Build Automation -- pcre -- development files - -%files -%defattr(-,root,root) - -%dir %prefix/lib -%prefix/lib/libpcre.so -%prefix/lib/libpcre.so.1 -%prefix/lib/libpcre.so.1.2.* -%prefix/lib/libpcreposix.so -%prefix/lib/libpcreposix.so.0 -%prefix/lib/libpcreposix.so.0.0.* - -%files devel -%defattr(-,root,root) - -%dir %prefix/bin -%prefix/bin/pcre-config - -%dir %prefix/include -%prefix/include/pcre.h -%prefix/include/pcreposix.h - -%dir %prefix/lib -%prefix/lib/libpcre.so -%prefix/lib/libpcreposix.so - -%dir %prefix/lib/pkgconfig -%prefix/lib/pkgconfig/libpcre.pc -%prefix/lib/pkgconfig/libpcreposix.pc - -%changelog - - diff --git a/deps-packaging/pcre/debian/control b/deps-packaging/pcre/debian/control deleted file mode 100644 index f277a5be2..000000000 --- a/deps-packaging/pcre/debian/control +++ /dev/null @@ -1,18 +0,0 @@ -Source: cfbuild-pcre -Section: libs -Priority: optional -Maintainer: CFEngine Packager -Build-Depends: debhelper -Standards-Version: 3.8.4 - -Package: cfbuild-pcre -Section: libs -Architecture: any -Description: CFEngine Build Automation -- pcre - CFEngine Build Automation -- pcre - -Package: cfbuild-pcre-devel -Section: libdevel -Architecture: any -Description: CFEngine Build Automation -- pcre -- development files - CFEngine Build Automation -- pcre -- development files diff --git a/deps-packaging/pcre/distfiles b/deps-packaging/pcre/distfiles deleted file mode 100644 index 57857b645..000000000 --- a/deps-packaging/pcre/distfiles +++ /dev/null @@ -1 +0,0 @@ -4e6ce03e0336e8b4a3d6c2b70b1c5e18590a5673a98186da90d4f33c23defc09 download pcre-8.45.tar.gz diff --git a/deps-packaging/pcre/freebsd/build b/deps-packaging/pcre/freebsd/build deleted file mode 100755 index 493f38404..000000000 --- a/deps-packaging/pcre/freebsd/build +++ /dev/null @@ -1,37 +0,0 @@ -#!/bin/sh - -# Options - -PREFIX=${BUILDPREFIX} - -PC=${BUILD_ROOT}/cfbuild-pcre${PREFIX} -PCD=${BUILD_ROOT}/cfbuild-pcre-devel${PREFIX} - -# Configure - -./configure --prefix=$PREFIX --enable-unicode-properties -disable-cpp - -# Build - -make - -# Test - -if [ "$TESTS" != no ]; then - make check -fi - -# Install - -make install DESTDIR=${BUILD_ROOT}/cfbuild-pcre-devel -# Package - -rm -f ${PCD}/bin/pcregrep -rm -f ${PCD}/bin/pcretest -rm -f ${PCD}/lib/*.a -rm -f ${PCD}/lib/*.la -rm -rf ${PCD}/share - -mkdir -p ${PC}/lib -mv ${PCD}/lib/*.so* ${PC}/lib - diff --git a/deps-packaging/pcre/freebsd/packages b/deps-packaging/pcre/freebsd/packages deleted file mode 100644 index a140ef417..000000000 --- a/deps-packaging/pcre/freebsd/packages +++ /dev/null @@ -1 +0,0 @@ -cfbuild-pcre cfbuild-pcre-devel diff --git a/deps-packaging/pcre/hpux/build b/deps-packaging/pcre/hpux/build deleted file mode 100755 index df592c384..000000000 --- a/deps-packaging/pcre/hpux/build +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/sh -e - -# Options - -PREFIX=${BUILDPREFIX} - -PC=${BUILD_ROOT}/cfbuild-pcre${PREFIX} -PCD=${BUILD_ROOT}/cfbuild-pcre-devel${PREFIX} - -# HP-UX needs the .libs directory in the library search path because of a -# bug in libtool: it will specify libpcre.so.3 as the dependency of -# libpcreposix.so.3, however when it links it tries to link to libpcre.so. -# Although they are the same library, the native ld is not happy with this, -# and starts looking for the libpcre.so.3 library on its own, which it won't -# find, because it wasn't listed on the command line. Hence we need to -# specify libtool's secret library stash: ".libs". -LDFLAGS="$LDFLAGS -L.libs" - -# Patch - -# Configure - -./configure --prefix=$PREFIX --enable-unicode-properties --disable-cpp - -# Build - -gmake - -# Test - -if [ "$TESTS" = all ]; then - gmake check -fi - -# Install - -gmake install DESTDIR=${BUILD_ROOT}/cfbuild-pcre-devel - -# Package - -rm -f ${PCD}/bin/pcregrep -rm -f ${PCD}/bin/pcretest -rm -f ${PCD}/lib/*.a -rm -f ${PCD}/lib/*.la -rm -rf ${PCD}/share - -mkdir -p ${PC}/lib -mv ${PCD}/lib/*.so* ${PC}/lib diff --git a/deps-packaging/pcre/hpux/packages b/deps-packaging/pcre/hpux/packages deleted file mode 100644 index a140ef417..000000000 --- a/deps-packaging/pcre/hpux/packages +++ /dev/null @@ -1 +0,0 @@ -cfbuild-pcre cfbuild-pcre-devel diff --git a/deps-packaging/pcre/mingw/debian/control b/deps-packaging/pcre/mingw/debian/control deleted file mode 100644 index c8ae57995..000000000 --- a/deps-packaging/pcre/mingw/debian/control +++ /dev/null @@ -1,18 +0,0 @@ -Source: cfbuild-pcre -Section: libs -Priority: optional -Maintainer: CFEngine Packager -Build-Depends: debhelper -Standards-Version: 3.8.4 - -Package: cfbuild-pcre-mingw64 -Section: libs -Architecture: all -Description: CFEngine Build Automation -- pcre -- mingw64 - CFEngine Build Automation -- pcre -- mingw64 - -Package: cfbuild-pcre-mingw64-devel -Section: libdevel -Architecture: all -Description: CFEngine Build Automation -- pcre -- mingw64 -- development files - CFEngine Build Automation -- pcre -- mingw64 -- development files diff --git a/deps-packaging/pcre/solaris-8-inttypes.patch b/deps-packaging/pcre/solaris-8-inttypes.patch deleted file mode 100644 index c420bd290..000000000 --- a/deps-packaging/pcre/solaris-8-inttypes.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- pcre_internal.h.orig 2012-03-13 16:19:53.966210786 +0100 -+++ pcre_internal.h 2012-03-13 16:19:41.094210593 +0100 -@@ -91,6 +91,8 @@ - #include - #include - -+#include -+ - /* Valgrind (memcheck) support */ - - #ifdef SUPPORT_VALGRIND diff --git a/deps-packaging/pcre/solaris/build b/deps-packaging/pcre/solaris/build deleted file mode 100755 index 54c494b67..000000000 --- a/deps-packaging/pcre/solaris/build +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/xpg4/bin/sh -e - -# Options - -PREFIX=${BUILDPREFIX} - -PC=${BUILD_ROOT}/cfbuild-pcre${PREFIX} -PCD=${BUILD_ROOT}/cfbuild-pcre-devel${PREFIX} - -# Patch - -$PATCH -p0 < solaris-8-inttypes.patch - -# Configure - -./configure --prefix=$PREFIX --enable-unicode-properties --disable-cpp - -# Build - -$MAKE - -# Test - -if [ "$TESTS" = all ]; then - $MAKE check -fi - -# Install - -$MAKE install DESTDIR=${BUILD_ROOT}/cfbuild-pcre-devel - -# Package - -rm -f ${PCD}/bin/pcregrep -rm -f ${PCD}/bin/pcretest -rm -f ${PCD}/lib/*.a -rm -f ${PCD}/lib/*.la -rm -rf ${PCD}/share - -mkdir -p ${PC}/lib -mv ${PCD}/lib/*.so* ${PC}/lib diff --git a/deps-packaging/pcre/solaris/packages b/deps-packaging/pcre/solaris/packages deleted file mode 100644 index a140ef417..000000000 --- a/deps-packaging/pcre/solaris/packages +++ /dev/null @@ -1 +0,0 @@ -cfbuild-pcre cfbuild-pcre-devel diff --git a/deps-packaging/pcre/source b/deps-packaging/pcre/source deleted file mode 100644 index 4a300bd1a..000000000 --- a/deps-packaging/pcre/source +++ /dev/null @@ -1 +0,0 @@ -https://sourceforge.net/projects/pcre/files/pcre/8.45/pcre-8.45.tar.gz/ diff --git a/deps-packaging/pcre2/cfbuild-pcre2.spec b/deps-packaging/pcre2/cfbuild-pcre2.spec new file mode 100644 index 000000000..44faab443 --- /dev/null +++ b/deps-packaging/pcre2/cfbuild-pcre2.spec @@ -0,0 +1,91 @@ +%define pcre2_version 10.42 + +Summary: CFEngine Build Automation -- pcre2 +Name: cfbuild-pcre2 +Version: %{version} +Release: 1 +Source0: pcre2-%{pcre2_version}.tar.gz +License: MIT +Group: Other +Url: http://example.com/ +BuildRoot: %{_topdir}/BUILD/%{name}-%{version}-%{release}-buildroot + +AutoReqProv: no + +%define prefix %{buildprefix} + +%prep +mkdir -p %{_builddir} +%setup -q -n pcre2-%{pcre2_version} + +./configure --prefix=%{prefix} --enable-shared --disable-static + +%build + +if [ -z $MAKE ]; then + MAKE_PATH=`which MAKE` + export MAKE=$MAKE_PATH +fi + +$MAKE + +SYS=`uname -s` +if ! [ "z$SYS" = "zAIX" ]; then +%if %{?with_testsuite:1}%{!?with_testsuite:0} +$MAKE check +%endif +fi + +%install +rm -rf ${RPM_BUILD_ROOT} + +$MAKE install DESTDIR=${RPM_BUILD_ROOT} + +# Removing unused files + +rm -f ${RPM_BUILD_ROOT}%{prefix}/bin/pcre2grep +rm -f ${RPM_BUILD_ROOT}%{prefix}/bin/pcre2test +rm -f ${RPM_BUILD_ROOT}%{prefix}/lib/libpcre2-8.la +rm -f ${RPM_BUILD_ROOT}%{prefix}/lib/libpcre2-posix.* +rm -f ${RPM_BUILD_ROOT}%{prefix}/lib/pkgconfig/libpcre2-posix.pc +rm -f ${RPM_BUILD_ROOT}%{prefix}/include/pcre2posix.h +# Do not merge those lines into single one -- any new file in share should trigger an error +rm -rf ${RPM_BUILD_ROOT}%{prefix}/share/man +rm -rf ${RPM_BUILD_ROOT}%{prefix}/share/doc +rmdir ${RPM_BUILD_ROOT}%{prefix}/share + +%clean +rm -rf $RPM_BUILD_ROOT + +%package devel +Summary: CFEngine Build Automation -- pcre2 -- development files +Group: Other +AutoReqProv: no + +%description +CFEngine Build Automation -- pcre2 + +%description devel +CFEngine Build Automation -- pcre2 -- development files + +%files +%defattr(-,root,root) + +%dir %prefix/lib +%prefix/lib/libpcre2-8.so.0.11.* +%prefix/lib/libpcre2-8.so.0 +%prefix/lib/libpcre2-8.so + +%files devel +%defattr(-,root,root) + +%dir %prefix/bin +%{prefix}/bin/pcre2-config + +%dir %prefix/include +%prefix/include/pcre2.h + +%dir %prefix/lib/pkgconfig +%prefix/lib/pkgconfig/libpcre2-8.pc + +%changelog diff --git a/deps-packaging/pcre/debian/cfbuild-pcre-devel.install b/deps-packaging/pcre2/debian/cfbuild-pcre2-devel.install similarity index 70% rename from deps-packaging/pcre/debian/cfbuild-pcre-devel.install rename to deps-packaging/pcre2/debian/cfbuild-pcre2-devel.install index 45269c6a0..3de89b8e4 100644 --- a/deps-packaging/pcre/debian/cfbuild-pcre-devel.install +++ b/deps-packaging/pcre2/debian/cfbuild-pcre2-devel.install @@ -1,4 +1,4 @@ -/var/cfengine/bin/pcre-config +/var/cfengine/bin/pcre2-config /var/cfengine/include /var/cfengine/lib/*.so /var/cfengine/lib/pkgconfig diff --git a/deps-packaging/pcre/debian/cfbuild-pcre.install b/deps-packaging/pcre2/debian/cfbuild-pcre2.install similarity index 100% rename from deps-packaging/pcre/debian/cfbuild-pcre.install rename to deps-packaging/pcre2/debian/cfbuild-pcre2.install diff --git a/deps-packaging/pcre/debian/compat b/deps-packaging/pcre2/debian/compat similarity index 100% rename from deps-packaging/pcre/debian/compat rename to deps-packaging/pcre2/debian/compat diff --git a/deps-packaging/pcre2/debian/control b/deps-packaging/pcre2/debian/control new file mode 100644 index 000000000..22968aa3d --- /dev/null +++ b/deps-packaging/pcre2/debian/control @@ -0,0 +1,18 @@ +Source: cfbuild-pcre2 +Section: libs +Priority: optional +Maintainer: CFEngine Packager +Build-Depends: debhelper +Standards-Version: 3.8.4 + +Package: cfbuild-pcre2 +Section: libs +Architecture: any +Description: CFEngine Build Automation -- pcre2 + CFEngine Build Automation -- pcre2 + +Package: cfbuild-pcre2-devel +Section: libdevel +Architecture: any +Description: CFEngine Build Automation -- pcre2 -- development files + CFEngine Build Automation -- pcre2 -- development files diff --git a/deps-packaging/pcre/debian/copyright b/deps-packaging/pcre2/debian/copyright similarity index 100% rename from deps-packaging/pcre/debian/copyright rename to deps-packaging/pcre2/debian/copyright diff --git a/deps-packaging/pcre/debian/rules b/deps-packaging/pcre2/debian/rules similarity index 68% rename from deps-packaging/pcre/debian/rules rename to deps-packaging/pcre2/debian/rules index ecbcd4294..1439a9436 100755 --- a/deps-packaging/pcre/debian/rules +++ b/deps-packaging/pcre2/debian/rules @@ -12,7 +12,7 @@ build: build-stamp build-stamp: dh_testdir - ./configure --prefix=$(PREFIX) --enable-unicode-properties --disable-cpp + ./configure --prefix=$(PREFIX) --enable-shared --disable-static make ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS))) make check @@ -28,12 +28,12 @@ install: build $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp - rm -f $(CURDIR)/debian/tmp$(PREFIX)/bin/pcregrep - rm -f $(CURDIR)/debian/tmp$(PREFIX)/bin/pcretest - rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/libpcre.a - rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/libpcre.la - rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/libpcreposix.a - rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/libpcreposix.la + rm -f $(CURDIR)/debian/tmp$(PREFIX)/bin/pcre2grep + rm -f $(CURDIR)/debian/tmp$(PREFIX)/bin/pcre2test + rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/libpcre2-8.la + rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/libpcre2-posix.* + rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/pkgconfig/libpcre2-posix.pc + rm -f $(CURDIR)/debian/tmp$(PREFIX)/include/pcre2posix.h # Do not merge those lines into single one -- any new file in share should trigger an error rm -rf $(CURDIR)/debian/tmp$(PREFIX)/share/man rm -rf $(CURDIR)/debian/tmp$(PREFIX)/share/doc diff --git a/deps-packaging/pcre2/distfiles b/deps-packaging/pcre2/distfiles new file mode 100644 index 000000000..1b005b483 --- /dev/null +++ b/deps-packaging/pcre2/distfiles @@ -0,0 +1,2 @@ +c33b418e3b936ee3153de2c61cc638e7e4fe3156022a5c77d0711bcbb9d64f1f pcre2-10.42.tar.gz + diff --git a/deps-packaging/pcre2/freebsd/build b/deps-packaging/pcre2/freebsd/build new file mode 100755 index 000000000..c52dd0d10 --- /dev/null +++ b/deps-packaging/pcre2/freebsd/build @@ -0,0 +1,39 @@ +#!/bin/sh + +# Options + +PREFIX=${BUILDPREFIX} + +PC=${BUILD_ROOT}/cfbuild-pcre2${PREFIX} +PCD=${BUILD_ROOT}/cfbuild-pcre2-devel${PREFIX} + +# Configure + +./configure --prefix=${PREFIX} --enable-shared --disable-static + +# Build + +make + +# Test + +if [ "$TESTS" != no ]; then + make check +fi + +# Install + +make install DESTDIR=${BUILD_ROOT}/cfbuild-pcre2-devel +# Package + +rm -f ${PCD}/bin/pcre2grep +rm -f ${PCD}/bin/pcre2test +rm -f ${PCD}/lib/*.la +rm -f ${PCD}/lib/libpcre2-posix.* +rm -f ${PCD}/lib/pkgconfig/libpcre2-posix.pc +rm -f ${PCD}/include/pcre2posix.h +rm -rf ${PCD}/share + +mkdir -p ${PC}/lib +mv ${PCD}/lib/*.so* ${PC}/lib + diff --git a/deps-packaging/pcre2/freebsd/packages b/deps-packaging/pcre2/freebsd/packages new file mode 100644 index 000000000..c40f36c83 --- /dev/null +++ b/deps-packaging/pcre2/freebsd/packages @@ -0,0 +1 @@ +cfbuild-pcre2 cfbuild-pcre2-devel diff --git a/deps-packaging/pcre2/hpux/build b/deps-packaging/pcre2/hpux/build new file mode 100755 index 000000000..6b3b21e10 --- /dev/null +++ b/deps-packaging/pcre2/hpux/build @@ -0,0 +1,43 @@ +#!/bin/sh -e + +# Options + +PREFIX=${BUILDPREFIX} + +PC=${BUILD_ROOT}/cfbuild-pcre2${PREFIX} +PCD=${BUILD_ROOT}/cfbuild-pcre2-devel${PREFIX} + +# Patch + +$PATCH -p0 < hpux_size_max_stdint_h.patch + +# Configure + +./configure --prefix=${PREFIX} --enable-shared --disable-static + +# Build + +gmake + +# Test + +if [ "$TESTS" = all ]; then + gmake check +fi + +# Install + +gmake install DESTDIR=${BUILD_ROOT}/cfbuild-pcre2-devel + +# Package + +rm -f ${PCD}/bin/pcre2grep +rm -f ${PCD}/bin/pcre2test +rm -f ${PCD}/lib/*.la +rm -f ${PCD}/lib/libpcre2-posix.* +rm -f ${PCD}/lib/pkgconfig/libpcre2-posix.pc +rm -f ${PCD}/include/pcre2posix.h +rm -rf ${PCD}/share + +mkdir -p ${PC}/lib +mv ${PCD}/lib/*.so* ${PC}/lib diff --git a/deps-packaging/pcre2/hpux/packages b/deps-packaging/pcre2/hpux/packages new file mode 100644 index 000000000..c40f36c83 --- /dev/null +++ b/deps-packaging/pcre2/hpux/packages @@ -0,0 +1 @@ +cfbuild-pcre2 cfbuild-pcre2-devel diff --git a/deps-packaging/pcre2/hpux_size_max_stdint_h.patch b/deps-packaging/pcre2/hpux_size_max_stdint_h.patch new file mode 100644 index 000000000..6f1dbdbc6 --- /dev/null +++ b/deps-packaging/pcre2/hpux_size_max_stdint_h.patch @@ -0,0 +1,13 @@ +--- ./src/pcre2.h.generic.orig 2022-12-12 18:10:40.000000000 +0100 ++++ ./src/pcre2.h.generic 2023-12-08 12:50:07.739772696 +0100 +@@ -91,6 +91,10 @@ + #include + #include + ++/* HP-UX doesn't follow the C standard mentioned above and inttypes.h doesn't ++contain stdint.h */ ++#include ++ + /* Allow for C++ users compiling this directly. */ + + #ifdef __cplusplus diff --git a/deps-packaging/pcre/mingw/debian/cfbuild-pcre-mingw64-devel.install b/deps-packaging/pcre2/mingw/debian/cfbuild-pcre2-mingw64-devel.install similarity index 100% rename from deps-packaging/pcre/mingw/debian/cfbuild-pcre-mingw64-devel.install rename to deps-packaging/pcre2/mingw/debian/cfbuild-pcre2-mingw64-devel.install diff --git a/deps-packaging/pcre/mingw/debian/cfbuild-pcre-mingw64.install b/deps-packaging/pcre2/mingw/debian/cfbuild-pcre2-mingw64.install similarity index 100% rename from deps-packaging/pcre/mingw/debian/cfbuild-pcre-mingw64.install rename to deps-packaging/pcre2/mingw/debian/cfbuild-pcre2-mingw64.install diff --git a/deps-packaging/pcre/mingw/debian/compat b/deps-packaging/pcre2/mingw/debian/compat similarity index 100% rename from deps-packaging/pcre/mingw/debian/compat rename to deps-packaging/pcre2/mingw/debian/compat diff --git a/deps-packaging/pcre2/mingw/debian/control b/deps-packaging/pcre2/mingw/debian/control new file mode 100644 index 000000000..bd9f6433a --- /dev/null +++ b/deps-packaging/pcre2/mingw/debian/control @@ -0,0 +1,18 @@ +Source: cfbuild-pcre2 +Section: libs +Priority: optional +Maintainer: CFEngine Packager +Build-Depends: debhelper +Standards-Version: 3.8.4 + +Package: cfbuild-pcre2-mingw64 +Section: libs +Architecture: all +Description: CFEngine Build Automation -- pcre2 -- mingw64 + CFEngine Build Automation -- pcre2 -- mingw64 + +Package: cfbuild-pcre2-mingw64-devel +Section: libdevel +Architecture: all +Description: CFEngine Build Automation -- pcre2 -- mingw64 -- development files + CFEngine Build Automation -- pcre2 -- mingw64 -- development files diff --git a/deps-packaging/pcre/mingw/debian/copyright b/deps-packaging/pcre2/mingw/debian/copyright similarity index 100% rename from deps-packaging/pcre/mingw/debian/copyright rename to deps-packaging/pcre2/mingw/debian/copyright diff --git a/deps-packaging/pcre/mingw/debian/rules b/deps-packaging/pcre2/mingw/debian/rules similarity index 70% rename from deps-packaging/pcre/mingw/debian/rules rename to deps-packaging/pcre2/mingw/debian/rules index 2af8748eb..5830c5300 100755 --- a/deps-packaging/pcre/mingw/debian/rules +++ b/deps-packaging/pcre2/mingw/debian/rules @@ -12,7 +12,7 @@ build: build-stamp build-stamp: dh_testdir - ./configure --host=$(DEB_HOST_GNU_TYPE) --prefix=$(PREFIX) --enable-unicode-properties --disable-cpp + ./configure --host=$(DEB_HOST_GNU_TYPE) --prefix=$(PREFIX) --enable-shared --disable-static make touch build-stamp @@ -25,12 +25,12 @@ install: build $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp - rm -f $(CURDIR)/debian/tmp$(PREFIX)/bin/pcregrep.exe - rm -f $(CURDIR)/debian/tmp$(PREFIX)/bin/pcretest.exe - rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/libpcre.a - rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/libpcre.la - rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/libpcreposix.a - rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/libpcreposix.la + rm -f $(CURDIR)/debian/tmp$(PREFIX)/bin/pcre2grep.exe + rm -f $(CURDIR)/debian/tmp$(PREFIX)/bin/pcre2test.exe + rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/libpcre2.la + rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/libpcre2posix*.* + rm -f $(CURDIR)/debian/tmp$(PREFIX)/lib/pkgconfig/libpcre2-posix.pc + rm -f $(CURDIR)/debian/tmp$(PREFIX)/include/pcre2posix.h # Do not merge those lines into single one -- any new file in share should trigger an error rm -rf $(CURDIR)/debian/tmp$(PREFIX)/share/man rm -rf $(CURDIR)/debian/tmp$(PREFIX)/share/doc diff --git a/deps-packaging/pcre2/solaris/build b/deps-packaging/pcre2/solaris/build new file mode 100755 index 000000000..1fb7f3e95 --- /dev/null +++ b/deps-packaging/pcre2/solaris/build @@ -0,0 +1,39 @@ +#!/usr/xpg4/bin/sh -e + +# Options + +PREFIX=${BUILDPREFIX} + +PC=${BUILD_ROOT}/cfbuild-pcre2${PREFIX} +PCD=${BUILD_ROOT}/cfbuild-pcre2-devel${PREFIX} + +# Configure + +./configure --prefix=${PREFIX} --enable-shared --disable-static + +# Build + +$MAKE + +# Test + +if [ "$TESTS" = all ]; then + $MAKE check +fi + +# Install + +$MAKE install DESTDIR=${BUILD_ROOT}/cfbuild-pcre2-devel + +# Package + +rm -f ${PCD}/bin/pcre2grep +rm -f ${PCD}/bin/pcre2test +rm -f ${PCD}/lib/*.la +rm -f ${PCD}/lib/libpcre2-posix.* +rm -f ${PCD}/lib/pkgconfig/libpcre2-posix.pc +rm -f ${PCD}/include/pcre2posix.h +rm -rf ${PCD}/share + +mkdir -p ${PC}/lib +mv ${PCD}/lib/*.so* ${PC}/lib diff --git a/deps-packaging/pcre2/solaris/packages b/deps-packaging/pcre2/solaris/packages new file mode 100644 index 000000000..c40f36c83 --- /dev/null +++ b/deps-packaging/pcre2/solaris/packages @@ -0,0 +1 @@ +cfbuild-pcre2 cfbuild-pcre2-devel diff --git a/deps-packaging/pcre2/source b/deps-packaging/pcre2/source new file mode 100644 index 000000000..dc54aa8be --- /dev/null +++ b/deps-packaging/pcre2/source @@ -0,0 +1 @@ +https://github.com/PCRE2Project/pcre2/releases/download/pcre2-10.42/ diff --git a/deps-packaging/release-monitoring.json b/deps-packaging/release-monitoring.json index fadcacee1..e9749b68e 100644 --- a/deps-packaging/release-monitoring.json +++ b/deps-packaging/release-monitoring.json @@ -16,7 +16,7 @@ "lmdb":"6974", "openldap":"2551", "openssl":"2566", - "pcre":"2610", + "pcre2":"5832", "php":"3627", "postgresql":"301832", "pthreads-w32":"17517", diff --git a/packaging/cfengine-nova/cfengine-nova.wxs b/packaging/cfengine-nova/cfengine-nova.wxs index 0f74e6e98..32d7445ae 100644 --- a/packaging/cfengine-nova/cfengine-nova.wxs +++ b/packaging/cfengine-nova/cfengine-nova.wxs @@ -129,8 +129,8 @@ - - + + @@ -197,7 +197,7 @@ - +