[1/3] libsemanage: Drop package

Message ID 20171012092810.18910-1-stefan.schantl@ipfire.org
State Accepted
Commit 729716ba8d6d478d02e3ef8a5f0e0da29d7a9d57
Headers
Series [1/3] libsemanage: Drop package |

Commit Message

Stefan Schantl Oct. 12, 2017, 8:28 p.m. UTC
  Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
---
 libsemanage/libsemanage.nm                 | 74 ------------------------------
 libsemanage/patches/libsemanage-rhat.patch | 24 ----------
 libsemanage/semanage.conf                  | 50 --------------------
 3 files changed, 148 deletions(-)
 delete mode 100644 libsemanage/libsemanage.nm
 delete mode 100644 libsemanage/patches/libsemanage-rhat.patch
 delete mode 100644 libsemanage/semanage.conf
  

Comments

Michael Tremer Oct. 12, 2017, 8:50 p.m. UTC | #1
Hi,

merged, but a few packages still depend on this.

What is going to happen to those?

-Michael

On Thu, 2017-10-12 at 11:28 +0200, Stefan Schantl wrote:
> Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
> ---
>  libsemanage/libsemanage.nm                 | 74 ---------------------------
> ---
>  libsemanage/patches/libsemanage-rhat.patch | 24 ----------
>  libsemanage/semanage.conf                  | 50 --------------------
>  3 files changed, 148 deletions(-)
>  delete mode 100644 libsemanage/libsemanage.nm
>  delete mode 100644 libsemanage/patches/libsemanage-rhat.patch
>  delete mode 100644 libsemanage/semanage.conf
> 
> diff --git a/libsemanage/libsemanage.nm b/libsemanage/libsemanage.nm
> deleted file mode 100644
> index 5bac1be..0000000
> --- a/libsemanage/libsemanage.nm
> +++ /dev/null
> @@ -1,74 +0,0 @@
> -#############################################################################
> ##
> -# IPFire.org    - An Open Source Firewall
> Solution                            #
> -# Copyright (C) - IPFire Development Team <info@ipfire.org>                  
>  #
> -#############################################################################
> ##
> -
> -name       = libsemanage
> -version    = 2.1.5
> -release    = 3
> -
> -groups     = System/Libraries
> -url        = http://www.selinuxproject.org
> -license    = LGPLv2+
> -summary    = SELinux binary policy manipulation library.
> -
> -description
> -	libsemanage provides an API for the manipulation of SELinux
> -	binary policies.
> -end
> -
> -sources    = %{thisapp}.tgz
> -
> -build
> -	requires
> -		bison
> -		bzip2-devel
> -		flex
> -		libselinux-devel
> -		libsepol-devel >= 2.1.4
> -		python-devel
> -		swig
> -		ustr-devel
> -	end
> -
> -	build
> -		make clean
> -		make CC=gcc LIBDIR="%{libdir}" CFLAGS="-g %{CFLAGS}" swigify
> -		make CC=gcc LIBDIR="%{libdir}" CFLAGS="-g %{CFLAGS}" all
> -		make CC=gcc LIBDIR="%{libdir}" CFLAGS="-g %{CFLAGS}" pywrap
> -	end
> -
> -	# Install libraries to correct place.
> -	make_install_targets += \
> -		LIBDIR="%{BUILDROOT}%{libdir}" \
> -		SHLIBDIR="%{BUILDROOT}%{libdir}"
> -
> -	install_cmds
> -		make install-pywrap %{make_install_targets}
> DESTDIR=%{BUILDROOT}
> -
> -		# Install our config file
> -		cp -vf %{DIR_SOURCE}/semanage.conf
> %{BUILDROOT}/etc/selinux/semanage.conf
> -	end
> -end
> -
> -packages
> -	package %{name}
> -	end
> -
> -	package %{name}-devel
> -		template DEVEL
> -	end
> -	
> -	package python-libsemanage
> -		summary =  SELinux manage python bindings.
> -		description = SELinux python bindings for libsemanage.
> -
> -		files
> -			%{libdir}/python*
> -		end
> -	end
> -
> -	package %{name}-debuginfo
> -		template DEBUGINFO
> -	end
> -end
> diff --git a/libsemanage/patches/libsemanage-rhat.patch
> b/libsemanage/patches/libsemanage-rhat.patch
> deleted file mode 100644
> index a1f53c5..0000000
> --- a/libsemanage/patches/libsemanage-rhat.patch
> +++ /dev/null
> @@ -1,24 +0,0 @@
> -diff --exclude-from=exclude -N -u -r nsalibsemanage/src/genhomedircon.c
> libsemanage-2.0.44/src/genhomedircon.c
> ---- nsalibsemanage/src/genhomedircon.c	2009-09-17 08:59:43.000000000
> -0400
> -+++ libsemanage-2.0.44/src/genhomedircon.c	2010-02-24
> 14:57:23.000000000 -0500
> -@@ -310,6 +310,10 @@
> - 		}
> - 		if (strcmp(pwbuf->pw_dir, "/") == 0)
> - 			continue;
> -+		if (strcmp(pwbuf->pw_dir, "/root") == 0) {
> -+			continue;
> -+		}
> -+
> - 		if (semanage_str_count(pwbuf->pw_dir, '/') <= 1)
> - 			continue;
> - 		if (!(path = strdup(pwbuf->pw_dir))) {
> -@@ -803,6 +807,9 @@
> - 			 * /root */
> - 			continue;
> - 		}
> -+		if (strcmp(pwent->pw_dir, "/root") == 0) {
> -+			continue;
> -+		}
> - 		if (push_user_entry(&head, name, seuname,
> - 				    prefix, pwent->pw_dir) !=
> STATUS_SUCCESS) {
> - 			*errors = STATUS_ERR;
> diff --git a/libsemanage/semanage.conf b/libsemanage/semanage.conf
> deleted file mode 100644
> index 882b8f0..0000000
> --- a/libsemanage/semanage.conf
> +++ /dev/null
> @@ -1,50 +0,0 @@
> -# Authors: Jason Tang <jtang@tresys.com>
> -#
> -# Copyright (C) 2004-2005 Tresys Technology, LLC
> -#
> -#  This library is free software; you can redistribute it and/or
> -#  modify it under the terms of the GNU Lesser General Public
> -#  License as published by the Free Software Foundation; either
> -#  version 2.1 of the License, or (at your option) any later version.
> -#
> -#  This library is distributed in the hope that it will be useful,
> -#  but WITHOUT ANY WARRANTY; without even the implied warranty of
> -#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
> -#  Lesser General Public License for more details.
> -#
> -#  You should have received a copy of the GNU Lesser General Public
> -#  License along with this library; if not, write to the Free Software
> -#  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
> -#
> -# Specify how libsemanage will interact with a SELinux policy manager.
> -# The four options are:
> -#
> -#  "source"     - libsemanage manipulates a source SELinux policy
> -#  "direct"     - libsemanage will write directly to a module store.
> -#  /foo/bar     - Write by way of a policy management server, whose
> -#                 named socket is at /foo/bar.  The path must begin
> -#                 with a '/'.
> -#  foo.com:4242 - Establish a TCP connection to a remote policy
> -#                 management server at foo.com.  If there is a colon
> -#                 then the remainder is interpreted as a port number;
> -#                 otherwise default to port 4242.
> -module-store = direct
> -
> -# When generating the final linked and expanded policy, by default
> -# semanage will set the policy version to POLICYDB_VERSION_MAX, as
> -# given in <sepol/policydb.h>.  Change this setting if a different
> -# version is necessary.
> -#policy-version = 19
> -
> -# expand-check check neverallow rules when executing all semanage commands.
> -# Large penalty in time if you turn this on.  
> -expand-check=0
> -
> -# usepasswd check tells semanage to scan all pass word records for home
> directories
> -# and setup the labeling correctly.  If this is turned off, SELinux will
> label /home 
> -# correctly only.  You will need to use semanage fcontext command.  
> -# For example, if you had home dirs in /althome directory you would have to
> execute
> -# semanage fcontext -a -e /home /althome
> -usepasswd=False
> -bzip-small=true
> -bzip-blocksize=5
  
Stefan Schantl Oct. 12, 2017, 9:22 p.m. UTC | #2
Hello Michael,

thanks for merging.

Currently only the "mesa" and "xorg-x11-server" packages still use
libselinux-devel and are linked against it.

Both packages will be removed during the next step of cleaning up the
IPFire 3 codebase.

For compatibility reasons, we should keep the selinux libraries for a
while in the stable repository unless the buildservice is up again and
all modified packages have been build, tested and moved to the stable
repository...

Best regards,

-Stefan
> Hi,
> 
> merged, but a few packages still depend on this.
> 
> What is going to happen to those?
> 
> -Michael
> 
> On Thu, 2017-10-12 at 11:28 +0200, Stefan Schantl wrote:
> > Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
> > ---
> >  libsemanage/libsemanage.nm                 | 74 ------------------
> > ---------
> > ---
> >  libsemanage/patches/libsemanage-rhat.patch | 24 ----------
> >  libsemanage/semanage.conf                  | 50 ------------------
> > --
> >  3 files changed, 148 deletions(-)
> >  delete mode 100644 libsemanage/libsemanage.nm
> >  delete mode 100644 libsemanage/patches/libsemanage-rhat.patch
> >  delete mode 100644 libsemanage/semanage.conf
> > 
> > diff --git a/libsemanage/libsemanage.nm
> > b/libsemanage/libsemanage.nm
> > deleted file mode 100644
> > index 5bac1be..0000000
> > --- a/libsemanage/libsemanage.nm
> > +++ /dev/null
> > @@ -1,74 +0,0 @@
> > -##################################################################
> > ###########
> > ##
> > -# IPFire.org    - An Open Source Firewall
> > Solution                            #
> > -# Copyright (C) - IPFire Development Team <info@ipfire.org>       
> >            
> >  #
> > -##################################################################
> > ###########
> > ##
> > -
> > -name       = libsemanage
> > -version    = 2.1.5
> > -release    = 3
> > -
> > -groups     = System/Libraries
> > -url        = http://www.selinuxproject.org
> > -license    = LGPLv2+
> > -summary    = SELinux binary policy manipulation library.
> > -
> > -description
> > -	libsemanage provides an API for the manipulation of
> > SELinux
> > -	binary policies.
> > -end
> > -
> > -sources    = %{thisapp}.tgz
> > -
> > -build
> > -	requires
> > -		bison
> > -		bzip2-devel
> > -		flex
> > -		libselinux-devel
> > -		libsepol-devel >= 2.1.4
> > -		python-devel
> > -		swig
> > -		ustr-devel
> > -	end
> > -
> > -	build
> > -		make clean
> > -		make CC=gcc LIBDIR="%{libdir}" CFLAGS="-g
> > %{CFLAGS}" swigify
> > -		make CC=gcc LIBDIR="%{libdir}" CFLAGS="-g
> > %{CFLAGS}" all
> > -		make CC=gcc LIBDIR="%{libdir}" CFLAGS="-g
> > %{CFLAGS}" pywrap
> > -	end
> > -
> > -	# Install libraries to correct place.
> > -	make_install_targets += \
> > -		LIBDIR="%{BUILDROOT}%{libdir}" \
> > -		SHLIBDIR="%{BUILDROOT}%{libdir}"
> > -
> > -	install_cmds
> > -		make install-pywrap %{make_install_targets}
> > DESTDIR=%{BUILDROOT}
> > -
> > -		# Install our config file
> > -		cp -vf %{DIR_SOURCE}/semanage.conf
> > %{BUILDROOT}/etc/selinux/semanage.conf
> > -	end
> > -end
> > -
> > -packages
> > -	package %{name}
> > -	end
> > -
> > -	package %{name}-devel
> > -		template DEVEL
> > -	end
> > -	
> > -	package python-libsemanage
> > -		summary =  SELinux manage python bindings.
> > -		description = SELinux python bindings for
> > libsemanage.
> > -
> > -		files
> > -			%{libdir}/python*
> > -		end
> > -	end
> > -
> > -	package %{name}-debuginfo
> > -		template DEBUGINFO
> > -	end
> > -end
> > diff --git a/libsemanage/patches/libsemanage-rhat.patch
> > b/libsemanage/patches/libsemanage-rhat.patch
> > deleted file mode 100644
> > index a1f53c5..0000000
> > --- a/libsemanage/patches/libsemanage-rhat.patch
> > +++ /dev/null
> > @@ -1,24 +0,0 @@
> > -diff --exclude-from=exclude -N -u -r
> > nsalibsemanage/src/genhomedircon.c
> > libsemanage-2.0.44/src/genhomedircon.c
> > ---- nsalibsemanage/src/genhomedircon.c	2009-09-17
> > 08:59:43.000000000
> > -0400
> > -+++ libsemanage-2.0.44/src/genhomedircon.c	2010-02-24
> > 14:57:23.000000000 -0500
> > -@@ -310,6 +310,10 @@
> > - 		}
> > - 		if (strcmp(pwbuf->pw_dir, "/") == 0)
> > - 			continue;
> > -+		if (strcmp(pwbuf->pw_dir, "/root") == 0) {
> > -+			continue;
> > -+		}
> > -+
> > - 		if (semanage_str_count(pwbuf->pw_dir, '/') <= 1)
> > - 			continue;
> > - 		if (!(path = strdup(pwbuf->pw_dir))) {
> > -@@ -803,6 +807,9 @@
> > - 			 * /root */
> > - 			continue;
> > - 		}
> > -+		if (strcmp(pwent->pw_dir, "/root") == 0) {
> > -+			continue;
> > -+		}
> > - 		if (push_user_entry(&head, name, seuname,
> > - 				    prefix, pwent->pw_dir) !=
> > STATUS_SUCCESS) {
> > - 			*errors = STATUS_ERR;
> > diff --git a/libsemanage/semanage.conf b/libsemanage/semanage.conf
> > deleted file mode 100644
> > index 882b8f0..0000000
> > --- a/libsemanage/semanage.conf
> > +++ /dev/null
> > @@ -1,50 +0,0 @@
> > -# Authors: Jason Tang <jtang@tresys.com>
> > -#
> > -# Copyright (C) 2004-2005 Tresys Technology, LLC
> > -#
> > -#  This library is free software; you can redistribute it and/or
> > -#  modify it under the terms of the GNU Lesser General Public
> > -#  License as published by the Free Software Foundation; either
> > -#  version 2.1 of the License, or (at your option) any later
> > version.
> > -#
> > -#  This library is distributed in the hope that it will be useful,
> > -#  but WITHOUT ANY WARRANTY; without even the implied warranty of
> > -#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
> > GNU
> > -#  Lesser General Public License for more details.
> > -#
> > -#  You should have received a copy of the GNU Lesser General
> > Public
> > -#  License along with this library; if not, write to the Free
> > Software
> > -#  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
> > MA  02110-1301  USA
> > -#
> > -# Specify how libsemanage will interact with a SELinux policy
> > manager.
> > -# The four options are:
> > -#
> > -#  "source"     - libsemanage manipulates a source SELinux policy
> > -#  "direct"     - libsemanage will write directly to a module
> > store.
> > -#  /foo/bar     - Write by way of a policy management server,
> > whose
> > -#                 named socket is at /foo/bar.  The path must
> > begin
> > -#                 with a '/'.
> > -#  foo.com:4242 - Establish a TCP connection to a remote policy
> > -#                 management server at foo.com.  If there is a
> > colon
> > -#                 then the remainder is interpreted as a port
> > number;
> > -#                 otherwise default to port 4242.
> > -module-store = direct
> > -
> > -# When generating the final linked and expanded policy, by default
> > -# semanage will set the policy version to POLICYDB_VERSION_MAX, as
> > -# given in <sepol/policydb.h>.  Change this setting if a different
> > -# version is necessary.
> > -#policy-version = 19
> > -
> > -# expand-check check neverallow rules when executing all semanage
> > commands.
> > -# Large penalty in time if you turn this on.  
> > -expand-check=0
> > -
> > -# usepasswd check tells semanage to scan all pass word records for
> > home
> > directories
> > -# and setup the labeling correctly.  If this is turned off,
> > SELinux will
> > label /home 
> > -# correctly only.  You will need to use semanage fcontext
> > command.  
> > -# For example, if you had home dirs in /althome directory you
> > would have to
> > execute
> > -# semanage fcontext -a -e /home /althome
> > -usepasswd=False
> > -bzip-small=true
> > -bzip-blocksize=5
  

Patch

diff --git a/libsemanage/libsemanage.nm b/libsemanage/libsemanage.nm
deleted file mode 100644
index 5bac1be..0000000
--- a/libsemanage/libsemanage.nm
+++ /dev/null
@@ -1,74 +0,0 @@ 
-###############################################################################
-# IPFire.org    - An Open Source Firewall Solution                            #
-# Copyright (C) - IPFire Development Team <info@ipfire.org>                   #
-###############################################################################
-
-name       = libsemanage
-version    = 2.1.5
-release    = 3
-
-groups     = System/Libraries
-url        = http://www.selinuxproject.org
-license    = LGPLv2+
-summary    = SELinux binary policy manipulation library.
-
-description
-	libsemanage provides an API for the manipulation of SELinux
-	binary policies.
-end
-
-sources    = %{thisapp}.tgz
-
-build
-	requires
-		bison
-		bzip2-devel
-		flex
-		libselinux-devel
-		libsepol-devel >= 2.1.4
-		python-devel
-		swig
-		ustr-devel
-	end
-
-	build
-		make clean
-		make CC=gcc LIBDIR="%{libdir}" CFLAGS="-g %{CFLAGS}" swigify
-		make CC=gcc LIBDIR="%{libdir}" CFLAGS="-g %{CFLAGS}" all
-		make CC=gcc LIBDIR="%{libdir}" CFLAGS="-g %{CFLAGS}" pywrap
-	end
-
-	# Install libraries to correct place.
-	make_install_targets += \
-		LIBDIR="%{BUILDROOT}%{libdir}" \
-		SHLIBDIR="%{BUILDROOT}%{libdir}"
-
-	install_cmds
-		make install-pywrap %{make_install_targets} DESTDIR=%{BUILDROOT}
-
-		# Install our config file
-		cp -vf %{DIR_SOURCE}/semanage.conf %{BUILDROOT}/etc/selinux/semanage.conf
-	end
-end
-
-packages
-	package %{name}
-	end
-
-	package %{name}-devel
-		template DEVEL
-	end
-	
-	package python-libsemanage
-		summary =  SELinux manage python bindings.
-		description = SELinux python bindings for libsemanage.
-
-		files
-			%{libdir}/python*
-		end
-	end
-
-	package %{name}-debuginfo
-		template DEBUGINFO
-	end
-end
diff --git a/libsemanage/patches/libsemanage-rhat.patch b/libsemanage/patches/libsemanage-rhat.patch
deleted file mode 100644
index a1f53c5..0000000
--- a/libsemanage/patches/libsemanage-rhat.patch
+++ /dev/null
@@ -1,24 +0,0 @@ 
-diff --exclude-from=exclude -N -u -r nsalibsemanage/src/genhomedircon.c libsemanage-2.0.44/src/genhomedircon.c
---- nsalibsemanage/src/genhomedircon.c	2009-09-17 08:59:43.000000000 -0400
-+++ libsemanage-2.0.44/src/genhomedircon.c	2010-02-24 14:57:23.000000000 -0500
-@@ -310,6 +310,10 @@
- 		}
- 		if (strcmp(pwbuf->pw_dir, "/") == 0)
- 			continue;
-+		if (strcmp(pwbuf->pw_dir, "/root") == 0) {
-+			continue;
-+		}
-+
- 		if (semanage_str_count(pwbuf->pw_dir, '/') <= 1)
- 			continue;
- 		if (!(path = strdup(pwbuf->pw_dir))) {
-@@ -803,6 +807,9 @@
- 			 * /root */
- 			continue;
- 		}
-+		if (strcmp(pwent->pw_dir, "/root") == 0) {
-+			continue;
-+		}
- 		if (push_user_entry(&head, name, seuname,
- 				    prefix, pwent->pw_dir) != STATUS_SUCCESS) {
- 			*errors = STATUS_ERR;
diff --git a/libsemanage/semanage.conf b/libsemanage/semanage.conf
deleted file mode 100644
index 882b8f0..0000000
--- a/libsemanage/semanage.conf
+++ /dev/null
@@ -1,50 +0,0 @@ 
-# Authors: Jason Tang <jtang@tresys.com>
-#
-# Copyright (C) 2004-2005 Tresys Technology, LLC
-#
-#  This library is free software; you can redistribute it and/or
-#  modify it under the terms of the GNU Lesser General Public
-#  License as published by the Free Software Foundation; either
-#  version 2.1 of the License, or (at your option) any later version.
-#
-#  This library is distributed in the hope that it will be useful,
-#  but WITHOUT ANY WARRANTY; without even the implied warranty of
-#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-#  Lesser General Public License for more details.
-#
-#  You should have received a copy of the GNU Lesser General Public
-#  License along with this library; if not, write to the Free Software
-#  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
-#
-# Specify how libsemanage will interact with a SELinux policy manager.
-# The four options are:
-#
-#  "source"     - libsemanage manipulates a source SELinux policy
-#  "direct"     - libsemanage will write directly to a module store.
-#  /foo/bar     - Write by way of a policy management server, whose
-#                 named socket is at /foo/bar.  The path must begin
-#                 with a '/'.
-#  foo.com:4242 - Establish a TCP connection to a remote policy
-#                 management server at foo.com.  If there is a colon
-#                 then the remainder is interpreted as a port number;
-#                 otherwise default to port 4242.
-module-store = direct
-
-# When generating the final linked and expanded policy, by default
-# semanage will set the policy version to POLICYDB_VERSION_MAX, as
-# given in <sepol/policydb.h>.  Change this setting if a different
-# version is necessary.
-#policy-version = 19
-
-# expand-check check neverallow rules when executing all semanage commands.
-# Large penalty in time if you turn this on.  
-expand-check=0
-
-# usepasswd check tells semanage to scan all pass word records for home directories
-# and setup the labeling correctly.  If this is turned off, SELinux will label /home 
-# correctly only.  You will need to use semanage fcontext command.  
-# For example, if you had home dirs in /althome directory you would have to execute
-# semanage fcontext -a -e /home /althome
-usepasswd=False
-bzip-small=true
-bzip-blocksize=5