[packages/netlabel_tools] Up to 0.30.0

arekm arekm at pld-linux.org
Fri Nov 27 21:39:53 CET 2026


commit 06830fbfc8fd0715bf1bb2108dcaeae9de933897
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date:   Fri Nov 27 15:10:09 2026 +0100

    Up to 0.30.0

 netlabel_tools-new-hdrs.patch | 33 --------------------------
 netlabel_tools.spec           | 54 ++++++++++++++++++++++++++++++-------------
 2 files changed, 38 insertions(+), 49 deletions(-)
---
diff --git a/netlabel_tools.spec b/netlabel_tools.spec
index 0fd1bcf..27a548e 100644
--- a/netlabel_tools.spec
+++ b/netlabel_tools.spec
@@ -1,17 +1,19 @@
 Summary:	Tools to manage the Linux NetLabel subsystem
 Summary(pl.UTF-8):	Narzędzia do zarządzania linuksowym podsystemem NetLabel
 Name:		netlabel_tools
-Version:	0.19
-Release:	4
-License:	GPL
+Version:	0.30.0
+Release:	1
+License:	GPL v2
 Group:		Daemons
-Source0:	http://dl.sourceforge.net/netlabel/%{name}-%{version}.tar.gz
-# Source0-md5:	f7a9f397e5bf2364676e2beba1a61beb
+Source0:	https://github.com/netlabel/netlabel_tools/releases/download/v%{version}/%{name}-%{version}.tar.gz
+# Source0-md5:	fc6b07bf01bc3f68f5f05071072e521e
 Source1:	%{name}.init
 Source2:	%{name}.rules
-Patch1:		%{name}-new-hdrs.patch
-URL:		http://netlabel.sourceforge.net/
-BuildRequires:	libnl-devel >= 1.0
+URL:		https://github.com/netlabel/netlabel_tools
+BuildRequires:	libnl-devel >= 3.0
+BuildRequires:	rpmbuild(macros) >= 1.644
+Requires(post,preun,postun):	systemd-units >= 38
+Requires:	systemd-units >= 38
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -32,18 +34,22 @@ odpytywania i konfigurowania podsystemu jądra.
 
 %prep
 %setup -q
-%patch -P1 -p1
 
 %build
-%{__make} -j1 \
-	CC="%{__cc}"
+%configure \
+	--sbindir=/sbin \
+	ac_cv_prog_have_doxygen=no \
+	--with-systemdsystemunitdir=%{systemdunitdir}
+%{__make}
 
 %install
 rm -rf $RPM_BUILD_ROOT
 
 %{__make} install \
-	INSTALL_PREFIX=$RPM_BUILD_ROOT \
-	INSTALL_MAN_DIR=$RPM_BUILD_ROOT%{_mandir}
+	DESTDIR=$RPM_BUILD_ROOT
+
+# unit hardcodes /usr/sbin, helper is installed in /sbin
+%{__sed} -i -e 's,/usr/sbin/netlabel-config,/sbin/netlabel-config,' $RPM_BUILD_ROOT%{systemdunitdir}/netlabel.service
 
 install -D %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/netlabel
 install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/netlabel.rules
@@ -51,10 +57,26 @@ install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/netlabel.rules
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%post
+/sbin/chkconfig --add netlabel
+%systemd_post netlabel.service
+
+%preun
+if [ "$1" = "0" ]; then
+	/sbin/chkconfig --del netlabel
+fi
+%systemd_preun netlabel.service
+
+%postun
+%systemd_reload
+
 %files
 %defattr(644,root,root,755)
-%doc docs/*.txt
-%attr(755,root,root) /sbin/*
+%doc CHANGELOG README
+%attr(755,root,root) /sbin/netlabel-config
+%attr(755,root,root) /sbin/netlabelctl
 %attr(754,root,root) /etc/rc.d/init.d/netlabel
 %config(noreplace) %verify(not md5 mtime size) %attr(640,root,root) %{_sysconfdir}/netlabel.rules
-%{_mandir}/man?/*
+%{systemdunitdir}/netlabel.service
+%{_mandir}/man8/netlabel-config.8*
+%{_mandir}/man8/netlabelctl.8*
diff --git a/netlabel_tools-new-hdrs.patch b/netlabel_tools-new-hdrs.patch
deleted file mode 100644
index 1150545..0000000
--- a/netlabel_tools-new-hdrs.patch
+++ /dev/null
@@ -1,33 +0,0 @@
---- 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
-@@ -72,15 +73,15 @@ 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
- 
- $(VERSION_HDR): version_info
- 	@echo "INFO: creating the version header file"
- 	@hdr="$(VERSION_HDR)"; \
--	. version_info; \
-+	. ./version_info; \
- 	echo "/* automatically generated - do not edit */" > $$hdr; \
- 	echo "#ifndef _VERSION_H" >> $$hdr; \
- 	echo "#define _VERSION_H" >> $$hdr; \
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/netlabel_tools.git/commitdiff/06830fbfc8fd0715bf1bb2108dcaeae9de933897



More information about the pld-cvs-commit mailing list