From d27dc974041fc94479030d5b36fc86104854d508 Mon Sep 17 00:00:00 2001 From: Daniel J Walsh Date: Fri, 17 Mar 2006 17:20:57 +0000 Subject: [PATCH] - Make some fixes so it will build on RHEL4 - Upgrade to latest from NSA Updated version for release. Altered rpm_execcon fallback logic for permissive mode to also handle case where /selinux/enforce is not available. --- .cvsignore | 2 ++ libselinux-rhat.patch | 47 ++++++++++--------------------------------- libselinux.spec | 20 +++++++++++++----- sources | 2 +- 4 files changed, 29 insertions(+), 42 deletions(-) diff --git a/.cvsignore b/.cvsignore index 76dc52c..30daf12 100644 --- a/.cvsignore +++ b/.cvsignore @@ -75,3 +75,5 @@ libselinux-1.29.4.tgz libselinux-1.29.5.tgz libselinux-1.29.6.tgz libselinux-1.29.7.tgz +libselinux-1.29.8.tgz +libselinux-1.30.tgz diff --git a/libselinux-rhat.patch b/libselinux-rhat.patch index 1e613ed..4577986 100644 --- a/libselinux-rhat.patch +++ b/libselinux-rhat.patch @@ -1,36 +1,11 @@ -diff --exclude-from=exclude -N -u -r nsalibselinux/Makefile libselinux-1.29.5/Makefile ---- nsalibselinux/Makefile 2005-02-09 17:04:51.000000000 -0500 -+++ libselinux-1.29.5/Makefile 2006-01-13 23:54:13.000000000 -0500 -@@ -2,12 +2,18 @@ - $(MAKE) -C src - $(MAKE) -C utils - -+pywrap: -+ $(MAKE) -C src pywrap -+ - install: - $(MAKE) -C include install - $(MAKE) -C src install - $(MAKE) -C utils install - $(MAKE) -C man install - -+install-pywrap: -+ $(MAKE) -C src install-pywrap -+ - relabel: - $(MAKE) -C src relabel - -diff --exclude-from=exclude -N -u -r nsalibselinux/src/Makefile libselinux-1.29.5/src/Makefile ---- nsalibselinux/src/Makefile 2006-01-04 10:37:34.000000000 -0500 -+++ libselinux-1.29.5/src/Makefile 2006-01-13 23:54:50.000000000 -0500 -@@ -26,7 +26,9 @@ - - SWIG = swig -Wall -python -o $(SWIGCOUT) -outdir ./ - --all: $(LIBA) $(LIBSO) $(SWIGSO) -+all: $(LIBA) $(LIBSO) -+ -+pywrap: $(SWIGSO) - - $(LIBA): $(OBJS) - $(AR) rcs $@ $^ +--- libselinux-1.29.7/src/Makefile~ 2006-01-20 10:37:52.000000000 -0500 ++++ libselinux-1.29.7/src/Makefile 2006-03-16 17:22:52.000000000 -0500 +@@ -3,7 +3,7 @@ + LIBDIR ?= $(PREFIX)/lib + SHLIBDIR ?= $(DESTDIR)/lib + INCLUDEDIR ?= $(PREFIX)/include +-PYLIBVER ?= python2.4 ++PYLIBVER ?= $(shell python -c 'import sys;print "python%d.%d" % sys.version_info[0:2]') + PYINC ?= /usr/include/$(PYLIBVER) + PYLIB ?= /usr/lib/$(PYLIBVER) + PYTHONLIBDIR ?= $(LIBDIR)/$(PYLIBVER) diff --git a/libselinux.spec b/libselinux.spec index e2dc968..02dcb6b 100644 --- a/libselinux.spec +++ b/libselinux.spec @@ -1,12 +1,13 @@ -%define libsepolver 1.11.9-1 +%define libsepolver 1.11.20-1 %define libsetransver 0.1.18-1 Summary: SELinux library and simple utilities Name: libselinux -Version: 1.29.7 -Release: 1.2 +Version: 1.30 +Release: 1 License: Public domain (uncopyrighted) Group: System Environment/Libraries Source: http://www.nsa.gov/selinux/archives/%{name}-%{version}.tgz +Patch: libselinux-rhat.patch BuildRequires: libsepol-devel >= %{libsepolver} Requires: libsepol >= %{libsepolver} @@ -33,6 +34,7 @@ decisions. Required for any applications that use the SELinux API. Summary: python bindings for libselinux Group: Development/Libraries Requires: libselinux = %{version}-%{release} +BuildRequires: python-devel %description python The libselinux-python package contains the python bindings for developing SELinux @@ -49,6 +51,7 @@ needed for developing SELinux applications. %prep %setup -q +%patch -p1 -b .rhat %build make clean @@ -104,10 +107,17 @@ exit 0 %files python %defattr(-,root,root,0755) -%{_libdir}/python2.4/site-packages/_selinux.so -%{_libdir}/python2.4/site-packages/selinux.py* +%{_libdir}/python*/site-packages/_selinux.so +%{_libdir}/python*/site-packages/selinux.py* %changelog +* Fri Mar 10 2006 Dan Walsh 1.30-1 +- Make some fixes so it will build on RHEL4 +- Upgrade to latest from NSA + * Updated version for release. + * Altered rpm_execcon fallback logic for permissive mode to also + handle case where /selinux/enforce is not available. + * Fri Feb 10 2006 Jesse Keating - 1.29.7-1.2 - bump again for double-long bug on ppc(64) diff --git a/sources b/sources index 85f89a0..287d8d6 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -880560e5229cbf090b0f4608a5c3b95e libselinux-1.29.7.tgz +b0834c79eac17c87c690542b0874cc53 libselinux-1.30.tgz