mirror of
https://github.com/pentoo/pentoo-overlay
synced 2026-05-06 03:20:43 +02:00
* Added pyrit for x86
This commit is contained in:
parent
1be84cab95
commit
ad99c0021f
3 changed files with 83 additions and 0 deletions
2
app-crypt/pyrit/Manifest
Normal file
2
app-crypt/pyrit/Manifest
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
AUX gentoo.patch 1834 RMD160 91769f58483d059fa9ca1223c3f314a44241033f SHA1 1c51b1e4518f5f969fa50b8956ecc3645fbe66a7 SHA256 54b80b091c732b9aedc166870554e9628fe1315622918dfa8de88fdd6db468c2
|
||||
EBUILD pyrit-9999.ebuild 966 RMD160 5d3871798711fdeae94f4e20b43cb5a957944e6d SHA1 32e19436d71be45024652479f46f83f295368e34 SHA256 38305ef96f65cc18793c64270b754506161004c8840ed7139062384f59a20532
|
||||
35
app-crypt/pyrit/files/gentoo.patch
Normal file
35
app-crypt/pyrit/files/gentoo.patch
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
Index: cpyrit/setup.py
|
||||
===================================================================
|
||||
--- cpyrit/setup.py (revision 66)
|
||||
+++ cpyrit/setup.py (working copy)
|
||||
@@ -20,8 +20,8 @@
|
||||
print "... done."
|
||||
libraries.extend(['cuda', 'cudart'])
|
||||
extra_compile_args.append('-DHAVE_CUDA')
|
||||
- include_dirs.append('/usr/local/cuda/include')
|
||||
- library_dirs.append('/usr/local/cuda/lib')
|
||||
+ include_dirs.append('/opt/cuda/include')
|
||||
+ library_dirs.append('/opt/cuda/lib')
|
||||
extra_objects.append('cpyrit_cuda.o')
|
||||
if 'HAVE_PADLOCK' in sys.argv:
|
||||
sys.argv.remove('HAVE_PADLOCK')
|
||||
@@ -38,14 +38,14 @@
|
||||
f.write(re.sub("W\[(.+?)\]", replace_eval, s))
|
||||
f.close()
|
||||
subprocess.check_call('mkdir -p brook',shell=True);
|
||||
- subprocess.check_call('/usr/local/amdbrook/sdk/bin/brcc -p cal -r -o brook/cpyrit cpyrit_stream_pp.br', shell=True);
|
||||
+ subprocess.check_call('brcc -p cal -r -o brook/cpyrit cpyrit_stream_pp.br', shell=True);
|
||||
print "... done."
|
||||
- subprocess.check_call('g++ -O2 -I/usr/local/amdbrook/sdk/include/ -Ibrook -o brook/cpyrit.o -c brook/cpyrit.cpp',shell=True);
|
||||
- subprocess.check_call('g++ -O2 -I/usr/local/amdbrook/sdk/include/ -Ibrook -c cpyrit_stream.cpp',shell=True);
|
||||
+ subprocess.check_call('g++ -O2 -I/opt/amdbrook/include/ -Ibrook -o brook/cpyrit.o -c brook/cpyrit.cpp',shell=True);
|
||||
+ subprocess.check_call('g++ -O2 -I/opt/amdbrook/include/ -Ibrook -c cpyrit_stream.cpp',shell=True);
|
||||
libraries.extend(['brook'])
|
||||
extra_compile_args.append('-DHAVE_STREAM')
|
||||
- include_dirs.append('/usr/local/amdbrook/sdk/include')
|
||||
- library_dirs.append('/usr/local/amdbrook/sdk/lib')
|
||||
+ include_dirs.append('/opt/amdbrook/include')
|
||||
+ library_dirs.append('/opt/amdbrook/lib')
|
||||
extra_objects.append('cpyrit_stream.o')
|
||||
extra_objects.append('brook/cpyrit.o')
|
||||
|
||||
46
app-crypt/pyrit/pyrit-9999.ebuild
Normal file
46
app-crypt/pyrit/pyrit-9999.ebuild
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
# Copyright 1999-2006 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
inherit eutils python distutils subversion
|
||||
DESCRIPTION="A GPU-based WPA-PSK and WPA2-PSK cracking tool"
|
||||
HOMEPAGE="http://code.google.com/p/pyrit/"
|
||||
ESVN_REPO_URI="http://pyrit.googlecode.com/svn/trunk/"
|
||||
|
||||
LICENSE="GPL-3"
|
||||
KEYWORDS="-*"
|
||||
IUSE="cuda stream"
|
||||
SLOT="0"
|
||||
DEPEND="stream? ( dev-util/amd-stream-sdk-bin )
|
||||
cuda? ( dev-util/nvidia-cuda-sdk )"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
src_compile() {
|
||||
MYOPTS="HAVE_PADLOCK"
|
||||
if use stream; then
|
||||
MYOPTS="${MYOPTS} HAVE_STREAM"
|
||||
fi
|
||||
if use cuda; then
|
||||
MYOPTS="${MYOPTS} HAVE_CUDA"
|
||||
fi
|
||||
|
||||
epatch "${FILESDIR}/gentoo.patch"
|
||||
cd cpyrit
|
||||
python setup.py ${MYOPTS} build || die "Build failed"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
python_version
|
||||
insinto /usr/lib/python"${PYVER}"/site-packages/
|
||||
doins cpyrit/build/lib.linux-i686-2.5/*
|
||||
dosbin pyrit.py
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
python_mod_optimize
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
python_mod_cleanup
|
||||
}
|
||||
|
||||
Loading…
Reference in a new issue