mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-16 14:54:29 +01:00
jd-gui: Fix interpreter, add many missing deps, un-upx.
This commit is contained in:
parent
f873ba8cc8
commit
ad29479457
1 changed files with 24 additions and 6 deletions
|
@ -1,8 +1,22 @@
|
|||
{ stdenv, fetchurl, gtk2, atk, gdk_pixbuf, pango, makeWrapper }:
|
||||
{ stdenv, fetchurl, gtk2, atk, gdk_pixbuf, glib, pango, fontconfig, zlib, xorg, upx, patchelf }:
|
||||
|
||||
let
|
||||
dynlibPath = stdenv.lib.makeLibraryPath
|
||||
[ gtk2 atk gdk_pixbuf pango ];
|
||||
([ gtk2 atk gdk_pixbuf glib pango fontconfig zlib stdenv.cc.cc.lib ]
|
||||
++ (with xorg; [
|
||||
libX11
|
||||
libXext
|
||||
libXrender
|
||||
libXrandr
|
||||
libSM
|
||||
libXfixes
|
||||
libXdamage
|
||||
libXcursor
|
||||
libXinerama
|
||||
libXi
|
||||
libXcomposite
|
||||
libXxf86vm
|
||||
]));
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
name = "jd-gui-${version}";
|
||||
|
@ -13,14 +27,18 @@ stdenv.mkDerivation rec {
|
|||
sha256 = "0jrvzs2s836yvqi41c7fq0gfiwf187qg765b9r1il2bjc0mb3dqv";
|
||||
};
|
||||
|
||||
buildInputs = [ makeWrapper ];
|
||||
nativeBuildInputs = [ upx patchelf ];
|
||||
|
||||
phases = "unpackPhase installPhase";
|
||||
unpackPhase = "tar xf ${src}";
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin && mv jd-gui $out/bin
|
||||
wrapProgram $out/bin/jd-gui \
|
||||
--prefix LD_LIBRARY_PATH ":" "${dynlibPath}"
|
||||
mkdir -p $out/bin
|
||||
upx -d jd-gui -o $out/bin/jd-gui
|
||||
|
||||
patchelf \
|
||||
--set-interpreter $(cat ${stdenv.cc}/nix-support/dynamic-linker) \
|
||||
--set-rpath ${dynlibPath} \
|
||||
$out/bin/jd-gui
|
||||
'';
|
||||
|
||||
meta = {
|
||||
|
|
Loading…
Reference in a new issue