Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 126 lines 2.7 kB view raw
1{ 2 lib, 3 intltool, 4 mkDerivation, 5 installShellFiles, 6 pkg-config, 7 fetchFromGitHub, 8 dbus-glib, 9 desktop-file-utils, 10 hicolor-icon-theme, 11 pcre, 12 qtbase, 13 sqlite, 14 taglib, 15 zlib, 16 gtk3, 17 libpeas, 18 libcddb, 19 libcdio, 20 gst_all_1, 21 withGstPlugins ? true, 22 glyr, 23 withGlyr ? true, 24 liblastfmSF, 25 withLastfm ? true, 26 libcdio-paranoia, 27 withCD ? true, 28 keybinder3, 29 withKeybinder ? false, 30 libnotify, 31 withLibnotify ? false, 32 libsoup_2_4, 33 withLibsoup ? false, 34 libgudev, 35 withGudev ? false, # experimental 36 libmtp, 37 withMtp ? false, # experimental 38 xfce, 39 withXfce4ui ? false, 40 totem-pl-parser, 41 withTotemPlParser ? false, 42# , grilo, withGrilo ? false 43# , rygel, withRygel ? true 44}: 45 46assert withGlyr -> withLastfm; 47assert withLastfm -> withCD; 48 49mkDerivation rec { 50 pname = "pragha"; 51 version = "1.3.99.1"; 52 53 src = fetchFromGitHub { 54 owner = "pragha-music-player"; 55 repo = "pragha"; 56 rev = "v${version}"; 57 sha256 = "sha256-C4zh2NHqP4bwKMi5s+3AfEtKqxRlzL66H8OyNonGzxE="; 58 }; 59 60 nativeBuildInputs = [ 61 intltool 62 pkg-config 63 xfce.xfce4-dev-tools 64 desktop-file-utils 65 installShellFiles 66 ]; 67 68 buildInputs = 69 with gst_all_1; 70 [ 71 dbus-glib 72 gstreamer 73 gst-plugins-base 74 gtk3 75 hicolor-icon-theme 76 libpeas 77 pcre 78 qtbase 79 sqlite 80 taglib 81 zlib 82 ] 83 ++ lib.optionals withGstPlugins [ 84 gst-plugins-good 85 gst-plugins-bad 86 gst-plugins-ugly 87 ] 88 ++ lib.optionals withCD [ 89 libcddb 90 libcdio 91 libcdio-paranoia 92 ] 93 ++ lib.optional withGudev libgudev 94 ++ lib.optional withKeybinder keybinder3 95 ++ lib.optional withLibnotify libnotify 96 ++ lib.optional withLastfm liblastfmSF 97 ++ lib.optional withGlyr glyr 98 ++ lib.optional withLibsoup libsoup_2_4 99 ++ lib.optional withMtp libmtp 100 ++ lib.optional withXfce4ui xfce.libxfce4ui 101 ++ lib.optional withTotemPlParser totem-pl-parser 102 # ++ lib.optional withGrilo grilo 103 # ++ lib.optional withRygel rygel 104 ; 105 106 CFLAGS = [ "-DHAVE_PARANOIA_NEW_INCLUDES" ]; 107 108 env.NIX_CFLAGS_COMPILE = "-I${lib.getDev gst_all_1.gst-plugins-base}/include/gstreamer-1.0"; 109 110 postInstall = '' 111 qtWrapperArgs+=(--prefix GST_PLUGIN_SYSTEM_PATH_1_0 : "$GST_PLUGIN_SYSTEM_PATH_1_0") 112 113 install -m 444 data/${pname}.desktop $out/share/applications 114 install -d $out/share/pixmaps 115 installManPage data/${pname}.1 116 ''; 117 118 meta = with lib; { 119 description = "Lightweight GTK+ music manager - fork of Consonance Music Manager"; 120 mainProgram = "pragha"; 121 homepage = "https://pragha-music-player.github.io/"; 122 license = licenses.gpl3Plus; 123 maintainers = with maintainers; [ mbaeten ]; 124 platforms = platforms.unix; 125 }; 126}