From a38593e479e49f30912b30f4643316f52ff91944 Mon Sep 17 00:00:00 2001 From: Juliano Martinez Date: Tue, 13 Dec 2011 10:31:10 -0200 Subject: [PATCH 1/4] added debian package --- debian/README | 6 +++ debian/README.Debian | 6 +++ debian/README.source | 9 +++++ debian/changelog | 5 +++ debian/compat | 1 + debian/control | 17 +++++++++ debian/copyright | 37 +++++++++++++++++++ debian/docs | 1 + debian/files | 1 + debian/python-iptables.debhelper.log | 45 +++++++++++++++++++++++ debian/python-iptables.postinst.debhelper | 5 +++ debian/python-iptables.prerm.debhelper | 5 +++ debian/python-iptables.substvars | 5 +++ debian/pyversions | 1 + debian/rules | 13 +++++++ debian/source/format | 1 + 16 files changed, 158 insertions(+) create mode 100644 debian/README create mode 100644 debian/README.Debian create mode 100644 debian/README.source create mode 100644 debian/changelog create mode 100644 debian/compat create mode 100644 debian/control create mode 100644 debian/copyright create mode 100644 debian/docs create mode 100644 debian/files create mode 100644 debian/python-iptables.debhelper.log create mode 100644 debian/python-iptables.postinst.debhelper create mode 100644 debian/python-iptables.prerm.debhelper create mode 100644 debian/python-iptables.substvars create mode 100644 debian/pyversions create mode 100755 debian/rules create mode 100644 debian/source/format diff --git a/debian/README b/debian/README new file mode 100644 index 0000000..43ea001 --- /dev/null +++ b/debian/README @@ -0,0 +1,6 @@ +The Debian Package python-iptables +---------------------------- + +Comments regarding the Package + + -- Juliano Martinez Tue, 13 Dec 2011 10:10:44 -0200 diff --git a/debian/README.Debian b/debian/README.Debian new file mode 100644 index 0000000..42ab769 --- /dev/null +++ b/debian/README.Debian @@ -0,0 +1,6 @@ +python-iptables for Debian +-------------------------- + + + + -- Juliano Martinez Tue, 13 Dec 2011 10:10:44 -0200 diff --git a/debian/README.source b/debian/README.source new file mode 100644 index 0000000..2d9dc2e --- /dev/null +++ b/debian/README.source @@ -0,0 +1,9 @@ +python-iptables for Debian +-------------------------- + + + + + + diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 0000000..9a73782 --- /dev/null +++ b/debian/changelog @@ -0,0 +1,5 @@ +python-iptables (0.1.1) unstable; urgency=low + + * Initial Release. + + -- Juliano Martinez Tue, 13 Dec 2011 10:10:44 -0200 diff --git a/debian/compat b/debian/compat new file mode 100644 index 0000000..7f8f011 --- /dev/null +++ b/debian/compat @@ -0,0 +1 @@ +7 diff --git a/debian/control b/debian/control new file mode 100644 index 0000000..fe6c84a --- /dev/null +++ b/debian/control @@ -0,0 +1,17 @@ +Source: python-iptables +Section: net +Priority: extra +Maintainer: Juliano Martinez +Build-Depends: debhelper (>= 7.0.50~) +Standards-Version: 3.8.4 +Homepage: https://github.com/ldx/python-iptables + +Package: python-iptables +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: Python bindings for iptables + Python-iptables is a Python project that provides bindings to the iptables C libraries in Linux. + Interoperability with iptables is achieved using the iptables C libraries (libiptc, libxtables, + and iptables extensions), not calling the iptables executable and parsing its output as most other + iptables wrapper libraries do; this makes python-iptables faster and not prone to parsing errors, + at the same time leveraging all available iptables match and target extensions without further work. diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 0000000..9ab11ee --- /dev/null +++ b/debian/copyright @@ -0,0 +1,37 @@ +This work was packaged for Debian by: + + Juliano Martinez on Tue, 13 Dec 2011 10:10:44 -0200 + +It was downloaded from: + + https://github.com/ldx/python-iptables + +Upstream Author(s): + + ldx -> https://github.com/ldx + +Copyright: + + Nilvec -> http://nilvec.com + +License: + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +On Debian systems, the complete text of the Apache version 2.0 license +can be found in "/usr/share/common-licenses/Apache-2.0". + +The Debian packaging is: + + Copyright (C) 2011 Juliano Martinez a.k.a (ncode) + diff --git a/debian/docs b/debian/docs new file mode 100644 index 0000000..e845566 --- /dev/null +++ b/debian/docs @@ -0,0 +1 @@ +README diff --git a/debian/files b/debian/files new file mode 100644 index 0000000..305abf7 --- /dev/null +++ b/debian/files @@ -0,0 +1 @@ +python-iptables_0.1.1_amd64.deb net extra diff --git a/debian/python-iptables.debhelper.log b/debian/python-iptables.debhelper.log new file mode 100644 index 0000000..2d06fcd --- /dev/null +++ b/debian/python-iptables.debhelper.log @@ -0,0 +1,45 @@ +dh_auto_configure +dh_auto_build +dh_auto_test +dh_prep +dh_installdirs +dh_auto_install +dh_install +dh_installdocs +dh_installchangelogs +dh_installexamples +dh_installman +dh_installcatalogs +dh_installcron +dh_installdebconf +dh_installemacsen +dh_installifupdown +dh_installinfo +dh_pysupport +dh_installinit +dh_installmenu +dh_installmime +dh_installmodules +dh_installlogcheck +dh_installlogrotate +dh_installpam +dh_installppp +dh_installudev +dh_installwm +dh_installxfonts +dh_bugfiles +dh_lintian +dh_gconf +dh_icons +dh_perl +dh_usrlocal +dh_link +dh_compress +dh_fixperms +dh_strip +dh_makeshlibs +dh_shlibdeps +dh_installdeb +dh_gencontrol +dh_md5sums +dh_builddeb diff --git a/debian/python-iptables.postinst.debhelper b/debian/python-iptables.postinst.debhelper new file mode 100644 index 0000000..1f8666b --- /dev/null +++ b/debian/python-iptables.postinst.debhelper @@ -0,0 +1,5 @@ +# Automatically added by dh_pysupport +if which update-python-modules >/dev/null 2>&1; then + update-python-modules python-iptables.public +fi +# End automatically added section diff --git a/debian/python-iptables.prerm.debhelper b/debian/python-iptables.prerm.debhelper new file mode 100644 index 0000000..07d0b9d --- /dev/null +++ b/debian/python-iptables.prerm.debhelper @@ -0,0 +1,5 @@ +# Automatically added by dh_pysupport +if which update-python-modules >/dev/null 2>&1; then + update-python-modules -c python-iptables.public +fi +# End automatically added section diff --git a/debian/python-iptables.substvars b/debian/python-iptables.substvars new file mode 100644 index 0000000..8c18101 --- /dev/null +++ b/debian/python-iptables.substvars @@ -0,0 +1,5 @@ +python:Versions=2.6 +python:Provides=python2.6-iptables +python:Depends=python (<< 2.7), python (>= 2.6), python-support (>= 0.90.0) +shlibs:Depends=libc6 (>= 2.2.5) +misc:Depends= diff --git a/debian/pyversions b/debian/pyversions new file mode 100644 index 0000000..5154b3f --- /dev/null +++ b/debian/pyversions @@ -0,0 +1 @@ +2.6 diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..b760bee --- /dev/null +++ b/debian/rules @@ -0,0 +1,13 @@ +#!/usr/bin/make -f +# -*- makefile -*- +# Sample debian/rules that uses debhelper. +# This file was originally written by Joey Hess and Craig Small. +# As a special exception, when this file is copied by dh-make into a +# dh-make output file, you may use that output file without restriction. +# This special exception was added by Craig Small in version 0.37 of dh-make. + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +%: + dh $@ diff --git a/debian/source/format b/debian/source/format new file mode 100644 index 0000000..89ae9db --- /dev/null +++ b/debian/source/format @@ -0,0 +1 @@ +3.0 (native) From 88581606e98ba14178df7594e68fdc4ee2b4c8cb Mon Sep 17 00:00:00 2001 From: Juliano Martinez Date: Thu, 15 Dec 2011 20:33:23 -0200 Subject: [PATCH 2/4] updated package to work on both debian and ubuntu --- debian/control | 7 +++-- debian/python-iptables.debhelper.log | 41 ++++++++++------------------ debian/rules | 8 ++++-- 3 files changed, 24 insertions(+), 32 deletions(-) diff --git a/debian/control b/debian/control index fe6c84a..b3a3f72 100644 --- a/debian/control +++ b/debian/control @@ -2,15 +2,16 @@ Source: python-iptables Section: net Priority: extra Maintainer: Juliano Martinez -Build-Depends: debhelper (>= 7.0.50~) +Build-Depends: cdbs (>= 0.4.49), debhelper (>= 7), python (>= 2.4), python-support +XS-Python-Version: >= 2.6 Standards-Version: 3.8.4 Homepage: https://github.com/ldx/python-iptables Package: python-iptables Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends} -Description: Python bindings for iptables - Python-iptables is a Python project that provides bindings to the iptables C libraries in Linux. +Description: Python bindings for iptables + Python-iptables is a Python project that provides bindings to the iptables C libraries in Linux. Interoperability with iptables is achieved using the iptables C libraries (libiptc, libxtables, and iptables extensions), not calling the iptables executable and parsing its output as most other iptables wrapper libraries do; this makes python-iptables faster and not prone to parsing errors, diff --git a/debian/python-iptables.debhelper.log b/debian/python-iptables.debhelper.log index 2d06fcd..d5c45b8 100644 --- a/debian/python-iptables.debhelper.log +++ b/debian/python-iptables.debhelper.log @@ -1,45 +1,34 @@ -dh_auto_configure -dh_auto_build -dh_auto_test dh_prep dh_installdirs -dh_auto_install -dh_install +dh_installdirs dh_installdocs -dh_installchangelogs dh_installexamples dh_installman -dh_installcatalogs +dh_installinfo +dh_installmenu dh_installcron +dh_installinit dh_installdebconf dh_installemacsen -dh_installifupdown -dh_installinfo -dh_pysupport -dh_installinit -dh_installmenu -dh_installmime -dh_installmodules -dh_installlogcheck -dh_installlogrotate +dh_installcatalogs dh_installpam -dh_installppp +dh_installlogrotate +dh_installlogcheck +dh_installchangelogs dh_installudev -dh_installwm -dh_installxfonts -dh_bugfiles dh_lintian -dh_gconf -dh_icons -dh_perl -dh_usrlocal +dh_install dh_link +dh_buildinfo +dh_installmime +dh_pysupport +dh_strip dh_compress dh_fixperms -dh_strip dh_makeshlibs -dh_shlibdeps dh_installdeb +dh_perl +dh_shlibdeps dh_gencontrol dh_md5sums dh_builddeb diff --git a/debian/rules b/debian/rules index b760bee..4cd3ea9 100755 --- a/debian/rules +++ b/debian/rules @@ -7,7 +7,9 @@ # This special exception was added by Craig Small in version 0.37 of dh-make. # Uncomment this to turn on verbose mode. -#export DH_VERBOSE=1 +export DH_VERBOSE=1 -%: - dh $@ +DEB_PYTHON_SYSTEM=pysupport + +include /usr/share/cdbs/1/rules/debhelper.mk +include /usr/share/cdbs/1/class/python-distutils.mk From 8b000d8af91fabc3d7cf224cd9849ef698516275 Mon Sep 17 00:00:00 2001 From: Juliano Martinez Date: Thu, 15 Dec 2011 20:33:40 -0200 Subject: [PATCH 3/4] updated package to work on both debian and ubuntu --- debian/pyversions | 1 - 1 file changed, 1 deletion(-) delete mode 100644 debian/pyversions diff --git a/debian/pyversions b/debian/pyversions deleted file mode 100644 index 5154b3f..0000000 --- a/debian/pyversions +++ /dev/null @@ -1 +0,0 @@ -2.6 From d0c256bdebca0f5299aaf2b6d6aca0c988f6a2d2 Mon Sep 17 00:00:00 2001 From: Juliano Martinez Date: Mon, 19 Dec 2011 11:49:16 -0200 Subject: [PATCH 4/4] cleaning and fixing deps --- debian/control | 2 +- debian/files | 1 - debian/python-iptables.debhelper.log | 34 ----------------------- debian/python-iptables.postinst.debhelper | 5 ---- debian/python-iptables.prerm.debhelper | 5 ---- debian/python-iptables.substvars | 5 ---- 6 files changed, 1 insertion(+), 51 deletions(-) delete mode 100644 debian/files delete mode 100644 debian/python-iptables.debhelper.log delete mode 100644 debian/python-iptables.postinst.debhelper delete mode 100644 debian/python-iptables.prerm.debhelper delete mode 100644 debian/python-iptables.substvars diff --git a/debian/control b/debian/control index b3a3f72..b3582ab 100644 --- a/debian/control +++ b/debian/control @@ -2,7 +2,7 @@ Source: python-iptables Section: net Priority: extra Maintainer: Juliano Martinez -Build-Depends: cdbs (>= 0.4.49), debhelper (>= 7), python (>= 2.4), python-support +Build-Depends: cdbs (>= 0.4.49), debhelper (>= 7), python (>= 2.4), python-support, python-all-dev (>= 2.3.5-11) XS-Python-Version: >= 2.6 Standards-Version: 3.8.4 Homepage: https://github.com/ldx/python-iptables diff --git a/debian/files b/debian/files deleted file mode 100644 index 305abf7..0000000 --- a/debian/files +++ /dev/null @@ -1 +0,0 @@ -python-iptables_0.1.1_amd64.deb net extra diff --git a/debian/python-iptables.debhelper.log b/debian/python-iptables.debhelper.log deleted file mode 100644 index d5c45b8..0000000 --- a/debian/python-iptables.debhelper.log +++ /dev/null @@ -1,34 +0,0 @@ -dh_prep -dh_installdirs -dh_installdirs -dh_installdocs -dh_installexamples -dh_installman -dh_installinfo -dh_installmenu -dh_installcron -dh_installinit -dh_installdebconf -dh_installemacsen -dh_installcatalogs -dh_installpam -dh_installlogrotate -dh_installlogcheck -dh_installchangelogs -dh_installudev -dh_lintian -dh_install -dh_link -dh_buildinfo -dh_installmime -dh_pysupport -dh_strip -dh_compress -dh_fixperms -dh_makeshlibs -dh_installdeb -dh_perl -dh_shlibdeps -dh_gencontrol -dh_md5sums -dh_builddeb diff --git a/debian/python-iptables.postinst.debhelper b/debian/python-iptables.postinst.debhelper deleted file mode 100644 index 1f8666b..0000000 --- a/debian/python-iptables.postinst.debhelper +++ /dev/null @@ -1,5 +0,0 @@ -# Automatically added by dh_pysupport -if which update-python-modules >/dev/null 2>&1; then - update-python-modules python-iptables.public -fi -# End automatically added section diff --git a/debian/python-iptables.prerm.debhelper b/debian/python-iptables.prerm.debhelper deleted file mode 100644 index 07d0b9d..0000000 --- a/debian/python-iptables.prerm.debhelper +++ /dev/null @@ -1,5 +0,0 @@ -# Automatically added by dh_pysupport -if which update-python-modules >/dev/null 2>&1; then - update-python-modules -c python-iptables.public -fi -# End automatically added section diff --git a/debian/python-iptables.substvars b/debian/python-iptables.substvars deleted file mode 100644 index 8c18101..0000000 --- a/debian/python-iptables.substvars +++ /dev/null @@ -1,5 +0,0 @@ -python:Versions=2.6 -python:Provides=python2.6-iptables -python:Depends=python (<< 2.7), python (>= 2.6), python-support (>= 0.90.0) -shlibs:Depends=libc6 (>= 2.2.5) -misc:Depends=