biglybt: 3.5.0.0 -> 3.6.0.0
[NixPkgs.git] / pkgs / applications / networking / instant-messengers / wavebox / default.nix
blob9578b11fdfa675c0567044e3c258dfa6cad026c5
1 { alsa-lib
2 , autoPatchelfHook
3 , fetchurl
4 , gtk3
5 , gtk4
6 , libnotify
7 , copyDesktopItems
8 , makeDesktopItem
9 , makeWrapper
10 , mesa
11 , nss
12 , lib
13 , libdrm
14 , qt5
15 , stdenv
16 , udev
17 , xdg-utils
18 , xorg
21 stdenv.mkDerivation rec {
22   pname = "wavebox";
23   version = "10.120.10-2";
25   src = fetchurl {
26     url = "https://download.wavebox.app/stable/linux/tar/Wavebox_${version}.tar.gz";
27     sha256 = "sha256-9kA3nJUNlNHbWYkIy0iEnWCrmIYTjULdMAGGnO4JCkg=";
28   };
30   # don't remove runtime deps
31   dontPatchELF = true;
32   # ignore optional Qt 6 shim
33   autoPatchelfIgnoreMissingDeps = [ "libQt6Widgets.so.6" "libQt6Gui.so.6" "libQt6Core.so.6" ];
35   nativeBuildInputs = [ autoPatchelfHook makeWrapper qt5.wrapQtAppsHook copyDesktopItems ];
37   buildInputs = with xorg; [
38     libXdmcp
39     libXScrnSaver
40     libXtst
41     libxshmfence
42     libXdamage
43   ] ++ [
44     alsa-lib
45     gtk3
46     nss
47     libdrm
48     mesa
49     gtk4
50     qt5.qtbase
51   ];
53   runtimeDependencies = [ (lib.getLib udev) libnotify gtk4 ];
55   desktopItems = [
56     (makeDesktopItem rec {
57       name = "Wavebox";
58       exec = "wavebox";
59       icon = "wavebox";
60       desktopName = name;
61       genericName = name;
62       categories = [ "Network" "WebBrowser" ];
63     })
64   ];
66   installPhase = ''
67     runHook preInstall
69     mkdir -p $out/bin $out/opt/wavebox
70     cp -r * $out/opt/wavebox
72     # provide icon for desktop item
73     mkdir -p $out/share/icons/hicolor/128x128/apps
74     ln -s $out/opt/wavebox/product_logo_128.png $out/share/icons/hicolor/128x128/apps/wavebox.png
76     runHook postInstall
77   '';
79   postFixup = ''
80     makeWrapper $out/opt/wavebox/wavebox-launcher $out/bin/wavebox \
81     --prefix PATH : ${xdg-utils}/bin
82   '';
84   passthru.updateScript = ./update.sh;
86   meta = with lib; {
87     description = "Wavebox messaging application";
88     homepage = "https://wavebox.io";
89     license = licenses.mpl20;
90     maintainers = with maintainers; [ rawkode ];
91     platforms = [ "x86_64-linux" ];
92     hydraPlatforms = [ ];
93   };