libselinux-2.7-3.fc27

- Add support for pcre2 to pkgconfig definition
- Rebuild with libsepol-2.7-2
This commit is contained in:
Petr Lautrbach 2017-11-24 13:50:39 +01:00
parent 7870b3514f
commit f0051913e5
2 changed files with 66 additions and 4 deletions

View File

@ -1,5 +1,5 @@
diff --git libselinux-2.7/Makefile libselinux-2.7/Makefile
index 1ecab17..1f507fb 100644
index 1ecab17..e63ed8d 100644
--- libselinux-2.7/Makefile
+++ libselinux-2.7/Makefile
@@ -1,4 +1,4 @@
@ -8,6 +8,26 @@ index 1ecab17..1f507fb 100644
PKG_CONFIG ?= pkg-config
DISABLE_SETRANS ?= n
@@ -21,13 +21,14 @@ export DISABLE_SETRANS DISABLE_RPM DISABLE_FLAGS ANDROID_HOST
USE_PCRE2 ?= n
ifeq ($(USE_PCRE2),y)
- PCRE_CFLAGS := -DUSE_PCRE2 -DPCRE2_CODE_UNIT_WIDTH=8 $(shell $(PKG_CONFIG) --cflags libpcre2-8)
- PCRE_LDLIBS := $(shell $(PKG_CONFIG) --libs libpcre2-8)
+ PCRE_MODULE := libpcre2-8
+ PCRE_CFLAGS := -DUSE_PCRE2 -DPCRE2_CODE_UNIT_WIDTH=8
else
- PCRE_CFLAGS := $(shell $(PKG_CONFIG) --cflags libpcre)
- PCRE_LDLIBS := $(shell $(PKG_CONFIG) --libs libpcre)
+ PCRE_MODULE := libpcre
endif
-export PCRE_CFLAGS PCRE_LDLIBS
+PCRE_CFLAGS += $(shell $(PKG_CONFIG) --cflags $(PCRE_MODULE))
+PCRE_LDLIBS := $(shell $(PKG_CONFIG) --libs $(PCRE_MODULE))
+export PCRE_MODULE PCRE_CFLAGS PCRE_LDLIBS
OS := $(shell uname)
export OS
diff --git libselinux-2.7/golang/Makefile libselinux-2.7/golang/Makefile
new file mode 100644
index 0000000..b75677b
@ -488,6 +508,32 @@ index e37aee6..bf23b65 100644
Every confined service on the system has a man page in the following format:
.br
diff --git libselinux-2.7/src/Makefile libselinux-2.7/src/Makefile
index 2408fae..18df75c 100644
--- libselinux-2.7/src/Makefile
+++ libselinux-2.7/src/Makefile
@@ -148,7 +148,7 @@ $(LIBSO): $(LOBJS)
ln -sf $@ $(TARGET)
$(LIBPC): $(LIBPC).in ../VERSION
- sed -e 's/@VERSION@/$(VERSION)/; s:@prefix@:$(PREFIX):; s:@libdir@:$(LIBBASE):; s:@includedir@:$(INCLUDEDIR):' < $< > $@
+ sed -e 's/@VERSION@/$(VERSION)/; s:@prefix@:$(PREFIX):; s:@libdir@:$(LIBBASE):; s:@includedir@:$(INCLUDEDIR):; s:@PCRE_MODULE@:$(PCRE_MODULE):' < $< > $@
selinuxswig_python_exception.i: ../include/selinux/selinux.h
bash -e exception.sh > $@ || (rm -f $@ ; false)
diff --git libselinux-2.7/src/avc.c libselinux-2.7/src/avc.c
index 96b2678..5230efd 100644
--- libselinux-2.7/src/avc.c
+++ libselinux-2.7/src/avc.c
@@ -4,7 +4,7 @@
* Author : Eamon Walsh <ewalsh@epoch.ncsc.mil>
*
* Derived from the kernel AVC implementation by
- * Stephen Smalley <sds@epoch.ncsc.mil> and
+ * Stephen Smalley <sds@tycho.nsa.gov> and
* James Morris <jmorris@redhat.com>.
*/
#include <selinux/avc.h>
diff --git libselinux-2.7/src/avc_sidtab.c libselinux-2.7/src/avc_sidtab.c
index 9669264..c775430 100644
--- libselinux-2.7/src/avc_sidtab.c
@ -647,6 +693,18 @@ index 52707d0..0cbe12d 100644
if (rc < 0 && errno == ENOTSUP) {
char * ccontext = NULL;
int err = errno;
diff --git libselinux-2.7/src/libselinux.pc.in libselinux-2.7/src/libselinux.pc.in
index 2cd04d3..2e90a84 100644
--- libselinux-2.7/src/libselinux.pc.in
+++ libselinux-2.7/src/libselinux.pc.in
@@ -7,6 +7,6 @@ Name: libselinux
Description: SELinux utility library
Version: @VERSION@
URL: http://userspace.selinuxproject.org/
-Requires.private: libsepol libpcre
+Requires.private: libsepol @PCRE_MODULE@
Libs: -L${libdir} -lselinux
Cflags: -I${includedir}
diff --git libselinux-2.7/src/lsetfilecon.c libselinux-2.7/src/lsetfilecon.c
index 1d3b28a..ea6d70b 100644
--- libselinux-2.7/src/lsetfilecon.c

View File

@ -3,13 +3,13 @@
%endif
%define ruby_inc %(pkg-config --cflags ruby)
%define libsepolver 2.7-1
%define libsepolver 2.7-2
%{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
Summary: SELinux library and simple utilities
Name: libselinux
Version: 2.7
Release: 2%{?dist}
Release: 3%{?dist}
License: Public Domain
Group: System Environment/Libraries
# https://github.com/SELinuxProject/selinux/wiki/Releases
@ -20,7 +20,7 @@ Url: https://github.com/SELinuxProject/selinux/wiki
# download https://raw.githubusercontent.com/fedora-selinux/scripts/master/selinux/make-fedora-selinux-patch.sh
# run:
# $ VERSION=2.7 ./make-fedora-selinux-patch.sh libselinux
# HEAD https://github.com/fedora-selinux/selinux/commit/70a12c5e7b56a81223d67ce2469292826b84efe9
# HEAD https://github.com/fedora-selinux/selinux/commit/e5a6540888e254b245d42b7cecf0b895d64ddc43
Patch1: libselinux-fedora.patch
%if 0%{?fedora} > 25
BuildRequires: pkgconf-pkg-config
@ -266,6 +266,10 @@ rm -rf %{buildroot}
%{ruby_vendorarchdir}/selinux.so
%changelog
* Fri Nov 24 2017 Petr Lautrbach <plautrba@redhat.com> - 2.7-3
- Add support for pcre2 to pkgconfig definition
- Rebuild with libsepol-2.7-2
* Fri Sep 01 2017 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 2.7-2
- Rebuild due to missing pkgconfig(libpcre) dependency