Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 97 lines 1.9 kB view raw
1{ 2 mkDerivation, 3 stdenv, 4 lib, 5 fetchurl, 6 rpmextract, 7 autoPatchelfHook, 8 libuuid, 9 libXtst, 10 libXfixes, 11 glib, 12 gst_all_1, 13 alsa-lib, 14 freetype, 15 fontconfig, 16 libXext, 17 libGL, 18 libpng, 19 libXScrnSaver, 20 libxcb, 21 xorg, 22 libpulseaudio, 23 libdrm, 24}: 25mkDerivation rec { 26 pname = "hpmyroom"; 27 version = "12.13.0.0749"; 28 29 src = fetchurl { 30 url = "https://www.myroom.hpe.com/downloadfiles/${pname}-${version}.x86_64.rpm"; 31 sha256 = "sha256-Ff3j14rC2ZHhNJLPxvKn9Sxyv351HuHbggclwOuFfX4="; 32 }; 33 34 nativeBuildInputs = [ 35 rpmextract 36 autoPatchelfHook 37 ]; 38 39 buildInputs = [ 40 libuuid 41 libXtst 42 libXScrnSaver 43 libXfixes 44 alsa-lib 45 freetype 46 fontconfig 47 libXext 48 libGL 49 libpng 50 libxcb 51 libpulseaudio 52 libdrm 53 glib # For libgobject 54 stdenv.cc.cc # For libstdc++ 55 xorg.libX11 56 ] 57 ++ (with gst_all_1; [ 58 gstreamer 59 gst-plugins-base 60 ]); 61 62 unpackPhase = '' 63 rpmextract $src 64 ''; 65 66 installPhase = '' 67 runHook preInstall 68 69 mv usr $out 70 71 runHook postInstall 72 ''; 73 74 qtWrapperArgs = [ 75 "--prefix QT_XKB_CONFIG_ROOT : '${xorg.xkeyboardconfig}/share/X11/xkb'" 76 ]; 77 78 postFixup = '' 79 substituteInPlace $out/share/applications/HP-myroom.desktop \ 80 --replace /usr/bin/hpmyroom hpmyroom \ 81 --replace Icon=/usr/share/hpmyroom/Resources/MyRoom.png Icon=$out/share/hpmyroom/Resources/MyRoom.png 82 83 ln -s ${libpng}/lib/libpng.so $out/lib/hpmyroom/libpng15.so.15 84 ''; 85 86 meta = { 87 description = "Client for HPE's MyRoom web conferencing solution"; 88 maintainers = with lib.maintainers; [ johnazoidberg ]; 89 sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ]; 90 license = lib.licenses.unfree; 91 homepage = "https://myroom.hpe.com"; 92 # TODO: A Darwin binary is available upstream 93 platforms = [ "x86_64-linux" ]; 94 mainProgram = "hpmyroom"; 95 broken = true; # requires libpng15 96 }; 97}