From f6332a43c35387c4a2dea1746be5fd092890ae0e Mon Sep 17 00:00:00 2001 From: davidovski Date: Mon, 27 Jun 2022 23:09:07 +0100 Subject: added lf and iptables --- repo/iptables/iptables.xibuild | 59 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 repo/iptables/iptables.xibuild (limited to 'repo/iptables/iptables.xibuild') diff --git a/repo/iptables/iptables.xibuild b/repo/iptables/iptables.xibuild new file mode 100644 index 0000000..8d8cead --- /dev/null +++ b/repo/iptables/iptables.xibuild @@ -0,0 +1,59 @@ +#!/bin/sh + +NAME="iptables" +DESC="Linux kernel firewall, NAT and packet mangling tools" + +MAKEDEPS=" linux-headers libnftnl bison flex autoconf automake" + +PKG_VER=1.8.7 +SOURCE="https://www.netfilter.org/projects/iptables/files/iptables-$PKG_VER.tar.bz2" + +ADDITIONAL=" +ebtables.confd +ebtables.initd +ip6tables.confd +iptables.confd +iptables.initd +use-sh-iptables-apply.patch +" + +prepare () { + apply_patches +} + +build() { + export CFLAGS="$CFLAGS -D_GNU_SOURCE" + ./configure \ + --prefix=/usr \ + --mandir=/usr/share/man \ + --sbindir=/sbin \ + --sysconfdir=/etc \ + --without-kernel \ + --enable-devel \ + --enable-libipq \ + --enable-shared + + # do not use rpath + sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool + sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool + + make +} + +package() { + make -j1 install DESTDIR="$PKG_DEST" + + mkdir -p "$PKG_DEST"/usr/include/libiptc \ + "$PKG_DEST"/usr/lib \ + "$PKG_DEST"/var/lib/iptables \ + "$PKG_DEST"/etc/iptables + + install -m644 include/iptables.h include/ip6tables.h \ + "$PKG_DEST"/usr/include/ + install include/libiptc/*.h "$PKG_DEST"/usr/include/libiptc/ + + install -D -m755 "$BUILD_ROOT"/iptables.initd "$PKG_DEST"/etc/init.d/iptables + install -D -m644 "$BUILD_ROOT"/iptables.confd "$PKG_DEST"/etc/conf.d/iptables + install -D -m755 "$BUILD_ROOT"/ebtables.initd "$PKG_DEST"/etc/init.d/ebtables + install -D -m644 "$BUILD_ROOT"/ebtables.confd "$PKG_DEST"/etc/conf.d/ebtables +} -- cgit v1.2.1