summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlin Năstac <mrness@gentoo.org>2007-01-14 16:32:43 +0000
committerAlin Năstac <mrness@gentoo.org>2007-01-14 16:32:43 +0000
commitdceb9b7beae8fa0f6d766bd2494d9230ef5297c7 (patch)
tree28a6ddd04e3dbefb1e9f304cf0ac1409d7ddff96 /net-firewall/ipp2p
parentReadd seamonkey-support (diff)
downloadgentoo-2-dceb9b7beae8fa0f6d766bd2494d9230ef5297c7.tar.gz
gentoo-2-dceb9b7beae8fa0f6d766bd2494d9230ef5297c7.tar.bz2
gentoo-2-dceb9b7beae8fa0f6d766bd2494d9230ef5297c7.zip
Fix invalid size error.
(Portage version: 2.1.1-r2)
Diffstat (limited to 'net-firewall/ipp2p')
-rw-r--r--net-firewall/ipp2p/ChangeLog8
-rw-r--r--net-firewall/ipp2p/files/digest-ipp2p-0.8.2-r23
-rw-r--r--net-firewall/ipp2p/files/ipp2p-0.8.2-matchsize.patch28
-rw-r--r--net-firewall/ipp2p/ipp2p-0.8.2-r2.ebuild67
4 files changed, 105 insertions, 1 deletions
diff --git a/net-firewall/ipp2p/ChangeLog b/net-firewall/ipp2p/ChangeLog
index ae0eaa01b354..0744be283efe 100644
--- a/net-firewall/ipp2p/ChangeLog
+++ b/net-firewall/ipp2p/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for net-firewall/ipp2p
# Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-firewall/ipp2p/ChangeLog,v 1.20 2007/01/04 13:18:52 mrness Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-firewall/ipp2p/ChangeLog,v 1.21 2007/01/14 16:32:43 mrness Exp $
+
+*ipp2p-0.8.2-r2 (14 Jan 2007)
+
+ 14 Jan 2007; Alin Năstac <mrness@gentoo.org>
+ +files/ipp2p-0.8.2-matchsize.patch, +ipp2p-0.8.2-r2.ebuild:
+ Fix invalid size error.
*ipp2p-0.8.2-r1 (04 Jan 2007)
diff --git a/net-firewall/ipp2p/files/digest-ipp2p-0.8.2-r2 b/net-firewall/ipp2p/files/digest-ipp2p-0.8.2-r2
new file mode 100644
index 000000000000..14106f32db3b
--- /dev/null
+++ b/net-firewall/ipp2p/files/digest-ipp2p-0.8.2-r2
@@ -0,0 +1,3 @@
+MD5 9dd745830f302d70d0b728013c1d6a0c ipp2p-0.8.2.tar.gz 18976
+RMD160 097cd4175af3f97f3687f343087b8fe0af20ba38 ipp2p-0.8.2.tar.gz 18976
+SHA256 b265f5a1ce62de5a6cc60b9af22134a8d19b23e14b47a897057bca91188e0ee7 ipp2p-0.8.2.tar.gz 18976
diff --git a/net-firewall/ipp2p/files/ipp2p-0.8.2-matchsize.patch b/net-firewall/ipp2p/files/ipp2p-0.8.2-matchsize.patch
new file mode 100644
index 000000000000..8e065f1cbe29
--- /dev/null
+++ b/net-firewall/ipp2p/files/ipp2p-0.8.2-matchsize.patch
@@ -0,0 +1,28 @@
+diff -Nru ipp2p-0.8.2.orig/ipt_ipp2p.c ipp2p-0.8.2/ipt_ipp2p.c
+--- ipp2p-0.8.2.orig/ipt_ipp2p.c 2006-09-27 12:52:00.000000000 +0300
++++ ipp2p-0.8.2/ipt_ipp2p.c 2007-01-14 18:26:23.000000000 +0200
+@@ -843,15 +843,6 @@
+ }
+
+
+-// TODO: find out what this structure is for (scheme taken
+-// from kernel sources)
+-// content seems to have a length of 8 bytes
+-// (at least on my x86 machine)
+-struct ipp2p_match_info {
+- long int dunno_what_this_is_for;
+- long int i_also_dunno_what_this_is_for;
+-};
+-
+ static struct ipt_match ipp2p_match = {
+ #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,0)
+ { NULL, NULL },
+@@ -870,7 +861,7 @@
+ .name = "ipp2p",
+ .match = &match,
+ .family = AF_INET,
+- .matchsize = sizeof(struct ipp2p_match_info),
++ .matchsize = XT_ALIGN(sizeof(struct ipt_p2p_info)),
+ .checkentry = &checkentry,
+ .me = THIS_MODULE,
+ #endif
diff --git a/net-firewall/ipp2p/ipp2p-0.8.2-r2.ebuild b/net-firewall/ipp2p/ipp2p-0.8.2-r2.ebuild
new file mode 100644
index 000000000000..f8455fb5e355
--- /dev/null
+++ b/net-firewall/ipp2p/ipp2p-0.8.2-r2.ebuild
@@ -0,0 +1,67 @@
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-firewall/ipp2p/ipp2p-0.8.2-r2.ebuild,v 1.1 2007/01/14 16:32:43 mrness Exp $
+
+inherit linux-mod eutils
+
+DESCRIPTION="Netfilter module for dealing with P2P Applications."
+HOMEPAGE="http://www.ipp2p.org/index_en.html"
+SRC_URI="http://www.ipp2p.org/downloads/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~ppc64 ~sparc ~x86"
+IUSE=""
+
+RDEPEND="virtual/modutils
+ >=net-firewall/iptables-1.2.11"
+
+DEPEND="${RDEPEND}
+ virtual/linux-sources"
+
+pkg_setup() {
+ CONFIG_CHECK="NETFILTER"
+ NETFILTER_ERROR="Your kernel is not configured to support Netfilter."
+ MODULE_NAMES="ipt_ipp2p(${PN}:${S}:${S})"
+
+ linux-mod_pkg_setup
+}
+
+src_unpack() {
+ unpack ${A}
+
+ cd "${S}"
+ epatch "${FILESDIR}"/${P}-matchsize.patch
+ convert_to_m Makefile
+
+ sed -i -e "s/^IPTABLES_VERSION/#IPTABLES_VERSION/" Makefile
+ if has_version '>=net-firewall/iptables-1.3.6' ; then
+ sed -i -e "s/ld -shared/\$\(CC\) -shared/" Makefile
+ fi
+}
+
+src_compile() {
+ local IPTABLES_VERSION="$("${ROOT}"/sbin/iptables --version | cut -f2 -dv)"
+ emake CFLAGS="${CFLAGS}" CC="$(tc-getCC)" \
+ IPTABLES_SRC="${ROOT}/usr" IPTABLES_VERSION="${IPTABLES_VERSION}" libipt_ipp2p.so \
+ || die "Failed to build iptables module"
+
+ local myARCH="${ARCH}"
+ ARCH="$(tc-arch-kernel)"
+ emake KERNEL_SRC="${KV_DIR}" \
+ IPTABLES_SRC="${ROOT}/usr" IPTABLES_VERSION="${IPTABLES_VERSION}" \
+ || die "Failed to build kernel module."
+ ARCH="${myARCH}"
+}
+
+src_install() {
+ exeinto /$(get_libdir)/iptables
+ doexe libipt_ipp2p.so
+
+ dodoc README
+ linux-mod_src_install
+}
+
+pkg_postinst() {
+ linux-mod_pkg_postinst
+}