git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #56959 from ck3d/ghidra

initial ghidra-9.0

commit8f9e283f929120f2579f791c9ac9b0df7bd8d938 authorJörg Thalheim <Mic92@users.noreply.github.com> dateThu 14 Mar 2019, 15:54 (8 years ago) parent8c0abe72385d15
2 files changed+50
pkgs/tools/security/ghidra/default.nix+48 pkgs/top-level/all-packages.nix+2
pkgs/tools/security/ghidra/default.nixnew file+48
@@ -0,0 +1,48 @@
1+{ stdenv, fetchurl, unzip, lib, makeWrapper, autoPatchelfHook
2+, openjdk11, pam
3+}: let
4+
5+ pkg_path = "$out/lib/ghidra";
6+
7+in stdenv.mkDerivation {
8+
9+ name = "ghidra-9.0";
10+
11+ src = fetchurl {
12+ url = https://ghidra-sre.org/ghidra_9.0_PUBLIC_20190228.zip;
13+ sha256 = "3b65d29024b9decdbb1148b12fe87bcb7f3a6a56ff38475f5dc9dd1cfc7fd6b2";
14+ };
15+
16+ nativeBuildInputs = [
17+ makeWrapper
18+ autoPatchelfHook
19+ unzip
20+ ];
21+
22+ buildInputs = [
23+ stdenv.cc.cc.lib
24+ pam
25+ ];
26+
27+ dontStrip = true;
28+
29+ installPhase = ''
30+ mkdir -p "${pkg_path}"
31+ cp -a * "${pkg_path}"
32+ '';
33+
34+ postFixup = ''
35+ mkdir -p "$out/bin"
36+ makeWrapper "${pkg_path}/ghidraRun" "$out/bin/ghidra" \
37+ --prefix PATH : ${lib.makeBinPath [ openjdk11 ]}
38+ '';
39+
40+ meta = with lib; {
41+ description = "A software reverse engineering (SRE) suite of tools developed by NSA's Research Directorate in support of the Cybersecurity mission";
42+ homepage = "https://ghidra-sre.org/";
43+ platforms = [ "x86_64-linux" ];
44+ license = licenses.asl20;
45+ maintainers = [ maintainers.ck3d ];
46+ };
47+
48+}
pkgs/top-level/all-packages.nix+2
@@ -1453,6 +1453,8 @@ in
14531453
14541454 gh-ost = callPackage ../tools/misc/gh-ost { };
14551455
1456+ ghidra-bin = callPackage ../tools/security/ghidra { };
1457+
14561458 gif-for-cli = callPackage ../tools/misc/gif-for-cli { };
14571459
14581460 gist = callPackage ../tools/text/gist { };