selinux: Remove obsolete version

Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
This commit is contained in:
Mark Hatle 2012-05-18 17:25:02 -05:00
parent 356aac4dfd
commit 3aa492ffe7
9 changed files with 0 additions and 691 deletions

View File

@ -1,18 +0,0 @@
Fix hard coded directories in the test makefile
Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
diff -ur checkpolicy-2.1.0.orig/test/Makefile checkpolicy-2.1.0/test/Makefile
--- checkpolicy-2.1.0.orig/test/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ checkpolicy-2.1.0/test/Makefile 2012-01-16 18:21:32.140776138 -0600
@@ -2,8 +2,8 @@
# Makefile for building the dispol program
#
PREFIX ?= $(DESTDIR)/usr
-BINDIR=$(PREFIX)/bin
-LIBDIR=$(PREFIX)/lib
+BINDIR ?= $(PREFIX)/bin
+LIBDIR ?= $(PREFIX)/lib
INCLUDEDIR ?= $(PREFIX)/include
CFLAGS ?= -g -Wall -O2 -pipe

View File

@ -1,17 +0,0 @@
SUMMARY = "SELinux policy compiler"
DESCRIPTION = "SELinux policy compiler"
SECTION = "base"
PR = "r1"
LICENSE = "GPLv2+"
LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
include selinux.inc
SRC_URI[md5sum] = "c447f1d6cc6897f058d7e44e961fe3fd"
SRC_URI[sha256sum] = "9eaa15d1fbd23faebda9b1aef902d986edd3a9f9e75791e081b322875ab4f1aa"
SRC_URI += "file://test_makefile.patch"
DEPENDS += "libsepol flex-native flex"
EXTRA_OEMAKE += "INCLUDEDIR='${STAGING_INCDIR}' LIBDIR='${STAGING_LIBDIR}'"

View File

@ -1,22 +0,0 @@
SUMMARY = "SELinux library and simple utilities"
DESCRIPTION = "libselinux provides an API for SELinux applications to get and set \
process and file security contexts and to obtain security policy \
decisions. Required for any applications that use the SELinux API."
SECTION = "base"
PR = "r1"
LICENSE = "NSA-Public_Domain"
LIC_FILES_CHKSUM = "file://LICENSE;md5=84b4d2c6ef954a2d4081e775a270d0d0"
include selinux.inc
inherit lib_package
SRC_URI[md5sum] = "df32d1650d2ae48cb88c1589c41a50c4"
SRC_URI[sha256sum] = "fbc4911c1103b00b0530ed21d1004ffa8c661342e1101ccf4c73a573f89f9caf"
DEPENDS += "libsepol python"
EXTRA_OEMAKE += "INCLUDEDIR='${STAGING_INCDIR}' LIBDIR='${STAGING_LIBDIR}' PYLIBVER='python${PYTHON_BASEVERSION}' PYINC='${STAGING_INCDIR}/$(PYLIBVER)' PYLIB='${STAGING_LIBDIR}/$(PYLIBVER)' PYTHONLIBDIR='$(PYLIB)'"
do_compile() {
oe_runmake all pywrap
}

View File

@ -1,36 +0,0 @@
SUMMARY = "SELinux binary policy manipulation library"
DESCRIPTION = "libsemanage provides an API for the manipulation of SELinux binary policies. \
It is used by checkpolicy (the policy compiler) and similar tools, as well \
as by programs like load_policy that need to perform specific transformations \
on binary policies such as customizing policy boolean settings."
SECTION = "base"
PR = "r1"
LICENSE = "LGPLv2.1+"
LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343"
include selinux.inc
inherit lib_package
SRC_URI[md5sum] = "d97b0700138dfcc0a9db55a26adffc70"
SRC_URI[sha256sum] = "004c05e32326b1658a85743a950b322d509032dc7c7f652989d7a20ec3652d0f"
DEPENDS += "libsepol libselinux ustr bzip2"
EXTRA_OEMAKE += "INCLUDEDIR='${STAGING_INCDIR}' LIBDIR='${STAGING_LIBDIR}' PYLIBVER='python${PYTHON_BASEVERSION}' PYINC='${STAGING_INCDIR}/$(PYLIBVER)' PYLIB='${STAGING_LIBDIR}/$(PYLIBVER)' PYTHONLIBDIR='$(PYLIB)'"
do_compile() {
oe_runmake all pywrap
}
do_install_append() {
rm ${D}${libdir}/libsemanage.so
ln -s libsemanage.so.1 ${D}${base_libdir}/libsemanage.so
count=0 ; while [ -n "$libdir" -a "$libdir" != "." -a "$libdir" != "/" ]; do count=$(expr $count + 1); libdir=`dirname $libdir` ; done
relpath=""
newcount=0 ; while [ $newcount -lt $count ]; do if [ $newcount -ne 0 ]; then relpath+="/" ; fi ; relpath+=".." ; newcount=$(expr $newcount + 1) ; done
ln -sf $relpath/${base_libdir}/libsemanage.so.1 ${D}${libdir}/libsemanage.so
}

View File

@ -1,17 +0,0 @@
SUMMARY = "SELinux binary policy manipulation library"
DESCRIPTION = "libsepol provides an API for the manipulation of SELinux binary policies. \
It is used by checkpolicy (the policy compiler) and similar tools, as well \
as by programs like load_policy that need to perform specific transformations \
on binary policies such as customizing policy boolean settings."
SECTION = "base"
PR = "r1"
LICENSE = "LGPLv2+"
LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343"
include selinux.inc
inherit lib_package
SRC_URI[md5sum] = "66677a14e3618753c69a05bc65efae75"
SRC_URI[sha256sum] = "67fda7fc0944410fb021e6dc565d88714a7ccd3be276149ce518ab6086f129fe"

View File

@ -1,505 +0,0 @@
Fix cross compilation issues in the Makefiles
Update the makefiles to allow us to specify the appropriate paths
and cross compilation options.
Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
diff -ur policycoreutils-2.1.0.orig/audit2allow/Makefile policycoreutils-2.1.0/audit2allow/Makefile
--- policycoreutils-2.1.0.orig/audit2allow/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/audit2allow/Makefile 2012-01-17 13:24:12.998786954 -0600
@@ -1,5 +1,5 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
BINDIR ?= $(PREFIX)/bin
LIBDIR ?= $(PREFIX)/lib
MANDIR ?= $(PREFIX)/share/man
diff -ur policycoreutils-2.1.0.orig/audit2why/Makefile policycoreutils-2.1.0/audit2why/Makefile
--- policycoreutils-2.1.0.orig/audit2why/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/audit2why/Makefile 2012-01-17 13:24:12.998786954 -0600
@@ -1,5 +1,5 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
BINDIR ?= $(PREFIX)/bin
MANDIR ?= $(PREFIX)/share/man
diff -ur policycoreutils-2.1.0.orig/load_policy/Makefile policycoreutils-2.1.0/load_policy/Makefile
--- policycoreutils-2.1.0.orig/load_policy/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/load_policy/Makefile 2012-01-17 13:31:54.708834556 -0600
@@ -1,25 +1,27 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
-SBINDIR ?= $(DESTDIR)/sbin
-USRSBINDIR ?= $(PREFIX)/sbin
+PREFIX ?= $(DESTDIR)/usr
+BASE_SBINDIR ?= $(DESTDIR)/sbin
+SBINDIR ?= $(PREFIX)/sbin
MANDIR ?= $(PREFIX)/share/man
LOCALEDIR ?= /usr/share/locale
+LIBDIR ?= $(PREFIX)/lib
+INCLUDEDIR ?= $(PREFIX)/include
CFLAGS ?= -Werror -Wall -W
-override CFLAGS += $(LDFLAGS) -I$(PREFIX)/include -DUSE_NLS -DLOCALEDIR="\"$(LOCALEDIR)\"" -DPACKAGE="\"policycoreutils\""
-LDLIBS += -lsepol -lselinux -L$(PREFIX)/lib
+override CFLAGS += $(LDFLAGS) -I$(INCLUDEDIR) -DUSE_NLS -DLOCALEDIR="\"$(LOCALEDIR)\"" -DPACKAGE="\"policycoreutils\""
+LDLIBS += -lsepol -lselinux -L$(LIBDIR)
TARGETS=$(patsubst %.c,%,$(wildcard *.c))
all: $(TARGETS)
install: all
- -mkdir -p $(SBINDIR)
- install -m 755 $(TARGETS) $(SBINDIR)
+ -mkdir -p $(BASE_SBINDIR)
+ install -m 755 $(TARGETS) $(BASE_SBINDIR)
test -d $(MANDIR)/man8 || install -m 755 -d $(MANDIR)/man8
install -m 644 load_policy.8 $(MANDIR)/man8/
- -mkdir -p $(USRSBINDIR)
- ln -sf /sbin/load_policy $(USRSBINDIR)/load_policy
+ -mkdir -p $(SBINDIR)
+ ln -sf /sbin/load_policy $(SBINDIR)/load_policy
clean:
-rm -f $(TARGETS) *.o
@@ -28,4 +30,4 @@
../../scripts/Lindent $(wildcard *.[ch])
relabel:
- /sbin/restorecon $(SBINDIR)/load_policy
+ /sbin/restorecon $(BASE_SBINDIR)/load_policy
diff -ur policycoreutils-2.1.0.orig/Makefile policycoreutils-2.1.0/Makefile
--- policycoreutils-2.1.0.orig/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/Makefile 2012-01-17 13:24:12.999792401 -0600
@@ -1,8 +1,8 @@
SUBDIRS = setfiles semanage load_policy newrole run_init sandbox secon audit2allow audit2why scripts sestatus semodule_package semodule semodule_link semodule_expand semodule_deps setsebool po
-INOTIFYH = $(shell ls /usr/include/sys/inotify.h 2>/dev/null)
+INOTIFYH ?= $(shell ls /usr/include/sys/inotify.h 2>/dev/null)
-ifeq (${INOTIFYH}, /usr/include/sys/inotify.h)
+ifneq ($(INOTIFYH),)
SUBDIRS += restorecond
endif
diff -ur policycoreutils-2.1.0.orig/mcstrans/src/Makefile policycoreutils-2.1.0/mcstrans/src/Makefile
--- policycoreutils-2.1.0.orig/mcstrans/src/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/mcstrans/src/Makefile 2012-01-17 13:24:13.000791906 -0600
@@ -1,21 +1,7 @@
-ARCH = $(shell uname -i)
-ifeq "$(ARCH)" "x86_64"
- # In case of 64 bit system, use these lines
- LIBDIR=/usr/lib64
-else
-ifeq "$(ARCH)" "i686"
- # In case of 32 bit system, use these lines
- LIBDIR=/usr/lib
-else
-ifeq "$(ARCH)" "i386"
- # In case of 32 bit system, use these lines
- LIBDIR=/usr/lib
-endif
-endif
-endif
# Installation directories.
PREFIX ?= $(DESTDIR)/usr
SBINDIR ?= $(DESTDIR)/sbin
+LIBDIR ?= $(PREFIX)/lib
INITDIR ?= $(DESTDIR)/etc/rc.d/init.d
PROG_SRC=mcstrans.c mcscolor.c mcstransd.c mls_level.c
diff -ur policycoreutils-2.1.0.orig/mcstrans/utils/Makefile policycoreutils-2.1.0/mcstrans/utils/Makefile
--- policycoreutils-2.1.0.orig/mcstrans/utils/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/mcstrans/utils/Makefile 2012-01-17 13:24:13.000791906 -0600
@@ -1,23 +1,7 @@
# Installation directories.
PREFIX ?= $(DESTDIR)/usr
BINDIR ?= $(PREFIX)/sbin
-
-ARCH = $(shell uname -i)
-ifeq "$(ARCH)" "x86_64"
- # In case of 64 bit system, use these lines
- LIBDIR=/usr/lib64
-else
-ifeq "$(ARCH)" "i686"
- # In case of 32 bit system, use these lines
- LIBDIR=/usr/lib
-else
-ifeq "$(ARCH)" "i386"
- # In case of 32 bit system, use these lines
- LIBDIR=/usr/lib
-endif
-endif
-endif
-
+LIBDIR ?= $(PREFIX)/lib
CFLAGS ?= -Wall
override CFLAGS += -I../src -D_GNU_SOURCE
diff -ur policycoreutils-2.1.0.orig/newrole/Makefile policycoreutils-2.1.0/newrole/Makefile
--- policycoreutils-2.1.0.orig/newrole/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/newrole/Makefile 2012-01-17 13:35:02.821834567 -0600
@@ -1,11 +1,13 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
BINDIR ?= $(PREFIX)/bin
MANDIR ?= $(PREFIX)/share/man
ETCDIR ?= $(DESTDIR)/etc
-LOCALEDIR = /usr/share/locale
-PAMH = $(shell ls /usr/include/security/pam_appl.h 2>/dev/null)
-AUDITH = $(shell ls /usr/include/libaudit.h 2>/dev/null)
+LOCALEDIR ?= /usr/share/locale
+LIBDIR ?= $(PREFIX)/lib
+INCLUDEDIR ?= $(PREFIX)/include
+PAMH ?= $(shell ls $(INCLUDEDIR)/security/pam_appl.h 2>/dev/null)
+AUDITH ?= $(shell ls $(INCLUDEDIR)/libaudit.h 2>/dev/null)
# Enable capabilities to permit newrole to generate audit records.
# This will make newrole a setuid root program.
# The capabilities used are: CAP_AUDIT_WRITE.
@@ -22,9 +24,9 @@
CFLAGS ?= -Werror -Wall -W
EXTRA_OBJS =
-override CFLAGS += -DVERSION=\"$(VERSION)\" $(LDFLAGS) -I$(PREFIX)/include -DUSE_NLS -DLOCALEDIR="\"$(LOCALEDIR)\"" -DPACKAGE="\"policycoreutils\""
-LDLIBS += -lselinux -L$(PREFIX)/lib
-ifeq (${PAMH}, /usr/include/security/pam_appl.h)
+override CFLAGS += -DVERSION=\"$(VERSION)\" $(LDFLAGS) -I$(INCLUDE_DIR) -DUSE_NLS -DLOCALEDIR="\"$(LOCALEDIR)\"" -DPACKAGE="\"policycoreutils\""
+LDLIBS += -lselinux -L$(LIBDIR)
+ifneq ($(PAMH),)
override CFLAGS += -DUSE_PAM
EXTRA_OBJS += hashtab.o
LDLIBS += -lpam -lpam_misc
@@ -32,23 +34,23 @@
override CFLAGS += -D_XOPEN_SOURCE=500
LDLIBS += -lcrypt
endif
-ifeq (${AUDITH}, /usr/include/libaudit.h)
+ifneq ($(AUDITH),)
override CFLAGS += -DUSE_AUDIT
LDLIBS += -laudit
endif
-ifeq (${LSPP_PRIV},y)
+ifeq ($(LSPP_PRIV),y)
override AUDIT_LOG_PRIV=y
override NAMESPACE_PRIV=y
endif
-ifeq (${AUDIT_LOG_PRIV},y)
+ifeq ($(AUDIT_LOG_PRIV),y)
override CFLAGS += -DAUDIT_LOG_PRIV
IS_SUID=y
endif
-ifeq (${NAMESPACE_PRIV},y)
+ifeq ($(NAMESPACE_PRIV),y)
override CFLAGS += -DNAMESPACE_PRIV
IS_SUID=y
endif
-ifeq (${IS_SUID},y)
+ifeq ($(IS_SUID),y)
MODE := 4555
LDLIBS += -lcap-ng
else
@@ -66,9 +68,9 @@
test -d $(MANDIR)/man1 || install -m 755 -d $(MANDIR)/man1
install -m $(MODE) newrole $(BINDIR)
install -m 644 newrole.1 $(MANDIR)/man1/
-ifeq (${PAMH}, /usr/include/security/pam_appl.h)
+ifneq ($(PAMH),)
test -d $(ETCDIR)/pam.d || install -m 755 -d $(ETCDIR)/pam.d
-ifeq (${LSPP_PRIV},y)
+ifeq ($(LSPP_PRIV),y)
install -m 644 newrole-lspp.pamd $(ETCDIR)/pam.d/newrole
else
install -m 644 newrole.pamd $(ETCDIR)/pam.d/newrole
diff -ur policycoreutils-2.1.0.orig/po/Makefile policycoreutils-2.1.0/po/Makefile
--- policycoreutils-2.1.0.orig/po/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/po/Makefile 2012-01-17 13:24:13.002788918 -0600
@@ -7,7 +7,7 @@
# What is this package?
NLSPACKAGE = policycoreutils
POTFILE = $(NLSPACKAGE).pot
-INSTALL = /usr/bin/install -c
+INSTALL = /usr/bin/install -c -p
INSTALL_DATA = $(INSTALL) -m 644
INSTALL_DIR = /usr/bin/install -d
diff -ur policycoreutils-2.1.0.orig/restorecond/Makefile policycoreutils-2.1.0/restorecond/Makefile
--- policycoreutils-2.1.0.orig/restorecond/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/restorecond/Makefile 2012-01-17 13:32:29.759836181 -0600
@@ -1,13 +1,15 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
SBINDIR ?= $(PREFIX)/sbin
-MANDIR = $(PREFIX)/share/man
-INITDIR = $(DESTDIR)/etc/rc.d/init.d
-SELINUXDIR = $(DESTDIR)/etc/selinux
+MANDIR ?= $(PREFIX)/share/man
+INITDIR ?= $(DESTDIR)/etc/rc.d/init.d
+LIBDIR ?= $(PREFIX)/lib
+INCLUDEDIR ?= $(PREFIX)/include
+SELINUXDIR ?= $(DESTDIR)/etc/selinux
CFLAGS ?= -g -Werror -Wall -W
-override CFLAGS += -I$(PREFIX)/include -D_FILE_OFFSET_BITS=64
-LDLIBS += -lselinux -L$(PREFIX)/lib
+override CFLAGS += -I$(INCLUDEDIR) -D_FILE_OFFSET_BITS=64
+LDLIBS += -lselinux -L$(LIBDIR)
all: restorecond
diff -ur policycoreutils-2.1.0.orig/run_init/Makefile policycoreutils-2.1.0/run_init/Makefile
--- policycoreutils-2.1.0.orig/run_init/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/run_init/Makefile 2012-01-17 13:35:26.647834661 -0600
@@ -1,24 +1,26 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
SBINDIR ?= $(PREFIX)/sbin
MANDIR ?= $(PREFIX)/share/man
ETCDIR ?= $(DESTDIR)/etc
LOCALEDIR ?= /usr/share/locale
-PAMH = $(shell ls /usr/include/security/pam_appl.h 2>/dev/null)
-AUDITH = $(shell ls /usr/include/libaudit.h 2>/dev/null)
+LIBDIR ?= $(PREFIX)/lib
+INCLUDEDIR ?= $(PREFIX)/include
+PAMH ?= $(shell ls $(INCLUDEDIR)/security/pam_appl.h 2>/dev/null)
+AUDITH ?= $(shell ls $(INCLUDEDIR)/libaudit.h 2>/dev/null)
CFLAGS ?= -Werror -Wall -W
-override CFLAGS += -I$(PREFIX)/include -DUSE_NLS -DLOCALEDIR="\"$(LOCALEDIR)\"" -DPACKAGE="\"policycoreutils\""
-LDLIBS += -lselinux -L$(PREFIX)/lib
-ifeq (${PAMH}, /usr/include/security/pam_appl.h)
+override CFLAGS += -I$(INCLUDEDIR) -DUSE_NLS -DLOCALEDIR="\"$(LOCALEDIR)\"" -DPACKAGE="\"policycoreutils\""
+LDLIBS += -lselinux -L$(LIBDIR)
+ifneq ($(PAMH),)
override CFLAGS += -DUSE_PAM
LDLIBS += -lpam -lpam_misc
else
override CFLAGS += -D_XOPEN_SOURCE=500
LDLIBS += -lcrypt
endif
-ifeq (${AUDITH}, /usr/include/libaudit.h)
+ifneq ($(AUDITH),)
override CFLAGS += -DUSE_AUDIT
LDLIBS += -laudit
endif
@@ -38,7 +40,7 @@
install -m 755 open_init_pty $(SBINDIR)
install -m 644 run_init.8 $(MANDIR)/man8/
install -m 644 open_init_pty.8 $(MANDIR)/man8/
-ifeq (${PAMH}, /usr/include/security/pam_appl.h)
+ifneq ($(PAMH),)
install -m 644 run_init.pamd $(ETCDIR)/pam.d/run_init
endif
diff -ur policycoreutils-2.1.0.orig/sandbox/Makefile policycoreutils-2.1.0/sandbox/Makefile
--- policycoreutils-2.1.0.orig/sandbox/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/sandbox/Makefile 2012-01-17 13:26:41.147959182 -0600
@@ -1,13 +1,14 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
-INITDIR ?= ${DESTDIR}/etc/rc.d/init.d/
-SYSCONFDIR ?= ${DESTDIR}/etc/sysconfig
+PREFIX ?= $(DESTDIR)/usr
+INITDIR ?= $(DESTDIR)/etc/rc.d/init.d/
+SYSCONFDIR ?= $(DESTDIR)/etc/sysconfig
BINDIR ?= $(PREFIX)/bin
SBINDIR ?= $(PREFIX)/sbin
MANDIR ?= $(PREFIX)/share/man
LOCALEDIR ?= /usr/share/locale
SHAREDIR ?= $(PREFIX)/share/sandbox
-override CFLAGS += $(LDFLAGS) -I$(PREFIX)/include -DPACKAGE="\"policycoreutils\""
+INCLUDEDIR ?= $(PREFIX)/include
+override CFLAGS += $(LDFLAGS) -I$(INCLUDEDIR) -DPACKAGE="\"policycoreutils\""
LDLIBS += -lselinux -lcap-ng
all: sandbox seunshare sandboxX.sh
diff -ur policycoreutils-2.1.0.orig/scripts/Makefile policycoreutils-2.1.0/scripts/Makefile
--- policycoreutils-2.1.0.orig/scripts/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/scripts/Makefile 2012-01-17 13:24:13.004789319 -0600
@@ -1,5 +1,5 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
BINDIR ?= $(PREFIX)/bin
SBINDIR ?= $(PREFIX)/sbin
MANDIR ?= $(PREFIX)/share/man
diff -ur policycoreutils-2.1.0.orig/secon/Makefile policycoreutils-2.1.0/secon/Makefile
--- policycoreutils-2.1.0.orig/secon/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/secon/Makefile 2012-01-17 13:24:13.004789319 -0600
@@ -1,9 +1,9 @@
# secon tool - command-line context
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
INCLUDEDIR ?= $(PREFIX)/include
BINDIR ?= $(PREFIX)/bin
MANDIR ?= $(PREFIX)/share/man
-LIBDIR ?= ${PREFIX}/lib
+LIBDIR ?= $(PREFIX)/lib
WARNS=-Werror -W -Wall -Wundef -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-align -Wwrite-strings -Waggregate-return -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Wno-format-zero-length -Wformat-nonliteral -Wformat-security -Wfloat-equal
VERSION = $(shell cat ../VERSION)
diff -ur policycoreutils-2.1.0.orig/semanage/Makefile policycoreutils-2.1.0/semanage/Makefile
--- policycoreutils-2.1.0.orig/semanage/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/semanage/Makefile 2012-01-17 13:24:13.005752372 -0600
@@ -1,5 +1,5 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
LIBDIR ?= $(PREFIX)/lib
SBINDIR ?= $(PREFIX)/sbin
MANDIR = $(PREFIX)/share/man
diff -ur policycoreutils-2.1.0.orig/semodule/Makefile policycoreutils-2.1.0/semodule/Makefile
--- policycoreutils-2.1.0.orig/semodule/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/semodule/Makefile 2012-01-17 13:24:13.005752372 -0600
@@ -3,7 +3,7 @@
INCLUDEDIR ?= $(PREFIX)/include
SBINDIR ?= $(PREFIX)/sbin
MANDIR = $(PREFIX)/share/man
-LIBDIR ?= ${PREFIX}/lib
+LIBDIR ?= $(PREFIX)/lib
CFLAGS ?= -Werror -Wall -W
override CFLAGS += -I$(INCLUDEDIR)
diff -ur policycoreutils-2.1.0.orig/semodule_deps/Makefile policycoreutils-2.1.0/semodule_deps/Makefile
--- policycoreutils-2.1.0.orig/semodule_deps/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/semodule_deps/Makefile 2012-01-17 13:24:13.006808131 -0600
@@ -1,8 +1,8 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
INCLUDEDIR ?= $(PREFIX)/include
BINDIR ?= $(PREFIX)/bin
-LIBDIR ?= ${PREFIX}/lib
+LIBDIR ?= $(PREFIX)/lib
MANDIR ?= $(PREFIX)/share/man
CFLAGS ?= -Werror -Wall -W
diff -ur policycoreutils-2.1.0.orig/semodule_expand/Makefile policycoreutils-2.1.0/semodule_expand/Makefile
--- policycoreutils-2.1.0.orig/semodule_expand/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/semodule_expand/Makefile 2012-01-17 13:24:13.006808131 -0600
@@ -1,8 +1,8 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
INCLUDEDIR ?= $(PREFIX)/include
BINDIR ?= $(PREFIX)/bin
-LIBDIR ?= ${PREFIX}/lib
+LIBDIR ?= $(PREFIX)/lib
MANDIR ?= $(PREFIX)/share/man
CFLAGS ?= -Werror -Wall -W
diff -ur policycoreutils-2.1.0.orig/semodule_link/Makefile policycoreutils-2.1.0/semodule_link/Makefile
--- policycoreutils-2.1.0.orig/semodule_link/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/semodule_link/Makefile 2012-01-17 13:24:13.008837145 -0600
@@ -1,9 +1,9 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
INCLUDEDIR ?= $(PREFIX)/include
BINDIR ?= $(PREFIX)/bin
MANDIR ?= $(PREFIX)/share/man
-LIBDIR ?= ${PREFIX}/lib
+LIBDIR ?= $(PREFIX)/lib
CFLAGS ?= -Werror -Wall -W
override CFLAGS += -I$(INCLUDEDIR)
diff -ur policycoreutils-2.1.0.orig/semodule_package/Makefile policycoreutils-2.1.0/semodule_package/Makefile
--- policycoreutils-2.1.0.orig/semodule_package/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/semodule_package/Makefile 2012-01-17 13:24:13.009746277 -0600
@@ -1,8 +1,8 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
INCLUDEDIR ?= $(PREFIX)/include
BINDIR ?= $(PREFIX)/bin
-LIBDIR ?= ${PREFIX}/lib
+LIBDIR ?= $(PREFIX)/lib
MANDIR ?= $(PREFIX)/share/man
CFLAGS ?= -Werror -Wall -W
diff -ur policycoreutils-2.1.0.orig/sestatus/Makefile policycoreutils-2.1.0/sestatus/Makefile
--- policycoreutils-2.1.0.orig/sestatus/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/sestatus/Makefile 2012-01-17 13:25:58.418959420 -0600
@@ -1,12 +1,13 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
+PREFIX ?= $(DESTDIR)/usr
SBINDIR ?= $(PREFIX)/sbin
-MANDIR = $(PREFIX)/share/man
+MANDIR ?= $(PREFIX)/share/man
ETCDIR ?= $(DESTDIR)/etc
-LIBDIR ?= ${PREFIX}/lib
+LIBDIR ?= $(PREFIX)/lib
+INCLUDEDIR ?= $(PREFIX)/include
CFLAGS = -Werror -Wall -W
-override CFLAGS += -I$(PREFIX)/include -D_FILE_OFFSET_BITS=64
+override CFLAGS += -I$(INCLUDEDIR) -D_FILE_OFFSET_BITS=64
LDLIBS = -lselinux -L$(LIBDIR)
all: sestatus
diff -ur policycoreutils-2.1.0.orig/setfiles/Makefile policycoreutils-2.1.0/setfiles/Makefile
--- policycoreutils-2.1.0.orig/setfiles/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/setfiles/Makefile 2012-01-17 13:34:38.168834084 -0600
@@ -1,15 +1,16 @@
# Installation directories.
-PREFIX ?= ${DESTDIR}/usr
-SBINDIR ?= $(DESTDIR)/sbin
-MANDIR = $(PREFIX)/share/man
+PREFIX ?= $(DESTDIR)/usr
+BASE_SBINDIR ?= $(DESTDIR)/sbin
+MANDIR ?= $(PREFIX)/share/man
LIBDIR ?= $(PREFIX)/lib
-AUDITH = $(shell ls /usr/include/libaudit.h 2>/dev/null)
+INCLUDEDIR ?= $(PREFIX)/include
+AUDITH ?= $(shell ls $(INCLUDEDIR)/libaudit.h 2>/dev/null)
CFLAGS = -g -Werror -Wall -W
-override CFLAGS += -I$(PREFIX)/include
+override CFLAGS += -I$(INCLUDEDIR)
LDLIBS = -lselinux -lsepol -L$(LIBDIR)
-ifeq (${AUDITH}, /usr/include/libaudit.h)
+ifneq ($(AUDITH),)
override CFLAGS += -DUSE_AUDIT
LDLIBS += -laudit
endif
@@ -23,9 +24,9 @@
install: all
[ -d $(MANDIR)/man8 ] || mkdir -p $(MANDIR)/man8
- -mkdir -p $(SBINDIR)
- install -m 755 setfiles $(SBINDIR)
- (cd $(SBINDIR) && ln -sf setfiles restorecon)
+ -mkdir -p $(BASE_SBINDIR)
+ install -m 755 setfiles $(BASE_SBINDIR)
+ (cd $(BASE_SBINDIR) && ln -sf setfiles restorecon)
install -m 644 setfiles.8 restorecon.8 $(MANDIR)/man8
clean:
@@ -35,4 +36,4 @@
../../scripts/Lindent $(wildcard *.[ch])
relabel: install
- /sbin/restorecon $(SBINDIR)/setfiles
+ /sbin/restorecon $(BASE_SBINDIR)/setfiles
diff -ur policycoreutils-2.1.0.orig/setsebool/Makefile policycoreutils-2.1.0/setsebool/Makefile
--- policycoreutils-2.1.0.orig/setsebool/Makefile 2011-07-27 14:32:54.000000000 -0500
+++ policycoreutils-2.1.0/setsebool/Makefile 2012-01-17 13:24:59.267961760 -0600
@@ -2,8 +2,8 @@
PREFIX ?= $(DESTDIR)/usr
INCLUDEDIR ?= $(PREFIX)/include
SBINDIR ?= $(PREFIX)/sbin
-MANDIR = $(PREFIX)/share/man
-LIBDIR ?= ${PREFIX}/lib
+MANDIR ?= $(PREFIX)/share/man
+LIBDIR ?= $(PREFIX)/lib
CFLAGS ?= -Werror -Wall -W
override CFLAGS += -I$(INCLUDEDIR)

View File

@ -1,52 +0,0 @@
SUMMARY = "SELinux policy core utilities"
DESCRIPTION = "policycoreutils contains the policy core utilities that are required \
for basic operation of a SELinux system. These utilities include \
load_policy to load policies, setfiles to label filesystems, newrole \
to switch roles, and run_init to run /etc/init.d scripts in the proper \
context."
SECTION = "base"
PR = "r1"
LICENSE = "GPLv2+"
LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
include selinux.inc
SRC_URI += "file://makefiles.patch"
SRC_URI[md5sum] = "f418384ea5bc57080a6ace843646aba9"
SRC_URI[sha256sum] = "6199b07fd4280e455ea05933cee510b5e09ad3f60b0544382231fe05b787d3f3"
DEPENDS += "libsepol libselinux libsemanage libcap-ng"
DEPENDS += "${@base_contains('DISTRO_FEATURES', 'pam', 'libpam audit', '', d)}"
RDEPENDS_${PN} += "sepolgen"
EXTRA_OEMAKE += "PREFIX='$(DESTDIR)${prefix}' BASE_SBINDIR='$(DESTDIR)${base_sbindir}' SBINDIR='$(DESTDIR)${sbindir}'"
EXTRA_OEMAKE += "BINDIR='$(DESTDIR)${bindir}' MANDIR='$(DESTDIR)/${mandir}' LOCALEDIR='$(DESTDIR)/${datadir}/locale'"
EXTRA_OEMAKE += "ETCDIR='$(DESTDIR)${sysconfdir}' SHAREDIR='$(DESTDIR)${datadir}'"
EXTRA_OEMAKE += "INITDIR='$(DESTDIR)${sysconfdir}/init.d'"
EXTRA_OEMAKE += "INCLUDEDIR='${STAGING_INCDIR}' LIBDIR='${STAGING_LIBDIR}'"
# Main Makefile
EXTRA_OEMAKE += "INOTIFYH=y"
# newrole/Makefile
# Options: PAMH, AUDITH, AUDIT_LOG_PRIV, NAMESPACE_PRIV, LSPP_PRIV
EXTRA_OEMAKE += "${@base_contains('DISTRO_FEATURES', 'pam', 'PAMH=y AUDITH=y', '', d)}"
# restorecond/Makefile
# AUTOSTARTDIR ?= $(DESTDIR)/etc/xdg/autostart DBUSSERVICEDIR ?= $(DESTDIR)/usr/share/dbus-1/services
# SELINUXDIR ?= $(DESTDIR)/etc/selinux
# semanage/Makefile
EXTRA_OEMAKE += "PYLIBVER='python${PYTHON_BASEVERSION}'"
do_compile() {
oe_runmake all
}
do_install() {
oe_runmake DESTDIR=${D} install
if [ "${base_sbindir}" != "${sbindir}" ]; then
mv ${D}${base_sbindir}/fixfiles ${D}${sbindir}/fixfiles
fi
rm ${D}${datadir}/sandboxX.sh
}

View File

@ -1,7 +0,0 @@
HOMEPAGE = "http://userspace.selinuxproject.org"
SRC_URI = "http://userspace.selinuxproject.org/releases/20110727/devel/${PN}-${PV}.tar.gz"
do_install() {
oe_runmake install DESTDIR="${D}" PREFIX="${D}/${prefix}" INCLUDEDIR="${D}/${includedir}" LIBDIR="${D}/${libdir}" SHLIBDIR="${D}/${base_libdir}"
}

View File

@ -1,17 +0,0 @@
SUMMARY = "Python modules for supporting various SELinux utilities."
DESCRIPTION = "Python modules for supporting various SELinux utilities."
SECTION = "base"
PR = "r1"
LICENSE = "LGPLv2+"
LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
include selinux.inc
SRC_URI[md5sum] = "efc281a45fde093c6506853617594ce6"
SRC_URI[sha256sum] = "9f2f6b07912aee3ecf32060ea09bab6d8d9cfe492638b28f058b4490b44c8e78"
EXTRA_OEMAKE += "PYTHONLIBDIR='${libdir}/python${PYTHON_BASEVERSION}/site-packages'"
DEPENDS += "python"
FILES_${PN} += "${libdir}/python${PYTHON_BASEVERSION}/site-packages"