Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 68 lines 1.8 kB view raw
1{ 2 lib, 3 buildNpmPackage, 4 fetchFromGitLab, 5 makeDesktopItem, 6 copyDesktopItems, 7 makeWrapper, 8 electron, 9 rsync, 10}: 11 12buildNpmPackage rec { 13 pname = "fcast-receiver"; 14 version = "2.0.0"; 15 16 src = fetchFromGitLab { 17 domain = "gitlab.futo.org"; 18 owner = "videostreaming"; 19 repo = "fcast"; 20 rev = "4af2a537ef431918a5cf53b3ba18abe6b2d18c1e"; 21 hash = "sha256-Y3IyxYLGRi/fLh5A3ap+5x3Wny9WRplaYtBM3R3I8+U="; 22 }; 23 24 sourceRoot = "${src.name}/receivers/electron"; 25 26 makeCacheWritable = true; 27 28 npmDepsHash = "sha256-GXlqOukGWtt3KP+xsAiDsUG2Naej0v2RL7Vq3hqcavE="; 29 30 env.ELECTRON_SKIP_BINARY_DOWNLOAD = "1"; 31 32 desktopItems = [ 33 (makeDesktopItem { 34 name = "fcast-receiver"; 35 desktopName = "FCast Receiver"; 36 genericName = "Media Streaming Receiver"; 37 exec = "fcast-receiver"; 38 icon = "fcast-receiver"; 39 comment = "FCast Receiver, an open-source media streaming receiver"; 40 }) 41 ]; 42 43 nativeBuildInputs = [ 44 copyDesktopItems 45 makeWrapper 46 rsync 47 ]; 48 49 postInstall = '' 50 install -Dm644 assets/icons/app/icon.png $out/share/pixmaps/fcast-receiver.png 51 ln -s $out/lib/node_modules/fcast-receiver/package.json $out/lib/node_modules/fcast-receiver/dist/package.json 52 53 makeWrapper ${electron}/bin/electron $out/bin/fcast-receiver \ 54 --add-flags $out/lib/node_modules/fcast-receiver/dist/bundle.js 55 ''; 56 57 meta = { 58 description = "FCast Receiver, an open-source media streaming receiver"; 59 longDescription = '' 60 FCast Receiver is a receiver for an open-source media streaming protocol, FCast, an alternative to Chromecast and AirPlay. 61 ''; 62 homepage = "https://fcast.org/"; 63 license = lib.licenses.gpl3; 64 maintainers = with lib.maintainers; [ ymstnt ]; 65 mainProgram = "fcast-receiver"; 66 platforms = lib.platforms.linux; 67 }; 68}