summaryrefslogtreecommitdiff
path: root/net-wireless/wepcrackgui/wepcrackgui-9999.ebuild
blob: 509bce092e9622da7bfaa9ca459f0ebc5f5bd969 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

EAPI=3

inherit git mono multilib

DESCRIPTION="A GUI for aircrack-ng written in C#"
HOMEPAGE="http://sourceforge.net/projects/wepcrackgui/"
SRC_URI=""
EGIT_REPO_URI="git://wepcrackgui.git.sourceforge.net/gitroot/wepcrackgui/wepcrackgui"

LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64"
IUSE="debug gtk qt4"

DEPEND="dev-lang/mono
		gtk? ( dev-dotnet/gtk-sharp )
		qt4? ( kde-base/kdebindings-csharp )"
RDEPEND="${DEPEND}
		net-wireless/aircrack-ng
		net-wireless/mdk"

src_configure() {
	local _conf
	if use debug ; then
		_conf=DEBUG
	else
		_conf=RELEASE
	fi
	echo $_conf >> _conf
	./configure --prefix=/usr --config=$_conf
}

src_install() {
	local _rls
	if [[ $(cat _conf) == RELEASE ]]; then
		_rls=Release
	else
		_rls=Debug
	fi
	insinto /usr/$(get_libdir)/${PN}/
	doins WepCrack/bin/$_rls/Unbuffer.exe || die
	doins WepCrack/bin/$_rls/TestRun.exe || die
	doins WepCrack/bin/$_rls/WepCrack.dll || die
	doins WepCrack/bin/$_rls/WepCrackInterfaces.dll || die
	if use gtk ; then
		doins GWepCrackGui/bin/$_rls/GWepCrackGui.exe || die
		doins GWepCrackGui/bin/$_rls/WepCrackGtk.dll || die
		sed -i "s|./|/usr/$(get_libdir)/${PN}/|" GWepCrackGui/gwepcrack || die
		dobin GWepCrackGui/gwepcrack || die
	fi
	if use qt4 ; then
		doins QWepCrackGui/bin/$_rls/QWepCrackGui.exe || die
		doins QWepCrackGui/bin/$_rls/WepCrackQt.dll || die
		sed -i "s|./|/usr/$(get_libdir)/${PN}/|" QWepCrackGui/qwepcrack || die
		dobin QWepCrackGui/qwepcrack || die
	fi
	insinto /usr/share/${PN}/
	doins WepCrack/SSID.txt || die
	doins WepCrack/oui.txt || die
	insinto /usr/share/${PN}/wordlists
	doins WepCrack/wordlists/password.lst || die
	dodoc TODO README || die
}