[packages/ufw] use officially supported installation

glen glen at pld-linux.org
Mon Sep 16 10:01:28 CEST 2013


commit 32d9bc52dbd476f96902c2d6d1639e257a839707
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Mon Sep 16 11:01:15 2013 +0300

    use officially supported installation

 common.py-file.patch | 20 --------------------
 ufw.spec             | 15 ++++++---------
 2 files changed, 6 insertions(+), 29 deletions(-)
---
diff --git a/ufw.spec b/ufw.spec
index 5234f58..fcaa36e 100644
--- a/ufw.spec
+++ b/ufw.spec
@@ -6,7 +6,6 @@ License:	GPL v3+
 Group:		Networking/Admin
 Source0:	http://launchpad.net/ufw/0.33/%{version}/+download/%{name}-%{version}.tar.gz
 # Source0-md5:	3747b453d76709e5a99da209fc0bb5f5
-Patch0:		common.py-file.patch
 URL:		http://launchpad.net/ufw
 BuildRequires:	iptables >= 1.4
 BuildRequires:	python-devel >= 1:2.6
@@ -24,18 +23,15 @@ manipulating the firewall.
 
 %prep
 %setup -q
-# Submited patch through ufw's bug report
-# Fix directory locations instead of #CONFIG_PREFIX#
-# http://bugs.launchpad.net/ufw/+bug/819600
-%patch0 -p0
 
 %build
-%{__python} setup.py build
+# We skip 'build' and run 'install' directly
+# http://bugs.launchpad.net/ufw/+bug/819600
+#%{__python} setup.py build
 
 %install
 rm -rf $RPM_BUILD_ROOT
 %{__python} setup.py install \
-	--skip-build \
 	--optimize=2 \
 	--root=$RPM_BUILD_ROOT
 
@@ -46,7 +42,7 @@ rm -rf $RPM_BUILD_ROOT
 
 %files
 %defattr(644,root,root,755)
-%doc ChangeLog COPYING README* TODO AUTHORS
+%doc ChangeLog README* TODO AUTHORS
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/default/ufw
 %dir %{_sysconfdir}/ufw
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ufw/*.conf
@@ -63,5 +59,6 @@ rm -rf $RPM_BUILD_ROOT
 /lib/ufw/ufw-init-functions
 /lib/ufw/user.rules
 /lib/ufw/user6.rules
-%{py_sitescriptdir}/ufw
+%dir %{py_sitescriptdir}/ufw
+%{py_sitescriptdir}/ufw/*.py[co]
 %{py_sitescriptdir}/ufw-%{version}-py*.egg-info
diff --git a/common.py-file.patch b/common.py-file.patch
deleted file mode 100644
index caec686..0000000
--- a/common.py-file.patch
+++ /dev/null
@@ -1,20 +0,0 @@
---- src/common.py	2011-03-22 13:00:03.000000000 -0500
-+++ src/common.py-new	2011-08-01 21:47:34.889906168 -0500
-@@ -22,12 +22,12 @@
- from ufw.util import debug
- 
- programName = "ufw"
--state_dir = "#STATE_PREFIX#"
--share_dir = "#SHARE_DIR#"
-+state_dir = "/lib/ufw/"
-+share_dir = "/usr/share/"
- trans_dir = share_dir
--config_dir = "#CONFIG_PREFIX#"
--prefix_dir = "#PREFIX#"
--iptables_dir = "#IPTABLES_DIR#"
-+config_dir = "/etc/"
-+prefix_dir = "/usr/"
-+iptables_dir = "/sbin/"
- 
- class UFWError(Exception):
-     '''This class represents ufw exceptions'''
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/ufw.git/commitdiff/32d9bc52dbd476f96902c2d6d1639e257a839707



More information about the pld-cvs-commit mailing list