8 , desktopToDarwinBundle
16 , waylandSupport ? false
19 assert waylandSupport -> stdenv.hostPlatform.isLinux;
22 pname = "supersonic" + lib.optionalString waylandSupport "-wayland";
25 src = fetchFromGitHub {
29 hash = "sha256-hJLooKH5jketvPTfTtkNBQL1F9lzBEhDZuUXZRFEcWo=";
32 vendorHash = "sha256-wT1WvwUUAnMIKa+RlRDD2QGJpZMtoecQCxSJekM6PdM=";
37 ] ++ lib.optionals stdenv.hostPlatform.isDarwin [
41 # go-glfw doesn't support both X11 and Wayland in single build
42 tags = lib.optionals waylandSupport [ "wayland" ];
47 ] ++ lib.optionals stdenv.hostPlatform.isLinux [
50 ] ++ lib.optionals (stdenv.hostPlatform.isLinux && !waylandSupport) [
56 ] ++ lib.optionals (stdenv.hostPlatform.isLinux && waylandSupport) [
60 ] ++ lib.optionals stdenv.hostPlatform.isDarwin [
61 darwin.apple_sdk_11_0.frameworks.Cocoa
62 darwin.apple_sdk_11_0.frameworks.Kernel
63 darwin.apple_sdk_11_0.frameworks.OpenGL
64 darwin.apple_sdk_11_0.frameworks.UserNotifications
65 darwin.apple_sdk_11_0.frameworks.MediaPlayer
69 for dimension in 128 256 512;do
70 dimensions=''${dimension}x''${dimension}
71 mkdir -p $out/share/icons/hicolor/$dimensions/apps
72 cp res/appicon-$dimension.png $out/share/icons/hicolor/$dimensions/apps/${meta.mainProgram}.png
74 '' + lib.optionalString waylandSupport ''
75 mv $out/bin/supersonic $out/bin/${meta.mainProgram}
80 name = meta.mainProgram;
81 exec = meta.mainProgram;
82 icon = meta.mainProgram;
83 desktopName = "Supersonic" + lib.optionalString waylandSupport " (Wayland)";
84 genericName = "Subsonic Client";
85 comment = meta.description;
87 categories = [ "Audio" "AudioVideo" ];
92 mainProgram = "supersonic" + lib.optionalString waylandSupport "-wayland";
93 description = "A lightweight cross-platform desktop client for Subsonic music servers";
94 homepage = "https://github.com/dweymouth/supersonic";
95 platforms = platforms.linux ++ platforms.darwin;
96 license = licenses.gpl3Plus;
97 maintainers = with maintainers; [ zane sochotnicky ];