2021-08-25 08:27:29 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
2020-12-25 13:55:36 +00:00
|
|
|
, fetchFromGitHub
|
2021-08-25 08:27:29 +00:00
|
|
|
, pkg-config
|
2022-01-25 03:21:06 +00:00
|
|
|
, which
|
2022-10-21 18:38:19 +00:00
|
|
|
, zip
|
|
|
|
, libicns
|
2024-02-29 20:09:43 +00:00
|
|
|
, botan2
|
2020-12-25 13:55:36 +00:00
|
|
|
, capstone
|
|
|
|
, jansson
|
2022-01-25 03:21:06 +00:00
|
|
|
, libunistring
|
2022-10-30 15:09:59 +00:00
|
|
|
, wxGTK32
|
2022-10-21 18:38:19 +00:00
|
|
|
, lua53Packages
|
|
|
|
, perlPackages
|
2022-10-30 15:09:59 +00:00
|
|
|
, gtk3
|
2021-08-25 08:27:29 +00:00
|
|
|
, Carbon
|
|
|
|
, Cocoa
|
|
|
|
, IOKit
|
2020-12-25 13:55:36 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "rehex";
|
2024-02-29 20:09:43 +00:00
|
|
|
version = "0.61.0";
|
2020-12-25 13:55:36 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "solemnwarning";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2024-02-29 20:09:43 +00:00
|
|
|
hash = "sha256-NBBBeTy15q6G30XR2PVd/xdIg41U2pWSPtqpdQX/+9o=";
|
2020-12-25 13:55:36 +00:00
|
|
|
};
|
|
|
|
|
2022-10-21 18:38:19 +00:00
|
|
|
nativeBuildInputs = [ pkg-config which zip ]
|
2021-08-25 08:27:29 +00:00
|
|
|
++ lib.optionals stdenv.isDarwin [ libicns ];
|
2020-12-25 13:55:36 +00:00
|
|
|
|
2024-02-29 20:09:43 +00:00
|
|
|
buildInputs = [ botan2 capstone jansson libunistring wxGTK32 ]
|
2022-10-21 18:38:19 +00:00
|
|
|
++ (with lua53Packages; [ lua busted ])
|
|
|
|
++ (with perlPackages; [ perl TemplateToolkit ])
|
2022-10-30 15:09:59 +00:00
|
|
|
++ lib.optionals stdenv.isLinux [ gtk3 ]
|
2022-10-21 18:38:19 +00:00
|
|
|
++ lib.optionals stdenv.isDarwin [ Carbon Cocoa IOKit ];
|
2020-12-25 13:55:36 +00:00
|
|
|
|
2022-01-25 03:21:06 +00:00
|
|
|
makeFlags = [ "prefix=${placeholder "out"}" ]
|
2021-08-25 08:27:29 +00:00
|
|
|
++ lib.optionals stdenv.isDarwin [ "-f Makefile.osx" ];
|
2020-12-25 13:55:36 +00:00
|
|
|
|
2022-01-25 03:21:06 +00:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-12-25 13:55:36 +00:00
|
|
|
description = "Reverse Engineers' Hex Editor";
|
|
|
|
longDescription = ''
|
|
|
|
A cross-platform (Windows, Linux, Mac) hex editor for reverse
|
|
|
|
engineering, and everything else.
|
|
|
|
'';
|
|
|
|
homepage = "https://github.com/solemnwarning/rehex";
|
2022-01-25 03:21:06 +00:00
|
|
|
changelog = "https://github.com/solemnwarning/rehex/raw/${version}/CHANGES.txt";
|
|
|
|
license = licenses.gpl2Only;
|
2022-10-21 18:38:19 +00:00
|
|
|
maintainers = with maintainers; [ markus1189 wegank ];
|
2020-12-25 13:55:36 +00:00
|
|
|
platforms = platforms.all;
|
2024-01-02 11:29:13 +00:00
|
|
|
mainProgram = "rehex";
|
2020-12-25 13:55:36 +00:00
|
|
|
};
|
|
|
|
}
|