From 07d429ac113f322ef35ee098d1d62157467b71aeb40afad14cbb5911d736fb29 Mon Sep 17 00:00:00 2001 From: Markos Chandras Date: Wed, 27 Dec 2017 10:32:40 +0000 Subject: [PATCH] Accepting request 559117 from home:markoschandras:network - Introduce new python3-firewall and firewall-macros subpackages. The first one contains the firewalld python3 bindings and the second one contains the RPM macros for firewalld. OBS-URL: https://build.opensuse.org/request/show/559117 OBS-URL: https://build.opensuse.org/package/show/security:netfilter/firewalld?expand=0&rev=57 --- firewalld.changes | 7 +++++ firewalld.spec | 74 +++++++++++++++++++++++++++++++++++++++++------ 2 files changed, 72 insertions(+), 9 deletions(-) diff --git a/firewalld.changes b/firewalld.changes index a8bfb24..4643de8 100644 --- a/firewalld.changes +++ b/firewalld.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Thu Dec 21 13:03:11 UTC 2017 - mchandras@suse.de + +- Introduce new python3-firewall and firewall-macros subpackages. + The first one contains the firewalld python3 bindings and the second + one contains the RPM macros for firewalld. + ------------------------------------------------------------------- Wed Nov 29 10:59:45 UTC 2017 - dimstar@opensuse.org diff --git a/firewalld.spec b/firewalld.spec index a0b2902..e07295d 100644 --- a/firewalld.spec +++ b/firewalld.spec @@ -36,6 +36,7 @@ BuildRequires: autoconf BuildRequires: automake BuildRequires: desktop-file-utils BuildRequires: docbook-xsl-stylesheets +BuildRequires: fdupes # Adding tools to BuildRequires as well so they can be autodetected # even though it is probably unlikely for paths to change in the future BuildRequires: ebtables @@ -49,13 +50,10 @@ BuildRequires: iptables BuildRequires: libxslt-tools BuildRequires: python3-devel BuildRequires: systemd-rpm-macros -Requires: dbus-1-python3 Requires: ebtables Requires: ipset Requires: iptables -Requires: python3-decorator -Requires: python3-gobject -Requires: python3-slip-dbus +Requires: python3-firewall = %{version} Requires: sysconfig Requires(post): %fillup_prereq Recommends: %{name}-lang @@ -67,6 +65,25 @@ BuildArch: noarch firewalld is a firewall service daemon that provides a dynamic customizable firewall with a D-Bus interface. +%package -n python3-firewall +Summary: Python3 bindings for FirewallD +Group: Productivity/Networking/Security +Requires: dbus-1-python3 +Requires: python3-decorator +Requires: python3-gobject +Requires: python3-slip-dbus + +%description -n python3-firewall +The python3 bindings for firewalld. + +%package -n firewall-macros +Summary: FirewallD RPM macros +Group: Productivity/Networking/Security + +%description -n firewall-macros +This package provides the firewalld RPM macros file needed by packages +which provide their own firewalld service files. + %package -n firewall-applet Summary: Firewall panel applet Group: Productivity/Networking/Security @@ -116,6 +133,9 @@ make %{?_smp_mflags} %py3_compile %{buildroot} +# remove files that shouldn't exist in the final rpms +rm -r %{buildroot}%{_datadir}/%{name}/__pycache__ + desktop-file-install --delete-original \ --dir %{buildroot}%{_sysconfdir}/xdg/autostart \ %{buildroot}%{_sysconfdir}/xdg/autostart/firewall-applet.desktop @@ -134,6 +154,8 @@ ln -sf %{_sbindir}/service %{buildroot}/%{_sbindir}/rcfirewalld rm %{buildroot}%{_rpmconfigdir}/macros.d/macros.firewalld install -D -m644 config/macros.firewalld %{buildroot}%{_sysconfdir}/rpm/macros.firewalld +%fdupes %{buildroot}%{python3_sitelib} + %find_lang %{name} --all-name %pre @@ -191,9 +213,21 @@ fi %{_bindir}/firewallctl %dir %{_datadir}/bash-completion/completions %{_datadir}/bash-completion/completions/firewall-cmd -%{_libexecdir}/firewalld +%dir %{_libexecdir}/firewalld +%dir %{_libexecdir}/firewalld/icmptypes +%dir %{_libexecdir}/firewalld/ipsets +%dir %{_libexecdir}/firewalld/services +%dir %{_libexecdir}/firewalld/zones +%dir %{_libexecdir}/firewalld/helpers +%dir %{_libexecdir}/firewalld/xmlschema +%{_libexecdir}/firewalld/icmptypes/*.xml +%{_libexecdir}/firewalld/ipsets/README +%{_libexecdir}/firewalld/services/*.xml +%{_libexecdir}/firewalld/zones/*.xml +%{_libexecdir}/firewalld/helpers/*.xml +%{_libexecdir}/firewalld/xmlschema/check.sh +%{_libexecdir}/firewalld/xmlschema/*.xsd %{_datadir}/polkit-1 -%config %{_sysconfdir}/rpm/macros.firewalld %dir %{_sysconfdir}/dbus-1 %dir %{_sysconfdir}/dbus-1/system.d %dir %{_sysconfdir}/modprobe.d @@ -211,14 +245,36 @@ fi %{_unitdir}/firewalld.service %{_fillupdir}/sysconfig.%{name} %config(noreplace) %{_sysconfdir}/dbus-1/system.d/FirewallD.conf -%attr(0755,root,root) %dir %{python3_sitelib}/firewall -%{_datadir}/firewalld/__pycache__ -%{python3_sitelib}/firewall/* %{_mandir}/man1/firewall*cmd*.1* %{_mandir}/man1/firewalld*.1* %{_mandir}/man1/firewallctl*.1* %{_mandir}/man5/firewall*.5* +%files -n python3-firewall +%attr(0755,root,root) %dir %{python3_sitelib}/firewall +%attr(0755,root,root) %dir %{python3_sitelib}/firewall/__pycache__ +%attr(0755,root,root) %dir %{python3_sitelib}/firewall/config +%attr(0755,root,root) %dir %{python3_sitelib}/firewall/config/__pycache__ +%attr(0755,root,root) %dir %{python3_sitelib}/firewall/core +%attr(0755,root,root) %dir %{python3_sitelib}/firewall/core/__pycache__ +%attr(0755,root,root) %dir %{python3_sitelib}/firewall/core/io +%attr(0755,root,root) %dir %{python3_sitelib}/firewall/core/io/__pycache__ +%attr(0755,root,root) %dir %{python3_sitelib}/firewall/server +%attr(0755,root,root) %dir %{python3_sitelib}/firewall/server/__pycache__ +%{python3_sitelib}/firewall/__pycache__/*.py* +%{python3_sitelib}/firewall/*.py* +%{python3_sitelib}/firewall/config/*.py* +%{python3_sitelib}/firewall/config/__pycache__/*.py* +%{python3_sitelib}/firewall/core/*.py* +%{python3_sitelib}/firewall/core/__pycache__/*.py* +%{python3_sitelib}/firewall/core/io/*.py* +%{python3_sitelib}/firewall/core/io/__pycache__/*.py* +%{python3_sitelib}/firewall/server/*.py* +%{python3_sitelib}/firewall/server/__pycache__/*.py* + +%files -n firewall-macros +%config %{_sysconfdir}/rpm/macros.firewalld + %files -n firewall-applet %attr(0755,root,root) %{_bindir}/firewall-applet %dir %{_sysconfdir}/firewall