nixpkgs/pkgs/by-name/mu/musikcube/package.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

109 lines
2.2 KiB
Nix
Raw Normal View History

2024-07-08 09:17:32 +00:00
{
asio,
cmake,
curl,
fetchFromGitHub,
2024-07-16 06:34:29 +00:00
ffmpeg-headless,
2024-07-08 09:17:32 +00:00
gnutls,
lame,
lib,
libev,
game-music-emu,
libmicrohttpd,
libopenmpt,
mpg123,
ncurses,
pkg-config,
portaudio,
stdenv,
taglib,
# Linux Dependencies
alsa-lib,
pipewireSupport ? !stdenv.hostPlatform.isDarwin,
pipewire,
pulseaudio,
sndioSupport ? true,
sndio,
systemd,
systemdSupport ? lib.meta.availableOn stdenv.hostPlatform systemd,
# Darwin Dependencies
darwin,
coreaudioSupport ? stdenv.hostPlatform.isDarwin,
2020-04-05 12:40:32 +00:00
}:
2024-07-08 09:13:27 +00:00
let
2024-07-16 06:34:29 +00:00
ffmpeg = ffmpeg-headless;
2024-07-08 09:13:27 +00:00
in
2024-07-08 09:18:56 +00:00
stdenv.mkDerivation (finalAttrs: {
2020-04-05 12:40:32 +00:00
pname = "musikcube";
2024-07-16 06:34:29 +00:00
version = "3.0.4";
2020-04-05 12:40:32 +00:00
src = fetchFromGitHub {
owner = "clangen";
2024-07-08 09:18:56 +00:00
repo = "musikcube";
rev = finalAttrs.version;
2024-07-16 06:34:29 +00:00
hash = "sha512-ibpSrzbn2yGNgWnjAh4sG9ZRFImxjE2sq6tu9k0w1QAAr/OWSTwtaIuK71ClT6yt4HKyRk1KSaXa+/IzOHI6Kg==";
2020-04-05 12:40:32 +00:00
};
2024-07-08 09:17:32 +00:00
outputs = [
"out"
"dev"
];
2022-11-03 09:05:34 +00:00
2020-04-05 12:40:32 +00:00
nativeBuildInputs = [
cmake
pkg-config
];
2022-04-30 16:03:44 +00:00
2024-07-08 09:17:32 +00:00
buildInputs =
[
asio
curl
ffmpeg
gnutls
lame
libev
game-music-emu
libmicrohttpd
libopenmpt
mpg123
ncurses
portaudio
taglib
]
++ lib.optionals systemdSupport [ systemd ]
++ lib.optionals stdenv.hostPlatform.isLinux [
alsa-lib
pulseaudio
]
++ lib.optionals stdenv.hostPlatform.isDarwin (
with darwin.apple_sdk.frameworks;
[
Cocoa
SystemConfiguration
]
)
++ lib.optionals coreaudioSupport (with darwin.apple_sdk.frameworks; [ CoreAudio ])
++ lib.optionals sndioSupport [ sndio ]
++ lib.optionals pipewireSupport [ pipewire ];
2020-04-05 12:40:32 +00:00
2024-07-08 09:17:32 +00:00
cmakeFlags = [ "-DDISABLE_STRIP=true" ];
2020-05-27 01:16:18 +00:00
postFixup = lib.optionalString stdenv.hostPlatform.isDarwin ''
2024-07-08 09:18:56 +00:00
install_name_tool -add_rpath $out/share/musikcube $out/share/musikcube/musikcube
install_name_tool -add_rpath $out/share/musikcube $out/share/musikcube/musikcubed
2022-07-26 10:02:32 +00:00
'';
2022-07-25 21:11:12 +00:00
meta = {
2023-04-22 06:01:40 +00:00
description = "Terminal-based music player, library, and streaming audio server";
2020-04-05 12:40:32 +00:00
homepage = "https://musikcube.com/";
2024-07-08 09:17:32 +00:00
maintainers = with lib.maintainers; [
aanderse
afh
];
2024-07-08 09:18:56 +00:00
mainProgram = "musikcube";
license = lib.licenses.bsd3;
platforms = lib.platforms.all;
2020-04-05 12:40:32 +00:00
};
2024-07-08 09:18:56 +00:00
})