[packages/libselinux] - added no-pip patch (use just setuptools to install); release 2

qboosh qboosh at pld-linux.org
Wed Jul 17 21:44:17 CEST 2024


commit 9c201c7d3544eb7ca3a57dcbca6079cd341a3651
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Wed Jul 17 21:37:43 2024 +0200

    - added no-pip patch (use just setuptools to install); release 2

 libselinux-no-pip.patch | 11 +++++++++++
 libselinux.spec         |  6 ++++--
 2 files changed, 15 insertions(+), 2 deletions(-)
---
diff --git a/libselinux.spec b/libselinux.spec
index a972f9a..c051011 100644
--- a/libselinux.spec
+++ b/libselinux.spec
@@ -8,12 +8,13 @@ Summary:	SELinux library and simple utilities
 Summary(pl.UTF-8):	Biblioteka SELinux i proste narzędzia
 Name:		libselinux
 Version:	3.7
-Release:	1
+Release:	2
 License:	Public Domain
 Group:		Libraries
 #Source0Download: https://github.com/SELinuxProject/selinux/wiki/Releases
 Source0:	https://github.com/SELinuxProject/selinux/releases/download/%{version}/%{name}-%{version}.tar.gz
 # Source0-md5:	ac0c812124d83faa7721928d0c01adc0
+Patch0:		%{name}-no-pip.patch
 URL:		https://github.com/SELinuxProject/selinux/wiki
 %ifarch ppc ppc64 sparc sparcv9 sparc64
 BuildRequires:	gcc >= 5:3.4
@@ -26,7 +27,7 @@ BuildRequires:	libsepol-devel >= %{sepol_ver}
 BuildRequires:	pcre2-8-devel
 BuildRequires:	pkgconfig
 %{?with_python:BuildRequires:	python3-devel >= 1:3.2}
-%{?with_python:BuildRequires:	python3-pip}
+%{?with_python:BuildRequires:	python3-setuptools}
 %{?with_python:BuildRequires:	rpm-pythonprov}
 BuildRequires:	rpmbuild(macros) >= 1.714
 %{?with_ruby:BuildRequires:	ruby-devel >= 1.9}
@@ -139,6 +140,7 @@ Wiązania języka Ruby do biblioteki SELinux.
 
 %prep
 %setup -q
+%patch0 -p1
 
 %build
 %{__make} -j1 all %{?with_python:pywrap} %{?with_ruby:rubywrap} \
diff --git a/libselinux-no-pip.patch b/libselinux-no-pip.patch
new file mode 100644
index 0000000..e66aa75
--- /dev/null
+++ b/libselinux-no-pip.patch
@@ -0,0 +1,11 @@
+--- libselinux-3.7/src/Makefile.orig	2024-06-26 17:30:41.000000000 +0200
++++ libselinux-3.7/src/Makefile	2024-07-17 21:32:22.645249014 +0200
+@@ -191,7 +191,7 @@ install: all
+ 	ln -sf --relative $(DESTDIR)$(SHLIBDIR)/$(LIBSO) $(DESTDIR)$(LIBDIR)/$(TARGET)
+ 
+ install-pywrap: pywrap
+-	CFLAGS="$(CPPFLAGS) $(CFLAGS) $(SWIG_CFLAGS)" $(PYTHON) -m pip install --prefix=$(PREFIX) `test -n "$(DESTDIR)" && echo --root $(DESTDIR) --ignore-installed --no-deps` $(PYTHON_SETUP_ARGS) .
++	CFLAGS="$(CPPFLAGS) $(CFLAGS) $(SWIG_CFLAGS)" $(PYTHON) setup.py install --skip-build --prefix=$(PREFIX) `test -n "$(DESTDIR)" && echo --root $(DESTDIR)` $(PYTHON_SETUP_ARGS)
+ 	install -m 644 $(SWIGPYOUT) $(DESTDIR)$(PYTHONLIBDIR)/selinux/__init__.py
+ 	ln -sf --relative $(DESTDIR)$(PYTHONLIBDIR)/selinux/_selinux$(PYCEXT) $(DESTDIR)$(PYTHONLIBDIR)/_selinux$(PYCEXT)
+ 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/libselinux.git/commitdiff/9c201c7d3544eb7ca3a57dcbca6079cd341a3651



More information about the pld-cvs-commit mailing list