[linux-igd] Fix FTBFS and package bugs.
mooninite
mooninite at fedoraproject.org
Wed Sep 10 22:53:21 UTC 2014
commit b7a7f17fa69cf3f45b9da9775e5176f8832b2e6c
Author: Michael Cronenworth <mike at cchtml.com>
Date: Wed Sep 10 17:52:59 2014 -0500
Fix FTBFS and package bugs.
linux-igd.spec | 73 +++++++++++++++++++++++++++----------------------------
upnpd.service | 6 ++--
2 files changed, 39 insertions(+), 40 deletions(-)
---
diff --git a/linux-igd.spec b/linux-igd.spec
index e312ddd..5c7228b 100644
--- a/linux-igd.spec
+++ b/linux-igd.spec
@@ -1,9 +1,10 @@
%define source_name linuxigd
-Summary: The Linux UPNP Internet GATEWAY DEVICE
Name: linux-igd
+Summary: The Linux UPNP Internet GATEWAY DEVICE
Version: 1.0
-Release: 18%{?dist}
+Release: 19%{?dist}
+License: GPL+
URL: http://linux-igd.sourceforge.net/index.php
Source0: http://downloads.sourceforge.net/%{name}/%{source_name}-%{version}.tar.gz
Source1: upnpd.service
@@ -11,23 +12,22 @@ Patch1: %{source_name}-%{version}.patch
Patch0: %{name}-%{version}-to-cvs20070630.patch
Patch2: %{source_name}-%{version}-restrict-internal-interface.patch
Patch3: linux-igd-includes.patch
-License: GPL+
-Group: System Environment/Daemons
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
-Requires: libupnp >= 1.3.1
-Requires(post): systemd-units
-Requires(preun): systemd-units
-Requires(postun): systemd-units
-# For triggerun
-Requires(post): systemd-sysv
+
+BuildRequires: systemd
BuildRequires: libupnp-devel
+Requires(post): systemd
+Requires(preun): systemd
+Requires(postun): systemd
+
+
%description
This is a daemon that emulates Microsoft's Internet Connection Service (ICS).
It implements the UPnP Internet Gateway Device specification (IGD) and allows
UPnP aware clients, such as MSN Messenger to work properly from behind
a Linux NAT firewall.
+
%prep
%setup -q -c -n %{name}
%patch0
@@ -35,11 +35,13 @@ UPnP aware clients, such as MSN Messenger to work properly from behind
%patch2
%patch3 -p1
+
%build
pushd %{source_name}-%{version}
make CFLAGS="$RPM_OPT_FLAGS" %{?_smp_mflags}
popd
+
%install
rm -rf %{buildroot}
pushd %{source_name}-%{version}
@@ -52,11 +54,14 @@ popd
rm -rf %{buildroot}%{_initrddir}
install -D -m 644 %{SOURCE1} %{buildroot}%{_unitdir}/upnpd.service
+
%clean
rm -rf %{buildroot}
+
%files
-%defattr(-,root,root,-)
+%license LICENSE
+%doc CHANGES TODO
%dir %{_sysconfdir}/linuxigd/
%attr(0644,root,root) %config(noreplace) %{_sysconfdir}/linuxigd/*.xml
%attr(0644,root,root) %config(noreplace) %{_sysconfdir}/upnpd.conf
@@ -64,39 +69,24 @@ rm -rf %{buildroot}
%attr(0644,root,root) %{_mandir}/man8/upnpd.8.gz
%{_sbindir}/upnpd
%{_unitdir}/upnpd.service
-%doc CHANGES LICENSE TODO
+
%post
-if [ $1 -eq 1 ] ; then
- # Initial installation
- /bin/systemctl daemon-reload >/dev/null 2>&1 || :
-fi
+%systemd_post upnpd.service
+
%preun
-if [ $1 -eq 0 ] ; then
- # Package removal, not upgrade
- /bin/systemctl --no-reload disable upnpd.service > /dev/null 2>&1 || :
- /bin/systemctl stop upnpd.service > /dev/null 2>&1 || :
-fi
+%systemd_preun upnpd.service
+
%postun
-/bin/systemctl daemon-reload >/dev/null 2>&1 || :
-if [ $1 -ge 1 ] ; then
- # Package upgrade, not uninstall
- /bin/systemctl try-restart upnpd.service >/dev/null 2>&1 || :
-fi
-
-%triggerun -- linux-igd < 1.0-13
-# Save the current service runlevel info
-# User must manually run systemd-sysv-convert --apply upnpd
-# to migrate them to systemd targets
-/usr/bin/systemd-sysv-convert --save upnpd >/dev/null 2>&1 ||:
-
-# Run these because the SysV package being removed won't do them
-/sbin/chkconfig --del upnpd >/dev/null 2>&1 || :
-/bin/systemctl try-restart upnpd.service >/dev/null 2>&1 || :
+%systemd_postun_with_restart upnpd.service
+
%changelog
+* Wed Sep 10 2014 Michael Cronenworth <mike at cchtml.com> - 1.0-19
+- Many packaging fixes (BZ# 850189, 903740)
+
* Sun Aug 17 2014 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.0-18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
@@ -129,25 +119,34 @@ fi
* Mon Aug 4 2008 Masahiro Hasegawa <masahase at gmail.com> - 1.0-7
- Fix Bug #457730
+
* Sat May 17 2008 Masahiro Hasegawa <masahase at gmail.com> - 1.0-6
- Fix dependencies
+
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng at fedoraproject.org> - 1.0-5
- Autorebuild for GCC 4.3
* Fri Jan 18 2008 Masahiro Hasegawa <masahase at gmail.com> - 1.0-4
- Merge CVS 20070630
+
* Tue Dec 25 2007 Masahiro Hasegawa <masahase at gmail.com> - 1.0-3
- more rewritten by Fedora's rule
+
* Tue Dec 25 2007 Masahiro Hasegawa <masahase at gmail.com> - 1.0-2
- more rewritten by Fedora's rule
+
* Mon Dec 24 2007 Masahiro Hasegawa <masahase at gmail.com>
- Rewritten by Fedora's rule
+
* Wed Oct 31 2007 Masahiro Hasegawa <masahase at gmail.com>
- Version 1.0 release
- first build for version 1.0 (Release)
+
* Mon Aug 14 2006 Tim Brody <tdb01r at ecs.soton.ac.uk>
- Version 0.95 Release 1
- first build for version 0.95 (Release)
+
* Sun Sep 26 2004 Watanabe Keiji <k at elt.ne.jp>
- Version 0.99 Release ELT1
- first build for version 0.92 (CVS Version on Sep 25, 2004.)
+
diff --git a/upnpd.service b/upnpd.service
index b2943ae..8ee01ea 100644
--- a/upnpd.service
+++ b/upnpd.service
@@ -4,9 +4,9 @@ After=network.target
[Service]
EnvironmentFile=-/etc/sysconfig/upnpd
-#ExecStartPre=/usr/sbin/route add -net 239.0.0.0 netmask 255.0.0.0 INTIFACE
-ExecStart=/usr/sbin/upnpd -f EXTIFACE INTIFACE
-#ExecStopPost=/usr/sbin/route del -net 239.0.0.0 netmask 255.0.0.0 INTIFACE
+#ExecStartPre=/usr/sbin/route add -net 239.0.0.0 netmask 255.0.0.0 $INTIFACE
+ExecStart=/usr/sbin/upnpd -f $EXTIFACE $INTIFACE
+#ExecStopPost=/usr/sbin/route del -net 239.0.0.0 netmask 255.0.0.0 $INTIFACE
[Install]
WantedBy=multi-user.target
More information about the scm-commits
mailing list