Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{
2 lib,
3 stdenv,
4 fetchFromGitHub,
5 autoreconfHook,
6 gobject-introspection,
7 intltool,
8 wrapGAppsHook3,
9 procps,
10 python3,
11 readline,
12}:
13
14stdenv.mkDerivation rec {
15 pname = "scanmem";
16 version = "0.17";
17
18 src = fetchFromGitHub {
19 owner = "scanmem";
20 repo = "scanmem";
21 rev = "v${version}";
22 sha256 = "17p8sh0rj8yqz36ria5bp48c8523zzw3y9g8sbm2jwq7sc27i7s9";
23 };
24
25 patches = [
26 ./gettext-0.25.patch
27 ];
28
29 nativeBuildInputs = [
30 autoreconfHook
31 gobject-introspection
32 intltool
33 wrapGAppsHook3
34 ];
35 buildInputs = [
36 readline
37 python3
38 ];
39 configureFlags = [ "--enable-gui" ];
40
41 # we don't need to wrap the main executable, just the GUI
42 dontWrapGApps = true;
43
44 fixupPhase = ''
45 runHook preFixup
46
47 # replace the upstream launcher which does stupid things
48 # also add procps because it shells out to `ps` and expects it to be procps
49 makeWrapper ${python3}/bin/python3 $out/bin/gameconqueror \
50 "''${gappsWrapperArgs[@]}" \
51 --set PYTHONPATH "${python3.pkgs.makePythonPath [ python3.pkgs.pygobject3 ]}" \
52 --prefix PATH : "${procps}/bin" \
53 --add-flags "$out/share/gameconqueror/GameConqueror.py"
54
55 runHook postFixup
56 '';
57
58 meta = with lib; {
59 homepage = "https://github.com/scanmem/scanmem";
60 description = "Memory scanner for finding and poking addresses in executing processes";
61 maintainers = [ ];
62 platforms = platforms.linux;
63 license = licenses.gpl3;
64 };
65}