Merge pull request #43426 from tadfisher/zoom-us

zoom-us: fix runtime qt environment

authored by Joachim F and committed by GitHub bc487708 1727513d

+18 -13
+18 -13
pkgs/applications/networking/instant-messengers/zoom-us/default.nix
··· 1 - { stdenv, fetchurl, system, makeWrapper, makeDesktopItem, autoPatchelfHook 1 + { stdenv, fetchurl, system, makeWrapper, makeDesktopItem, autoPatchelfHook, env 2 2 # Dynamic libraries 3 3 , dbus, glib, libGL, libX11, libXfixes, libuuid, libxcb, qtbase, qtdeclarative 4 - , qtlocation, qtquickcontrols2, qtscript, qtwebchannel, qtwebengine 4 + , qtimageformats, qtlocation, qtquickcontrols, qtquickcontrols2, qtscript, qtsvg 5 + , qttools, qtwayland, qtwebchannel, qtwebengine 5 6 # Runtime 6 - , libjpeg_turbo, pciutils, procps, qtimageformats 7 + , coreutils, libjpeg_turbo, pciutils, procps, utillinux 7 8 , pulseaudioSupport ? true, libpulseaudio ? null 8 9 }: 9 10 10 11 assert pulseaudioSupport -> libpulseaudio != null; 11 12 12 13 let 13 - inherit (stdenv.lib) concatStringsSep makeBinPath optional optionalString; 14 + inherit (stdenv.lib) concatStringsSep makeBinPath makeLibraryPath 15 + makeSearchPath optional optionalString; 14 16 15 17 version = "2.2.128200.0702"; 16 18 srcs = { ··· 20 22 }; 21 23 }; 22 24 25 + qtDeps = [ 26 + qtbase qtdeclarative qtlocation qtquickcontrols qtquickcontrols2 qtscript 27 + qtwebchannel qtwebengine qtimageformats qtsvg qttools qtwayland 28 + ]; 29 + 30 + qtEnv = env "zoom-us-qt-${qtbase.version}" qtDeps; 31 + 23 32 in stdenv.mkDerivation { 24 33 name = "zoom-us-${version}"; 25 34 ··· 28 37 nativeBuildInputs = [ autoPatchelfHook makeWrapper ]; 29 38 30 39 buildInputs = [ 31 - dbus glib libGL libX11 libXfixes libuuid libxcb qtbase qtdeclarative 32 - qtlocation qtquickcontrols2 qtscript qtwebchannel qtwebengine 33 - libjpeg_turbo 34 - ]; 40 + dbus glib libGL libX11 libXfixes libuuid libxcb qtEnv libjpeg_turbo 41 + ] ++ qtDeps; 35 42 36 43 runtimeDependencies = optional pulseaudioSupport libpulseaudio; 37 44 ··· 46 53 "ZXMPPROOT.cer" 47 54 "ZoomLauncher" 48 55 "config-dump.sh" 49 - "qtdiag" 50 56 "timezones" 51 57 "translations" 52 58 "version.txt" ··· 67 73 # TODO Patch this somehow; tries to dlopen './libturbojpeg.so' from cwd 68 74 ln -s $(readlink -e "${libjpeg_turbo.out}/lib/libturbojpeg.so") $packagePath/libturbojpeg.so 69 75 76 + ln -s ${qtEnv}/bin/qt.conf $packagePath 77 + 70 78 makeWrapper $packagePath/zoom $out/bin/zoom-us \ 71 - --prefix PATH : "${makeBinPath [ pciutils procps ]}" \ 72 - --set QSG_INFO 1 \ 73 - --set QT_QPA_PLATFORM_PLUGIN_PATH ${qtbase.bin}/lib/qt-${qtbase.qtCompatVersion}/plugins/platforms \ 74 - --set QT_PLUGIN_PATH ${qtbase.bin}/${qtbase.qtPluginPrefix}:${qtimageformats}/${qtbase.qtPluginPrefix} \ 79 + --prefix PATH : "${makeBinPath [ coreutils glib.dev pciutils procps qttools.dev utillinux ]}" \ 75 80 --run "cd $packagePath" 76 81 77 82 runHook postInstall