From 91ca403a03230af2c864c4d85048c55e307c8df558968d14d5ff9289bc2f6e98 Mon Sep 17 00:00:00 2001 From: Andreas Stieger Date: Sat, 5 Aug 2017 17:34:46 +0000 Subject: [PATCH] - fix SLE 11 build OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/pcre2?expand=0&rev=19 --- pcre2.changes | 5 +++++ pcre2.spec | 22 +++++++++++++--------- 2 files changed, 18 insertions(+), 9 deletions(-) diff --git a/pcre2.changes b/pcre2.changes index a0ce0cb..dbd124b 100644 --- a/pcre2.changes +++ b/pcre2.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Sat Aug 5 17:34:26 UTC 2017 - astieger@suse.com + +- fix SLE 11 build + ------------------------------------------------------------------- Tue May 2 17:28:30 UTC 2017 - astieger@suse.com diff --git a/pcre2.spec b/pcre2.spec index 0dc0d37..727696c 100644 --- a/pcre2.spec +++ b/pcre2.spec @@ -16,6 +16,7 @@ # +%define with_libedit 0%{?suse_version} > 1110 Name: pcre2 Version: 10.23 Release: 0 @@ -34,10 +35,12 @@ BuildRequires: autoconf BuildRequires: automake BuildRequires: gcc-c++ BuildRequires: libbz2-devel -BuildRequires: libedit-devel BuildRequires: libtool -BuildRequires: pkg-config +BuildRequires: pkgconfig BuildRequires: zlib-devel +%if %{with_libedit} +BuildRequires: libedit-devel +%endif BuildRoot: %{_tmppath}/%{name}-%{version}-build %description @@ -185,7 +188,9 @@ export LDFLAGS="-Wl,-z,relro,-z,now" --enable-pcre2-32 \ --enable-pcre2grep-libz \ --enable-pcre2grep-libbz2 \ +%if %{with_libedit} --enable-pcre2test-libedit \ +%endif --enable-unicode make %{?_smp_mflags} V=1 @@ -201,19 +206,12 @@ export LANG=POSIX make 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-posix1 -p /sbin/ldconfig - %postun -n libpcre2-posix1 -p /sbin/ldconfig %files -n libpcre2-8-0 @@ -223,18 +221,22 @@ make check -j1 %files -n libpcre2-16-0 %defattr(-,root,root) +%doc LICENCE %{_libdir}/libpcre2-16.so.* %files -n libpcre2-32-0 %defattr(-,root,root) +%doc LICENCE %{_libdir}/libpcre2-32.so.* %files -n libpcre2-posix1 %defattr(-,root,root) +%doc LICENCE %{_libdir}/libpcre2-posix.so.* %files tools %defattr(-,root,root) +%doc LICENCE %{_bindir}/pcre2grep %{_bindir}/pcre2test %{_mandir}/man1/pcre2grep.* @@ -242,11 +244,13 @@ make check -j1 %files doc %defattr(-,root,root) +%doc AUTHORS COPYING ChangeLog LICENCE NEWS README %doc doc/html doc/*.txt %doc %{_defaultdocdir}/pcre2-doc %files devel %defattr(-,root,root) +%doc LICENCE %{_bindir}/pcre2-config %{_includedir}/* %{_libdir}/*.so