summary refs log tree commit diff
path: root/pkgs/tools/security/keybase
diff options
context:
space:
mode:
authorworldofpeace <worldofpeace@users.noreply.github.com>2018-11-24 20:19:34 -0500
committerworldofpeace <worldofpeace@users.noreply.github.com>2018-11-25 16:44:34 -0500
commit02e9d06e5e54550c99814402bcebaedc261b6da2 (patch)
tree8d004aa8dd2e2583c8721f87eae2bfe67b138f01 /pkgs/tools/security/keybase
parented99c2266f76e93ed22e60337061208b9891afc4 (diff)
downloadnixpkgs-02e9d06e5e54550c99814402bcebaedc261b6da2.tar
nixpkgs-02e9d06e5e54550c99814402bcebaedc261b6da2.tar.gz
nixpkgs-02e9d06e5e54550c99814402bcebaedc261b6da2.tar.bz2
nixpkgs-02e9d06e5e54550c99814402bcebaedc261b6da2.tar.lz
nixpkgs-02e9d06e5e54550c99814402bcebaedc261b6da2.tar.xz
nixpkgs-02e9d06e5e54550c99814402bcebaedc261b6da2.tar.zst
nixpkgs-02e9d06e5e54550c99814402bcebaedc261b6da2.zip
keybase-gui: 2.7.0 -> 2.11.0
- Use `autoPatchelfHook`
- Don't explicitly set phases - Part of #28910
- Correct `version` by hoisting out the suffix
Diffstat (limited to 'pkgs/tools/security/keybase')
-rw-r--r--pkgs/tools/security/keybase/gui.nix55
1 files changed, 35 insertions, 20 deletions
diff --git a/pkgs/tools/security/keybase/gui.nix b/pkgs/tools/security/keybase/gui.nix
index 8831f26a42d..422ca4ac9cf 100644
--- a/pkgs/tools/security/keybase/gui.nix
+++ b/pkgs/tools/security/keybase/gui.nix
@@ -1,9 +1,26 @@
-{ stdenv, fetchurl, alsaLib, atk, cairo, cups
-, dbus, expat, fontconfig, freetype, gcc, gdk_pixbuf, glib, gnome2, gtk3
-, libnotify, nspr, nss, pango, systemd, xorg }:
+{ stdenv, fetchurl, alsaLib, atk, cairo, cups, udev, hicolor-icon-theme
+, dbus, expat, fontconfig, freetype, gdk_pixbuf, glib, gnome2, gtk3, gnome3
+, libnotify, nspr, nss, pango, systemd, xorg, autoPatchelfHook, wrapGAppsHook }:
 
 let
-  libPath = stdenv.lib.makeLibraryPath [
+  versionSuffix = "20181121195344.99751ac04f";
+in
+
+stdenv.mkDerivation rec {
+  name = "keybase-gui-${version}";
+  version = "2.11.0"; # Find latest version from https://prerelease.keybase.io/deb/dists/stable/main/binary-amd64/Packages
+
+  src = fetchurl {
+    url = "https://s3.amazonaws.com/prerelease.keybase.io/linux_binaries/deb/keybase_${version + "-" + versionSuffix}_amd64.deb";
+    sha256 = "1gh7brdw2p4xfdgc43vrmv0lvki2f3691mfh6lvksy1dv43yb8zl";
+  };
+
+  nativeBuildInputs = [
+    autoPatchelfHook
+    wrapGAppsHook
+  ];
+
+  buildInputs = [
     alsaLib
     atk
     cairo
@@ -12,10 +29,10 @@ let
     expat
     fontconfig
     freetype
-    gcc.cc
     gdk_pixbuf
     glib
     gnome2.GConf
+    gnome3.gsettings-desktop-schemas
     gtk3
     libnotify
     nspr
@@ -23,7 +40,7 @@ let
     pango
     systemd
     xorg.libX11
-    xorg.libxcb
+    xorg.libXScrnSaver
     xorg.libXcomposite
     xorg.libXcursor
     xorg.libXdamage
@@ -32,22 +49,23 @@ let
     xorg.libXi
     xorg.libXrandr
     xorg.libXrender
-    xorg.libXScrnSaver
     xorg.libXtst
+    xorg.libxcb
   ];
-in
-stdenv.mkDerivation rec {
-  name = "keybase-gui-${version}";
-  version = "2.7.0-20180926133747.0d62c866fc";
-  src = fetchurl {
-    url = "https://s3.amazonaws.com/prerelease.keybase.io/linux_binaries/deb/keybase_${version}_amd64.deb";
-    sha256 = "0a0ax3skfw398vcjl7822qp7160lbll1snwdqsa13dy8qrjl1byp";
-  };
-  phases = ["unpackPhase" "installPhase" "fixupPhase"];
+
+  runtimeDependencies = [
+    udev.lib
+  ];
+
+  dontBuild = true;
+  dontConfigure = true;
+  dontPatchElf = true;
+
   unpackPhase = ''
     ar xf $src
     tar xf data.tar.xz
   '';
+
   installPhase = ''
     mkdir -p $out/bin
     mv usr/share $out/share
@@ -83,13 +101,10 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/share/applications/keybase.desktop \
       --replace run_keybase $out/bin/keybase-gui
   '';
-  postFixup = ''
-    patchelf --set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) --set-rpath "${libPath}:\$ORIGIN" "$out/share/keybase/Keybase"
-  '';
 
   meta = with stdenv.lib; {
     homepage = https://www.keybase.io/;
-    description = "The Keybase official GUI.";
+    description = "The Keybase official GUI";
     platforms = platforms.linux;
     maintainers = with maintainers; [ puffnfresh np ];
     license = licenses.bsd3;