diff --git a/pkgs/by-name/sp/spotifyd/package.nix b/pkgs/by-name/sp/spotifyd/package.nix index 5dcf83303bfd..380d97266dc8 100644 --- a/pkgs/by-name/sp/spotifyd/package.nix +++ b/pkgs/by-name/sp/spotifyd/package.nix @@ -3,6 +3,7 @@ stdenv, config, alsa-lib, + apple-sdk_11, cmake, dbus, fetchFromGitHub, @@ -42,7 +43,8 @@ rustPlatform.buildRustPackage (finalAttrs: { ]; buildInputs = - lib.optionals stdenv.hostPlatform.isLinux [ openssl ] + lib.optionals stdenv.hostPlatform.isDarwin [ apple-sdk_11 ] + ++ lib.optionals stdenv.hostPlatform.isLinux [ openssl ] # The `dbus_mpris` feature works on other platforms, but only requires `dbus` on Linux ++ lib.optional (withMpris && stdenv.hostPlatform.isLinux) dbus ++ lib.optional (withALSA || withJack) alsa-lib @@ -61,6 +63,13 @@ rustPlatform.buildRustPackage (finalAttrs: { ++ lib.optional withPortAudio "portaudio_backend" ++ lib.optional withPulseAudio "pulseaudio_backend"; + checkFlags = lib.optionals stdenv.hostPlatform.isDarwin [ + # `assertion failed: shell.is_some()` + # Internally it's trying to query the user's shell through `dscl`. This is bad + # https://github.com/Spotifyd/spotifyd/blob/8777c67988508d3623d3f6b81c9379fb071ac7dd/src/utils.rs#L45-L47 + "--skip=utils::tests::test_ffi_discovery" + ]; + passthru = { tests.version = testers.testVersion { package = finalAttrs.finalPackage; }; updateScript = nix-update-script { };