summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2021-05-16 03:47:31 +0000
committerRick Farina <zerochaos@gentoo.org>2021-05-18 11:12:04 -0400
commitc498c9ba984eabf60d4cbf3a1064353a3804db19 (patch)
treecd2eee9ecc050e5107142a2472d3ff95f0a4eb91 /app-crypt/hashcat/hashcat-9999.ebuild
parentdev-libs/roct-thunk-interface: Version bump to 4.2 (diff)
downloadgentoo-c498c9ba984eabf60d4cbf3a1064353a3804db19.tar.gz
gentoo-c498c9ba984eabf60d4cbf3a1064353a3804db19.tar.bz2
gentoo-c498c9ba984eabf60d4cbf3a1064353a3804db19.zip
app-crypt/hashcat: add 6.2.1
* Bump to 6.2.1 * Respect CC, CXX, AR * Style changes to make it easier to read argument lists to (e)make * Ostensibly support prefix * Debundling ** Use system zlib (and minizip) ** Use system unrar ** Cannot use system lzma for now as the ebuild doesn't install all of the necessary files Closes: https://bugs.gentoo.org/745327 Signed-off-by: Sam James <sam@gentoo.org> Signed-off-by: Rick Farina <zerochaos@gentoo.org>
Diffstat (limited to 'app-crypt/hashcat/hashcat-9999.ebuild')
-rw-r--r--app-crypt/hashcat/hashcat-9999.ebuild53
1 files changed, 44 insertions, 9 deletions
diff --git a/app-crypt/hashcat/hashcat-9999.ebuild b/app-crypt/hashcat/hashcat-9999.ebuild
index 4bcf042ea7e7..dc3813e63de6 100644
--- a/app-crypt/hashcat/hashcat-9999.ebuild
+++ b/app-crypt/hashcat/hashcat-9999.ebuild
@@ -3,7 +3,7 @@
EAPI=7
-inherit pax-utils multilib
+inherit pax-utils toolchain-funcs
DESCRIPTION="World's fastest and most advanced password recovery utility"
HOMEPAGE="https://github.com/hashcat/hashcat"
@@ -20,6 +20,8 @@ fi
IUSE="brain video_cards_nvidia"
DEPEND="
app-arch/lzma
+ app-arch/unrar
+ sys-libs/zlib[minizip]
brain? ( dev-libs/xxhash )
video_cards_nvidia? ( >x11-drivers/nvidia-drivers-440.64
|| ( dev-util/nvidia-cuda-toolkit
@@ -29,24 +31,46 @@ DEPEND="
RDEPEND="${DEPEND}"
src_prepare() {
- #remove bundled stuff
+ # remove bundled stuff
rm -r deps/OpenCL-Headers || die "Failed to remove bundled OpenCL Headers"
rm -r deps/xxHash || die "Failed to remove bundled xxHash"
+ # TODO: Gentoo's app-arch/lzma doesn't install the needed files
#rm -r deps/LZMA-SDK || die "Failed to remove bundled LZMA-SDK"
#rm -r deps || die "Failed to remove bundled deps"
- #do not strip
+
+ # do not strip
sed -i "/LFLAGS += -s/d" src/Makefile
- #do not add random CFLAGS
+ # do not add random CFLAGS
sed -i "s/-O2//" src/Makefile || die
- sed -i "#LZMA_SDK_INCLUDE#d" src/Makefile || die
- export PREFIX=/usr
+ #sed -i "#LZMA_SDK_INCLUDE#d" src/Makefile || die
+ # respect CC, CXX, AR
+ sed -i \
+ -e 's/:= gcc/:= $(CC)/' \
+ -e 's/:= g++/:= $(CXX)/' \
+ -e 's/:= ar/:= $(AR)/' \
+ src/Makefile || die
+
+ export PREFIX="${EPREFIX}"/usr
export LIBRARY_FOLDER="/usr/$(get_libdir)"
- export DOCUMENT_FOLDER="/usr/share/doc/${P}"
+ export DOCUMENT_FOLDER="/usr/share/doc/${PF}"
+
default
}
src_compile() {
- emake SHARED=1 PRODUCTION=1 ENABLE_BRAIN=$(usex brain 1 0) USE_SYSTEM_LZMA=0 USE_SYSTEM_OPENCL=1 USE_SYSTEM_XXHASH=1 VERSION_PURE="${PV}"
+ tc-export CC CXX AR
+
+ emake \
+ SHARED=1 \
+ PRODUCTION=1 \
+ ENABLE_BRAIN=$(usex brain 1 0) \
+ USE_SYSTEM_LZMA=0 \
+ USE_SYSTEM_OPENCL=1 \
+ USE_SYSTEM_UNRAR=1 \
+ USE_SYSTEM_ZLIB=1 \
+ USE_SYSTEM_XXHASH=1 \
+ VERSION_PURE="${PV}"
+
pax-mark -mr hashcat
}
@@ -68,5 +92,16 @@ src_test() {
}
src_install() {
- emake DESTDIR="${ED}" SHARED=1 PRODUCTION=1 ENABLE_BRAIN=$(usex brain 1 0) USE_SYSTEM_LZMA=0 USE_SYSTEM_OPENCL=1 USE_SYSTEM_XXHASH=1 VERSION_PURE="${PV}" install
+ emake \
+ DESTDIR="${ED}" \
+ SHARED=1 \
+ PRODUCTION=1 \
+ ENABLE_BRAIN=$(usex brain 1 0) \
+ USE_SYSTEM_LZMA=0 \
+ USE_SYSTEM_OPENCL=1 \
+ USE_SYSTEM_UNRAR=1 \
+ USE_SYSTEM_ZLIB=1 \
+ USE_SYSTEM_XXHASH=1 \
+ VERSION_PURE="${PV}" \
+ install
}