2019-11-06 10:37:31 +01:00
|
|
|
{ stdenv, makeWrapper, fetchurl, dpkg, alsaLib, atk, cairo, cups, dbus, expat
|
|
|
|
, fontconfig, freetype, gdk-pixbuf, glib, gnome2, nspr, nss, gtk3, gtk2
|
|
|
|
, at-spi2-atk, gsettings-desktop-schemas, gobject-introspection, wrapGAppsHook
|
2018-05-03 00:08:30 +02:00
|
|
|
, libX11, libXScrnSaver, libXcomposite, libXcursor, libXdamage, libXext
|
|
|
|
, libXfixes, libXi, libXrandr, libXrender, libXtst, libxcb, nghttp2
|
2019-11-06 10:37:31 +01:00
|
|
|
, libudev0-shim, glibc, curl, openssl, autoPatchelfHook }:
|
2018-02-22 20:01:34 +01:00
|
|
|
|
|
|
|
let
|
2018-11-23 08:50:02 +01:00
|
|
|
runtimeLibs = stdenv.lib.makeLibraryPath [
|
|
|
|
curl
|
|
|
|
glibc
|
|
|
|
libudev0-shim
|
|
|
|
nghttp2
|
|
|
|
openssl
|
|
|
|
stdenv.cc.cc
|
2018-02-22 20:01:34 +01:00
|
|
|
];
|
|
|
|
in stdenv.mkDerivation rec {
|
2019-08-15 14:41:18 +02:00
|
|
|
pname = "insomnia";
|
2020-03-18 12:14:32 +01:00
|
|
|
version = "7.1.1";
|
2018-02-22 20:01:34 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
2019-11-06 10:37:31 +01:00
|
|
|
url =
|
|
|
|
"https://github.com/getinsomnia/insomnia/releases/download/v${version}/insomnia_${version}_amd64.deb";
|
2020-03-18 12:14:32 +01:00
|
|
|
sha256 = "0lg3j5pr2bkjq5rq035fwh4mgpqsja3ndp11zpcz85ni3nvhn657";
|
2018-02-22 20:01:34 +01:00
|
|
|
};
|
|
|
|
|
2019-11-06 10:37:31 +01:00
|
|
|
nativeBuildInputs =
|
|
|
|
[ autoPatchelfHook dpkg makeWrapper gobject-introspection wrapGAppsHook ];
|
2019-05-22 13:03:39 +02:00
|
|
|
|
2018-11-23 08:50:02 +01:00
|
|
|
buildInputs = [
|
|
|
|
alsaLib
|
|
|
|
at-spi2-atk
|
|
|
|
atk
|
|
|
|
cairo
|
|
|
|
cups
|
|
|
|
dbus
|
|
|
|
expat
|
|
|
|
fontconfig
|
|
|
|
freetype
|
2019-05-22 13:03:39 +02:00
|
|
|
gdk-pixbuf
|
2018-11-23 08:50:02 +01:00
|
|
|
glib
|
|
|
|
gnome2.GConf
|
|
|
|
gnome2.pango
|
|
|
|
gtk2
|
|
|
|
gtk3
|
2019-05-22 16:19:30 +02:00
|
|
|
gsettings-desktop-schemas
|
2018-11-23 08:50:02 +01:00
|
|
|
libX11
|
|
|
|
libXScrnSaver
|
|
|
|
libXcomposite
|
|
|
|
libXcursor
|
|
|
|
libXdamage
|
|
|
|
libXext
|
|
|
|
libXfixes
|
|
|
|
libXi
|
|
|
|
libXrandr
|
|
|
|
libXrender
|
|
|
|
libXtst
|
|
|
|
libxcb
|
|
|
|
nspr
|
|
|
|
nss
|
|
|
|
stdenv.cc.cc
|
|
|
|
];
|
2018-02-22 20:01:34 +01:00
|
|
|
|
2018-11-23 08:50:02 +01:00
|
|
|
dontBuild = true;
|
|
|
|
dontConfigure = true;
|
2018-02-22 20:01:34 +01:00
|
|
|
|
|
|
|
unpackPhase = "dpkg-deb -x $src .";
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/share/insomnia $out/lib $out/bin
|
|
|
|
|
|
|
|
mv usr/share/* $out/share/
|
|
|
|
mv opt/Insomnia/* $out/share/insomnia
|
|
|
|
mv $out/share/insomnia/*.so $out/lib/
|
|
|
|
|
|
|
|
ln -s $out/share/insomnia/insomnia $out/bin/insomnia
|
2019-04-19 07:37:17 +02:00
|
|
|
sed -i 's|\/opt\/Insomnia|'$out'/bin|g' $out/share/applications/insomnia.desktop
|
2018-02-22 20:01:34 +01:00
|
|
|
'';
|
|
|
|
|
|
|
|
preFixup = ''
|
|
|
|
wrapProgram "$out/bin/insomnia" --prefix LD_LIBRARY_PATH : ${runtimeLibs}
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2019-11-06 10:37:31 +01:00
|
|
|
homepage = "https://insomnia.rest/";
|
2018-02-22 20:01:34 +01:00
|
|
|
description = "The most intuitive cross-platform REST API Client";
|
2018-11-23 08:50:02 +01:00
|
|
|
license = licenses.mit;
|
2018-02-22 20:01:34 +01:00
|
|
|
platforms = [ "x86_64-linux" ];
|
2019-11-06 10:37:31 +01:00
|
|
|
maintainers = with maintainers; [ markus1189 babariviere ];
|
2018-02-22 20:01:34 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|