blob: d7b519b04c347ff59ddec9e9be9b19d551d1f8d0 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
|
{ stdenv
, fetchurl
, lib
, autoPatchelfHook
, wrapQtAppsHook
, gmpxx
, gnustep
, libbsd
, libffi_3_3
, ncurses6
}:
stdenv.mkDerivation rec {
pname = "hopper";
version = "5.5.3";
rev = "v4";
src = fetchurl {
url = "https://d2ap6ypl1xbe4k.cloudfront.net/Hopper-${rev}-${version}-Linux-demo.pkg.tar.xz";
hash = "sha256-xq9ZVg1leHm/tq6LYyQLa8p5dDwBd64Jt92uMoE0z58=";
};
sourceRoot = ".";
nativeBuildInputs = [
autoPatchelfHook
wrapQtAppsHook
];
buildInputs = [
gnustep.libobjc
libbsd
libffi_3_3
ncurses6
];
installPhase = ''
runHook preInstall
mkdir -p $out/bin
mkdir -p $out/lib
mkdir -p $out/share
cp $sourceRoot/opt/hopper-${rev}/bin/Hopper $out/bin/hopper
cp \
--archive \
$sourceRoot/opt/hopper-${rev}/lib/libBlocksRuntime.so* \
$sourceRoot/opt/hopper-${rev}/lib/libdispatch.so* \
$sourceRoot/opt/hopper-${rev}/lib/libgnustep-base.so* \
$sourceRoot/opt/hopper-${rev}/lib/libHopperCore.so* \
$sourceRoot/opt/hopper-${rev}/lib/libkqueue.so* \
$sourceRoot/opt/hopper-${rev}/lib/libobjcxx.so* \
$sourceRoot/opt/hopper-${rev}/lib/libpthread_workqueue.so* \
$out/lib
cp -r $sourceRoot/usr/share $out
runHook postInstall
'';
postFixup = ''
substituteInPlace "$out/share/applications/hopper-${rev}.desktop" \
--replace "Exec=/opt/hopper-${rev}/bin/Hopper" "Exec=$out/bin/hopper"
'';
meta = with lib; {
homepage = "https://www.hopperapp.com/index.html";
description = "A macOS and Linux Disassembler";
license = licenses.unfree;
maintainers = with maintainers; [
luis
Enteee
];
platforms = platforms.linux;
};
}
|