2019-06-25 06:30:58 +00:00
|
|
|
{ stdenv, fetchurl, makeWrapper, wrapGAppsHook, autoPatchelfHook, dpkg
|
2019-05-22 11:03:39 +00:00
|
|
|
, xorg, atk, glib, pango, gdk-pixbuf, cairo, freetype, fontconfig, gtk3
|
2018-07-09 22:34:32 +00:00
|
|
|
, gnome2, dbus, nss, nspr, alsaLib, cups, expat, udev, libnotify, xdg_utils }:
|
2016-10-03 13:26:16 +00:00
|
|
|
|
2016-10-12 06:38:15 +00:00
|
|
|
let
|
2019-07-22 10:26:52 +00:00
|
|
|
version = "5.2.0";
|
2016-10-12 06:38:15 +00:00
|
|
|
in stdenv.mkDerivation rec {
|
2019-08-13 21:52:01 +00:00
|
|
|
pname = "franz";
|
|
|
|
inherit version;
|
2016-10-03 13:26:16 +00:00
|
|
|
src = fetchurl {
|
2019-01-11 22:17:46 +00:00
|
|
|
url = "https://github.com/meetfranz/franz/releases/download/v${version}/franz_${version}_amd64.deb";
|
2019-07-22 10:26:52 +00:00
|
|
|
sha256 = "1wlfd1ja38vbjy8y5pg95cpvf5ixkkq53m7v3c24q473jax4ynvg";
|
2016-10-03 13:26:16 +00:00
|
|
|
};
|
|
|
|
|
2017-04-23 18:10:35 +00:00
|
|
|
# don't remove runtime deps
|
|
|
|
dontPatchELF = true;
|
2016-10-03 13:26:16 +00:00
|
|
|
|
2019-06-25 06:30:58 +00:00
|
|
|
nativeBuildInputs = [ autoPatchelfHook makeWrapper wrapGAppsHook dpkg ];
|
2018-05-17 19:43:51 +00:00
|
|
|
buildInputs = (with xorg; [
|
|
|
|
libXi libXcursor libXdamage libXrandr libXcomposite libXext libXfixes
|
|
|
|
libXrender libX11 libXtst libXScrnSaver
|
|
|
|
]) ++ [
|
2019-05-22 11:03:39 +00:00
|
|
|
gtk3 atk glib pango gdk-pixbuf cairo freetype fontconfig dbus
|
2018-07-09 22:34:32 +00:00
|
|
|
gnome2.GConf nss nspr alsaLib cups expat stdenv.cc.cc
|
2018-05-17 19:43:51 +00:00
|
|
|
];
|
|
|
|
runtimeDependencies = [ udev.lib libnotify ];
|
2017-11-01 13:17:44 +00:00
|
|
|
|
2019-01-11 22:17:46 +00:00
|
|
|
unpackPhase = "dpkg-deb -x $src .";
|
2016-10-03 13:26:16 +00:00
|
|
|
|
|
|
|
installPhase = ''
|
2019-01-11 22:17:46 +00:00
|
|
|
mkdir -p $out/bin
|
|
|
|
cp -r opt $out
|
|
|
|
ln -s $out/opt/Franz/franz $out/bin
|
2016-10-12 06:38:15 +00:00
|
|
|
|
2017-04-23 18:10:35 +00:00
|
|
|
# provide desktop item and icon
|
2019-01-11 22:17:46 +00:00
|
|
|
cp -r usr/share $out
|
|
|
|
substituteInPlace $out/share/applications/franz.desktop \
|
|
|
|
--replace Exec=\"/opt/Franz/franz\" Exec=franz
|
2016-10-03 13:26:16 +00:00
|
|
|
'';
|
|
|
|
|
2019-06-25 06:30:58 +00:00
|
|
|
dontWrapGApps = true;
|
|
|
|
|
2016-11-19 13:39:13 +00:00
|
|
|
postFixup = ''
|
2019-06-25 06:30:58 +00:00
|
|
|
wrapProgram $out/opt/Franz/franz \
|
|
|
|
--prefix PATH : ${xdg_utils}/bin \
|
|
|
|
"''${gappsWrapperArgs[@]}"
|
2016-11-19 13:39:13 +00:00
|
|
|
'';
|
|
|
|
|
2016-10-03 13:26:16 +00:00
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "A free messaging app that combines chat & messaging services into one application";
|
2018-05-01 03:03:23 +00:00
|
|
|
homepage = https://meetfranz.com;
|
2016-10-03 13:26:16 +00:00
|
|
|
license = licenses.free;
|
2017-07-05 01:42:08 +00:00
|
|
|
maintainers = [ maintainers.gnidorah ];
|
2019-01-11 22:17:46 +00:00
|
|
|
platforms = ["x86_64-linux"];
|
2016-10-03 16:24:57 +00:00
|
|
|
hydraPlatforms = [];
|
2016-10-03 13:26:16 +00:00
|
|
|
};
|
|
|
|
}
|