Sync from SUSE:SLFO:Main pcre2 revision dc5d4fdb6ff52f8404fca95261e34951

This commit is contained in:
Adrian Schröter 2024-05-03 17:45:34 +02:00
commit 2e114ab218
8 changed files with 1740 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

4
baselibs.conf Normal file
View File

@ -0,0 +1,4 @@
libpcre2-8-0
libpcre2-16-0
libpcre2-32-0
libpcre2-posix3

View File

@ -0,0 +1,34 @@
From 1d5ce3e2e6341b01609aefab20786a8638fee17a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com>
Date: Tue, 6 Dec 2011 18:44:11 +0100
Subject: [PATCH] Fix multilib
Do not set RPATH nor add explicit -L path to compiler.
---
pcre2-config.in | 12 ------------
1 file changed, 12 deletions(-)
Index: pcre2-10.10/pcre2-config.in
===================================================================
--- pcre2-10.10.orig/pcre2-config.in 2014-10-17 17:07:57.000000000 +0200
+++ pcre2-10.10/pcre2-config.in 2015-06-18 20:56:20.000000000 +0200
@@ -28,19 +28,7 @@ if test $# -eq 0; then
fi
libR=
-case `uname -s` in
- *SunOS*)
- libR=" -R@libdir@"
- ;;
- *BSD*)
- libR=" -Wl,-R@libdir@"
- ;;
-esac
-
libS=
-if test @libdir@ != /usr/lib ; then
- libS=-L@libdir@
-fi
while test $# -gt 0; do
case "$1" in

BIN
pcre2-10.42.tar.bz2 (Stored with Git LFS) Normal file

Binary file not shown.

BIN
pcre2-10.42.tar.bz2.sig Normal file

Binary file not shown.

1373
pcre2.changes Normal file

File diff suppressed because it is too large Load Diff

39
pcre2.keyring Normal file
View File

@ -0,0 +1,39 @@
This is Philip Hazel's public GPG key.
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v1.2.0 (SunOS)
mQEMBD2z9g0BCACpGWJ4K2mjR6K9nv7/K+HLjJtDO0E0ckudeNjg2JvnuUU7m1bK
87nSklHTSMNiqmuVU5hFAuGiMGBMj31GPpce3VbABdm6TmAJB8ZndvJXyf8lC7Ko
5iZX/gCYU6817UI5pFwYR3MTIUSSxTGqk1y62pYLKUq9keSU5Cew4q1KMwl46Bn3
SwlfQeST4WGwL2w9b8mWNltBBY23bgzwYu7vFBD4GQnfzJsvMC9lj825wob2nKy5
CL4bY6tiYUqALzDYaIVCBqJ1Ky1rpPzRcDZUeeF8Ta3njh18Y0KzPEj+Xu5Ksexg
7LUy/2wFzVRtJgqvAFZo43KIOptsj/63zxJjAAkBAbQhUGhpbGlwIEhhemVsIDxw
aDEwQGN1cy5jYW0uYWMudWs+iQEyBBMBAgAcBQI9s/YNAhsDBAsHAwIDFQIDAxYC
AQIeAQIXgAAKCRCXZuCE+w9D2JbrCACBHrxybV+9t3TGR3+uk2QnUuct90a+udcB
cbWgKQgX345ZgwIfyoPKAbG84mN/+SFUN/Ie4ZHZxVsbN//l2P/Osx0C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aey78LQAGKYkBHwQYAQIACQUCPbP3iQIbDAAKCRCX
ZuCE+w9D2P0BCACXsbwFerd4wlnt8PxxQlRGXi1t4EGBFf2zSdgQvIXJ3ntPzcDU
+8hnIWQJhCTZ3PfVmoqB6ZOM1RWI/IcP6b4qVb6vJGI/VxRICraAczw+4bdFxFiB
n2+SyD4MxZg8t66FcH3fHugQqsApHTmtKmahv5BXB+0dPmP/BRUmzxYUv8hdnhHl
91S4R4BDu84DvKYyJK9jlqUl06pvqXrBSNsbWKgAJnmnDe8FaLUk+p0IXeMSavUn
T5E26MRIioxAz/G4FZI8IdO92GHTz82O7/mQMhveAdpspDvpV3M4wnldU425GlxZ
nmq1bbjAU4QVuIS9nkk2GrGx5+N6cYMy8JqG
=EHsz
-----END PGP PUBLIC KEY BLOCK-----

264
pcre2.spec Normal file
View File

@ -0,0 +1,264 @@
#
# spec file for package pcre2
#
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%global _lto_cflags %{_lto_cflags} -ffat-lto-objects
Name: pcre2
Version: 10.42
Release: 0
Summary: A library for Perl-compatible regular expressions
License: BSD-3-Clause
Group: Development/Libraries/C and C++
URL: https://www.pcre.org
Source0: https://github.com/PhilipHazel/pcre2/releases/download/%{name}-%{version}/%{name}-%{version}.tar.bz2
Source2: https://github.com/PhilipHazel/pcre2/releases/download/%{name}-%{version}/%{name}-%{version}.tar.bz2.sig
Source3: %{name}.keyring
Source4: baselibs.conf
#PATCH-FIX-OPENSUSE tchvatal@suse.cz upstream thinks it is good idea to use rpath, taken from RH
Patch1: pcre2-10.10-multilib.patch
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: gcc-c++
BuildRequires: libbz2-devel
BuildRequires: libedit-devel
BuildRequires: libtool
BuildRequires: pkgconfig
BuildRequires: pkgconfig(zlib)
%description
The PCRE2 library is a set of functions that implement regular
expression pattern matching using the same syntax and semantics
as Perl 5.
PCRE2 is a re-working of the original PCRE library to provide an entirely new
API.
%package devel
Summary: A library for Perl-compatible regular expressions
Group: Development/Libraries/C and C++
Requires: libpcre2-16-0 = %{version}
Requires: libpcre2-32-0 = %{version}
Requires: libpcre2-8-0 = %{version}
Requires: libpcre2-posix3 = %{version}
Requires: libstdc++-devel
%description devel
The PCRE2 library is a set of functions that implement regular
expression pattern matching using the same syntax and semantics
as Perl 5.
PCRE2 is a re-working of the original PCRE library to provide an entirely new
API.
%package devel-static
Summary: A library for Perl-compatible regular expressions
Group: Development/Libraries/C and C++
Requires: pcre2-devel = %{version}
%description devel-static
The PCRE2 library is a set of functions that implement regular
expression pattern matching using the same syntax and semantics
as Perl 5.
PCRE2 is a re-working of the original PCRE library to provide an entirely new
API.
This package contains static versions of the PCRE2 libraries.
%package -n libpcre2-8-0
Summary: A library for Perl-compatible regular expressions
Group: System/Libraries
%description -n libpcre2-8-0
The PCRE2 library is a set of functions that implement regular
expression pattern matching using the same syntax and semantics
as Perl 5.
PCRE2 is a re-working of the original PCRE library to provide an entirely new
API.
This PCRE2 library variant supports 8-bit and UTF-8 strings.
(See also libpcre2-16 and libpcre2-32)
%package -n libpcre2-16-0
Summary: A library for Perl-compatible regular expressions
Group: System/Libraries
%description -n libpcre2-16-0
The PCRE2 library is a set of functions that implement regular
expression pattern matching using the same syntax and semantics
as Perl 5.
PCRE2 is a re-working of the original PCRE library to provide an entirely new
API.
libpcre2-16 supports 16-bit and UTF-16 strings.
%package -n libpcre2-32-0
Summary: A library for Perl-compatible regular expressions
Group: System/Libraries
%description -n libpcre2-32-0
The PCRE2 library is a set of functions that implement regular
expression pattern matching using the same syntax and semantics
as Perl 5.
PCRE2 is a re-working of the original PCRE library to provide an entirely new
API.
libpcre2-32 supports 32-bit and UTF-32 strings.
%package -n libpcre2-posix3
Summary: A library for Perl-compatible regular expressions
Group: System/Libraries
%description -n libpcre2-posix3
The PCRE2 library is a set of functions that implement regular
expression pattern matching using the same syntax and semantics
as Perl 5.
PCRE2 is a re-working of the original PCRE library to provide an entirely new
API.
pcre2-posix provides a POSIX-compatible API to the PCRE2 engine.
%package doc
Summary: A library for Perl-compatible regular expressions
Group: Documentation/HTML
BuildArch: noarch
%description doc
The PCRE2 library is a set of functions that implement regular
expression pattern matching using the same syntax and semantics
as Perl 5.
PCRE2 is a re-working of the original PCRE library to provide an entirely new
API.
%package tools
Summary: A library for Perl-compatible regular expressions
Group: Productivity/Text/Utilities
Recommends: %{name}-doc
%description tools
The PCRE2 library is a set of functions that implement regular
expression pattern matching using the same syntax and semantics
as Perl 5.
PCRE2 is a re-working of the original PCRE library to provide an entirely new
API.
%prep
%autosetup -p1
%build
%define _lto_cflags %{nil}
# Available JIT archs see sljit/sljitConfig.h
autoreconf -fiv
export LDFLAGS="-Wl,-z,relro,-z,now"
%configure \
%ifarch %{ix86} x86_64 aarch64 %{arm} ppc ppc64 ppc64le mips sparc s390x
--enable-jit \
%endif
--enable-static \
--with-link-size=2 \
--with-match-limit=10000000 \
--enable-newline-is-lf \
--enable-pcre2-16 \
--enable-pcre2-32 \
--enable-pcre2grep-libz \
--enable-pcre2grep-libbz2 \
--enable-pcre2test-libedit \
--enable-unicode
%if 0%{?do_profiling}
%make_build CFLAGS="%{optflags} %{cflags_profile_generate}"
export LANG=POSIX
# do not run profiling in parallel for reproducible builds (boo#1040589 boo#1102408)
%make_build -j1 CFLAGS="%{optflags} %{cflags_profile_generate}" check
%make_build clean
%make_build CFLAGS="%{optflags} %{cflags_profile_feedback}"
%else
%make_build CFLAGS="%{optflags}"
%endif
%install
%make_install
mkdir -p %{buildroot}/%{_defaultdocdir}
mv %{buildroot}%{_datadir}/doc/pcre2 %{buildroot}/%{_defaultdocdir}/pcre2-doc
#empty dependecy_libs
find %{buildroot} -type f -name "*.la" -delete -print
%check
export LANG=POSIX
%make_build check -j1
%post -n libpcre2-8-0 -p /sbin/ldconfig
%postun -n libpcre2-8-0 -p /sbin/ldconfig
%post -n libpcre2-16-0 -p /sbin/ldconfig
%postun -n libpcre2-16-0 -p /sbin/ldconfig
%post -n libpcre2-32-0 -p /sbin/ldconfig
%postun -n libpcre2-32-0 -p /sbin/ldconfig
%post -n libpcre2-posix3 -p /sbin/ldconfig
%postun -n libpcre2-posix3 -p /sbin/ldconfig
%files -n libpcre2-8-0
%license COPYING LICENCE
%doc AUTHORS ChangeLog NEWS README
%{_libdir}/libpcre2-8.so.*
%files -n libpcre2-16-0
%license LICENCE
%{_libdir}/libpcre2-16.so.*
%files -n libpcre2-32-0
%license LICENCE
%{_libdir}/libpcre2-32.so.*
%files -n libpcre2-posix3
%license LICENCE
%{_libdir}/libpcre2-posix.so.*
%files tools
%license LICENCE
%{_bindir}/pcre2grep
%{_bindir}/pcre2test
%{_mandir}/man1/pcre2grep.1%{?ext_man}
%{_mandir}/man1/pcre2test.1%{?ext_man}
%files doc
%license COPYING LICENCE
%doc AUTHORS ChangeLog NEWS README
%doc doc/html doc/*.txt
%doc %{_defaultdocdir}/pcre2-doc
%files devel
%license LICENCE
%{_bindir}/pcre2-config
%{_includedir}/*
%{_libdir}/*.so
%{_libdir}/pkgconfig/libpcre2-8.pc
%{_libdir}/pkgconfig/libpcre2-16.pc
%{_libdir}/pkgconfig/libpcre2-32.pc
%{_libdir}/pkgconfig/libpcre2-posix.pc
%{_mandir}/man1/pcre2-config.1%{?ext_man}
%{_mandir}/man3/*%{ext_man}
%files devel-static
%{_libdir}/*.a
%changelog