# Copyright 1999-2010 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit eutils toolchain-funcs DESCRIPTION="w3af audit tools" HOMEPAGE="http://w3af.sourceforge.net/" SRC_URI="mirror://sourceforge/${PN}/${PN}-1.0-rc3.tar.bz2" LICENSE="GPL-2" SLOT="0" KEYWORDS="amd64 x86" IUSE="gtk doc" DEPEND="dev-python/pyopenssl dev-python/pysqlite dev-python/soappy >=dev-python/fpconst-0.7.2 dev-python/beautifulsoup dev-python/nltk dev-python/pyPdf gtk? ( media-gfx/graphviz \ >dev-python/pygtk-2.0 )" RDEPEND="${DEPEND}" S=${WORKDIR}/${PN} src_unpack() { unpack ${A} } src_compile(){ if ! has_version "dev-lang/python[sqlite]"; then die "Please rebuild dev-lang/python with USE=sqlite" fi for i in BeautifulSoup.py fpconst-0.7.2 jsonpy nltk nltk_contrib pygoogle pyPdf scapy SOAPpy yaml; do rm -r "${S}"/extlib/$i done } src_install() { dodir /usr/lib/w3af insinto /usr/lib/w3af doins -r * fowners root:0 /usr/lib/w3af dosym /usr/lib/w3af/w3af_gui usr/bin/w3af_gui dosym /usr/lib/w3af/w3af_console usr/bin/w3af_console chmod +x "${D}"/usr/lib/w3af/w3af_gui chmod +x "${D}"/usr/lib/w3af/w3af_console #use flag doc is here because doc is bigger than 3 Mb if use doc then dodir /usr/share/doc/w3af mv "${D}"/usr/lib/w3af/readme "${D}"/usr/share/doc/w3af else rm -r "${D}"/usr/lib/w3af/readme fi }