mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-25 03:17:13 +00:00
108 lines
2.5 KiB
Nix
108 lines
2.5 KiB
Nix
{ stdenv, lib, libXcomposite, libgnome-keyring, makeWrapper, udev, curl, alsaLib
|
|
, libXfixes, atk, gtk2, libXrender, pango, gnome2, cairo, freetype, fontconfig
|
|
, libX11, libXi, libxcb, libXext, libXcursor, glib, libXScrnSaver, libxkbfile, libXtst
|
|
, nss, nspr, cups, fetchurl, expat, gdk_pixbuf, libXdamage, libXrandr, dbus
|
|
, dpkg, makeDesktopItem
|
|
}:
|
|
|
|
with stdenv.lib;
|
|
|
|
let
|
|
curlWithGnuTls = curl.override { gnutlsSupport = true; sslSupport = false; };
|
|
in
|
|
stdenv.mkDerivation rec {
|
|
name = "gitkraken-${version}";
|
|
version = "3.6.3";
|
|
|
|
src = fetchurl {
|
|
url = "https://release.gitkraken.com/linux/v${version}.deb";
|
|
sha256 = "1bl4zz4k9whv5q6bkf6hyki26dkjhm19rzx2800zzadbrdgs7iz4";
|
|
};
|
|
|
|
libPath = makeLibraryPath [
|
|
stdenv.cc.cc.lib
|
|
curlWithGnuTls
|
|
udev
|
|
libX11
|
|
libXext
|
|
libXcursor
|
|
libXi
|
|
libxcb
|
|
glib
|
|
libXScrnSaver
|
|
libxkbfile
|
|
libXtst
|
|
nss
|
|
nspr
|
|
cups
|
|
alsaLib
|
|
expat
|
|
gdk_pixbuf
|
|
dbus
|
|
libXdamage
|
|
libXrandr
|
|
atk
|
|
pango
|
|
cairo
|
|
freetype
|
|
fontconfig
|
|
libXcomposite
|
|
libXfixes
|
|
libXrender
|
|
gtk2
|
|
gnome2.GConf
|
|
libgnome-keyring
|
|
];
|
|
|
|
desktopItem = makeDesktopItem {
|
|
name = "gitkraken";
|
|
exec = "gitkraken";
|
|
icon = "gitkraken";
|
|
desktopName = "GitKraken";
|
|
genericName = "Git Client";
|
|
categories = "Application;Development;";
|
|
comment = "Graphical Git client from Axosoft";
|
|
};
|
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
buildInputs = [ dpkg ];
|
|
|
|
unpackCmd = ''
|
|
mkdir out
|
|
dpkg -x $curSrc out
|
|
'';
|
|
|
|
installPhase = ''
|
|
mkdir $out
|
|
pushd usr
|
|
pushd share
|
|
substituteInPlace applications/gitkraken.desktop \
|
|
--replace /usr/share/gitkraken $out/bin \
|
|
--replace Icon=app Icon=gitkraken
|
|
mv pixmaps/app.png pixmaps/gitkraken.png
|
|
popd
|
|
rm -rf bin/gitkraken share/lintian
|
|
cp -av share bin $out/
|
|
popd
|
|
ln -s $out/share/gitkraken/gitkraken $out/bin/gitkraken
|
|
'';
|
|
|
|
postFixup = ''
|
|
pushd $out/share/gitkraken
|
|
patchelf --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" gitkraken
|
|
|
|
for file in $(find . -type f \( -name \*.node -o -name gitkraken -o -name \*.so\* \) ); do
|
|
patchelf --set-rpath ${libPath}:$out/share/gitkraken $file || true
|
|
done
|
|
popd
|
|
'';
|
|
|
|
meta = {
|
|
homepage = https://www.gitkraken.com/;
|
|
description = "The downright luxurious and most popular Git client for Windows, Mac & Linux";
|
|
license = licenses.unfree;
|
|
platforms = platforms.linux;
|
|
maintainers = with maintainers; [ xnwdd ];
|
|
};
|
|
}
|