From e363c497694d640d80af85dc254b0b40d72004ed Mon Sep 17 00:00:00 2001 From: James Antill Date: Fri, 1 Sep 2006 18:38:21 +0000 Subject: [PATCH] auto-import netlabel_tools-0.16-5 on branch devel from netlabel_tools-0.16-5.src.rpm --- .cvsignore | 1 + netlabel_tools-0.16-new-hdrs.patch | 65 +++++++++++++++++++++++++ netlabel_tools.spec | 78 ++++++++++++++++++++++++++++++ sources | 1 + 4 files changed, 145 insertions(+) create mode 100644 netlabel_tools-0.16-new-hdrs.patch create mode 100644 netlabel_tools.spec diff --git a/.cvsignore b/.cvsignore index e69de29..79357aa 100644 --- a/.cvsignore +++ b/.cvsignore @@ -0,0 +1 @@ +netlabel_tools-0.16.tar.gz diff --git a/netlabel_tools-0.16-new-hdrs.patch b/netlabel_tools-0.16-new-hdrs.patch new file mode 100644 index 0000000..06ce44f --- /dev/null +++ b/netlabel_tools-0.16-new-hdrs.patch @@ -0,0 +1,65 @@ +diff -rup netlabel_tools-0.16-orig/include/linux/netlabel.h netlabel_tools-0.16/include/linux/netlabel.h +--- netlabel_tools-0.16-orig/include/linux/netlabel.h 2006-07-31 17:20:41.000000000 -0400 ++++ netlabel_tools-0.16/include/linux/netlabel.h 2006-08-29 14:07:44.000000000 -0400 +@@ -39,7 +39,9 @@ + + /* FIXME: perhaps some or all this lives in a system header file? */ + +-#define NLMSG_HDRLEN NLMSG_ALIGN(sizeof(struct nlmsghdr)) ++#ifndef NLMSG_HDRLEN /* newer netlink.h has these... */ ++ ++# define NLMSG_HDRLEN NLMSG_ALIGN(sizeof(struct nlmsghdr)) + + struct nlattr + { +@@ -47,6 +49,13 @@ struct nlattr + unsigned short nla_type; + }; + ++# define NLA_HDRLEN NLMSG_ALIGN(sizeof(struct nlattr)) ++ ++# define NETLINK_GENERIC 16 ++ ++ ++#endif ++ + enum { + NLA_UNSPEC, + NLA_U8, +@@ -61,10 +70,6 @@ enum { + }; + #define NLA_TYPE_MAX (__NLA_TYPE_MAX - 1) + +-#define NLA_HDRLEN NLMSG_ALIGN(sizeof(struct nlattr)) +- +-#define NETLINK_GENERIC 16 +- + struct genlmsghdr { + unsigned char cmd; + unsigned char version; +--- netlabel_tools-0.16-orig/Makefile 2006-06-27 13:06:28.000000000 -0400 ++++ netlabel_tools-0.16/Makefile 2006-08-29 16:42:09.000000000 -0400 +@@ -43,8 +43,9 @@ INSTALL_SBIN_DIR = $(INSTALL_PREFIX)/sbi + INSTALL_BIN_DIR = $(INSTALL_PREFIX)/bin + INSTALL_MAN_DIR = $(INSTALL_PREFIX)/share/man + +-OWNER = root +-GROUP = root ++# Mock doesn't allow this. ++#OWNER = root ++#GROUP = root + + # + # targets +@@ -77,9 +78,9 @@ install: $(SUBDIRS) + @echo "INFO: installing files in $(INSTALL_PREFIX)" + @mkdir -p $(INSTALL_SBIN_DIR) + @mkdir -p $(INSTALL_MAN_DIR)/man8 +- @install -o $(OWNER) -g $(GROUP) -m 755 netlabelctl/netlabelctl \ ++ @install -m 755 netlabelctl/netlabelctl \ + $(INSTALL_SBIN_DIR)/netlabelctl +- @install -o $(OWNER) -g $(GROUP) -m 644 docs/man/netlabelctl.8 \ ++ @install -m 644 docs/man/netlabelctl.8 \ + $(INSTALL_MAN_DIR)/man8 + + clean: diff --git a/netlabel_tools.spec b/netlabel_tools.spec new file mode 100644 index 0000000..ed7fd5c --- /dev/null +++ b/netlabel_tools.spec @@ -0,0 +1,78 @@ + +%define home_base_url http://free.linux.hp.com/~pmoore/projects/linux_cipso + +Summary: Tools to manage the Linux NetLabel subsystem +Name: netlabel_tools +Version: 0.16 +Release: 5%{?dist} +License: GPL +Group: System Environment/Daemons +URL: %{home_base_url} +Source0: %{home_base_url}/%{name}-%{version}.tar.gz +Patch: netlabel_tools-0.16-new-hdrs.patch +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +BuildRequires: kernel-headers + +%description +NetLabel is a kernel subsystem which implements explicit packet labeling +protocols such as CIPSO and RIPSO for Linux. Packet labeling is used in +secure networks to mark packets with the security attributes of the data they +contain. This package provides the necessary user space tools to query and +configure the kernel subsystem. + +%prep +%setup -q -n %{name}-%{version} + +%patch -p1 + +%build +# Don't use _smp_mflags, it's small and a hand crafted Makefile +make + +%install +rm -rf $RPM_BUILD_ROOT +make INSTALL_PREFIX=${RPM_BUILD_ROOT} \ + INSTALL_MAN_DIR=${RPM_BUILD_ROOT}/usr/share/man \ + install + +%clean +rm -rf $RPM_BUILD_ROOT + +%files +%defattr(-,root,root) +%doc docs/*.txt +%attr(0755,root,root) /sbin/* +%attr(0644,root,root) %{_mandir}/man8/* + +%changelog +* Tue Aug 29 2006 James Antill - 0.16-5 +- Fix install calls for mock. + +* Tue Aug 29 2006 James Antill - 0.16-4 +- Fix more reviewing problems, building on newer kernel-headers. +- Add URL tag. + +* Fri Aug 18 2006 James Antill - 0.16-3 +- Fix minor review problems. +- Added BuildRequires for kernel headers (netlink). + +* Fri Aug 18 2006 James Antill - 0.16-2 +- Use root as owner. +- Contribute to fedora extras. + +* Thu Aug 3 2006 Paul Moore 0.16-1 +- Bumped version number. + +* Thu Jul 6 2006 Paul Moore 0.15-1 +- Bumped version number. + +* Mon Jun 26 2006 Paul Moore 0.14-1 +- Bumped version number. +- Changes related to including the version number in the path name. +- Changed the netlabelctl perms from 0750 to 0755. +- Removed the patch. (included in the base with edits) +- Updated the description. + +* Fri Jun 23 2006 Steve Grubb 0.13-1 +- Initial build. + diff --git a/sources b/sources index e69de29..7fb3d14 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +a97576c90975716ba089171b125bf7b3 netlabel_tools-0.16.tar.gz