# Copyright 1999-2009 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ DESCRIPTION="Uncomplicated FireWall: A program used to manage a netfilter firewall." SRC_URI="http://launchpad.net/ufw/0.29/${PV}/+download/${PN}-${PV}.tar.gz" HOMEPAGE="http://launchpad.net/ufw" LICENSE="GPL-3" KEYWORDS="~amd64 ~x86" SLOT="0" IUSE="test" RDEPEND=">=dev-lang/python-2.5.0 >=net-firewall/iptables-1.4" DEPEND="" src_unpack() { unpack ${A} cd "${S}" sh tests/check-requirements } src_test() { cd "${S}" sh run_tests.sh } src_compile() { python setup.py install --root="${T}" cd "${T}" mkdir etc/init.d cp lib/ufw/ufw-init etc/init.d/ufw } src_install() { cp -R "${T}/etc" "${D}/" cp -R "${T}/lib" "${D}/" cp -R "${T}/usr" "${D}/" } pkg_postinst() { ewarn "Please Note: --*" elog "UFW requires several modules to be installed: " elog "addrtype, comment, hl (IPv6), limit, multiport, " elog "recent, state, conntrack ftp/irc, nat ftp/irc." elog "--> Make sure your kernel has these as modules. " elog "They MUST be modular!!!" ewarn "Also remember to add ufw to your boot sequence: " ewarn "-- #rc-update add ufw boot " }