at 18.03-beta 29 lines 903 B view raw
1{ stdenv, fetchurl, patchelf }: 2 3stdenv.mkDerivation rec { 4 name = "ssdeep-${version}"; 5 version = "2.13"; 6 7 src = fetchurl { 8 url = "mirror://sourceforge/ssdeep/${name}.tar.gz"; 9 sha256 = "1igqy0j7jrklb8fdlrm6ald4cyl1fda5ipfl8crzyl6bax2ajk3f"; 10 }; 11 12 # Hack to avoid TMPDIR in RPATHs. 13 preFixup = ''rm -rf "$(pwd)" ''; 14 15 # For some reason (probably a build system bug), the binary isn't 16 # properly linked to $out/lib to find libfuzzy.so 17 postFixup = stdenv.lib.optionalString (!stdenv.isDarwin) '' 18 rp=$(patchelf --print-rpath $out/bin/ssdeep) 19 patchelf --set-rpath $rp:$out/lib $out/bin/ssdeep 20 ''; 21 22 meta = { 23 description = "A program for calculating fuzzy hashes"; 24 homepage = "http://www.ssdeep.sf.net"; 25 license = stdenv.lib.licenses.gpl2; 26 platforms = stdenv.lib.platforms.unix; 27 maintainers = [ stdenv.lib.maintainers.thoughtpolice ]; 28 }; 29}