Package: libpcre2-dev Version: 10.42-1 Severity: normal Tags: patch Dear Maintainer,
The pcre2 package is currently built using autoconf/configure. The problem with this is that essential cmake configuration files are not installed and thus missing on a regular Debian system. Swithing to using cmake for building and installing fixes this problem. I've included a patch that seems to work on my system. -- System Information: Debian Release: 12.11 APT prefers stable-security APT policy: (500, 'stable-security'), (500, 'stable') Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 6.1.0-37-amd64 (SMP w/2 CPU threads; PREEMPT) Locale: LANG=nl_NL.UTF-8, LC_CTYPE=nl_NL.UTF-8 (charmap=UTF-8), LANGUAGE not set Shell: /bin/sh linked to /usr/bin/dash Init: systemd (via /run/systemd/system) LSM: AppArmor: enabled Versions of packages libpcre2-dev depends on: ii libc6-dev [libc-dev] 2.36-9+deb12u10 ii libpcre2-16-0 10.42-1 ii libpcre2-32-0 10.42-1 ii libpcre2-8-0 10.42-1 ii libpcre2-posix3 10.42-1 libpcre2-dev recommends no packages. libpcre2-dev suggests no packages. -- no debconf information diff --git a/debian/compat b/debian/compat index ec63514..b4de394 100644 --- a/debian/compat +++ b/debian/compat @@ -1 +1 @@ -9 +11 diff --git a/debian/control b/debian/control index 248e6c7..3ee628b 100644 --- a/debian/control +++ b/debian/control @@ -3,7 +3,8 @@ Section: libs Priority: optional Maintainer: Matthew Vernon <[email protected]> Standards-Version: 4.5.1 -Build-Depends: debhelper (>=9), dpkg-dev (>= 1.16.1~), dh-autoreconf +Build-Depends: cmake (>= 3.15), dh-cmake, dh-cmake-compat (= 1), dh-sequence-cmake, + debhelper (>= 11) Vcs-Git: https://salsa.debian.org/debian/pcre2.git Vcs-Browser: https://salsa.debian.org/debian/pcre2 Homepage: https://github.com/PCRE2Project/pcre2 diff --git a/debian/libpcre2-dev.install b/debian/libpcre2-dev.install index 52ce644..4f37f69 100644 --- a/debian/libpcre2-dev.install +++ b/debian/libpcre2-dev.install @@ -2,5 +2,5 @@ debian/tmp/usr/include/* debian/tmp/usr/lib/*/lib*.a debian/tmp/usr/lib/*/lib*.so debian/tmp/usr/lib/*/pkgconfig/* -debian/tmp/usr/bin/*-config debian/tmp/usr/share/man/man3/* +debian/tmp/usr/lib/*/cmake/pcre2/pcre2-config*.cmake diff --git a/debian/rules b/debian/rules index 1bf190f..a9860b9 100755 --- a/debian/rules +++ b/debian/rules @@ -1,26 +1,26 @@ #!/usr/bin/make -f # See debhelper(7) # output every command that modifies files on the build system. -#DH_VERBOSE = 1 +DH_VERBOSE = 1 # see dpkg-buildflags(1) DPKG_EXPORT_BUILDFLAGS = 1 -include /usr/share/dpkg/default.mk +# include /usr/share/dpkg/default.mk # prefix names of functions in libpcreposix with PCRE2 to avoid clash with # ones in libc. export DEB_CFLAGS_MAINT_APPEND = -Dregcomp=PCRE2regcomp -Dregexec=PCRE2regexec -Dregerror=PCRE2regerror -Dregfree=PCRE2regfree - -deb_maint_conf_args = --enable-pcre2-16 --enable-pcre2-32 --disable-pcre2grep-callout +# deb_maint_conf_args = --enable-pcre2-16 --enable-pcre2-32 --disable-pcre2grep-callout +deb_maint_conf_args = -DBUILD_SHARED_LIBS=ON -DPCRE2_BUILD_PCRE2_8=ON -DPCRE2_BUILD_PCRE2_16=ON -DPCRE2_BUILD_PCRE2_32=ON -DPCRE2GREP_SUPPORT_CALLOUT=OFF #enable JIT only on architectures that support it (see pcre2jit.3) -ifneq ($(filter amd64 armhf arm64 i386 loong64 mips mipsel mips64el powerpc ppc64 ppc64el riscv64 s390x, $(DEB_HOST_ARCH)),) -deb_maint_conf_args +=--enable-jit +ifneq ($(filter i386 amd64 armel armhf mips mipsel mips64el powerpc sparc arm64 ppc64 ppc64el s390x, $(DEB_HOST_ARCH)),) +deb_maint_conf_args += -DPCRE2_SUPPORT_JIT=ON else -deb_maint_conf_args +=--disable-jit +deb_maint_conf_args += -DPCRE2_SUPPORT_JIT=OFF endif %: - dh $@ --parallel --with autoreconf + dh $@ --buildsystem=cmake override_dh_auto_configure: dh_auto_configure -- $(deb_maint_conf_args)

