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 12:17:32 +03:00
{
asio,
cmake,
curl,
fetchFromGitHub,
2024-07-16 09:34:29 +03:00
ffmpeg-headless,
2024-07-08 12:17:32 +03: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 15:40:32 +03:00
}:
2024-07-08 12:13:27 +03:00
let
2024-07-16 09:34:29 +03:00
ffmpeg = ffmpeg-headless;
2024-07-08 12:13:27 +03:00
in
2024-07-08 12:18:56 +03:00
stdenv.mkDerivation (finalAttrs: {
2020-04-05 15:40:32 +03:00
pname = "musikcube";
2024-07-16 09:34:29 +03:00
version = "3.0.4";
2020-04-05 15:40:32 +03:00
src = fetchFromGitHub {
owner = "clangen";
2024-07-08 12:18:56 +03:00
repo = "musikcube";
rev = finalAttrs.version;
2024-07-16 09:34:29 +03:00
hash = "sha512-ibpSrzbn2yGNgWnjAh4sG9ZRFImxjE2sq6tu9k0w1QAAr/OWSTwtaIuK71ClT6yt4HKyRk1KSaXa+/IzOHI6Kg==";
2020-04-05 15:40:32 +03:00
};
2024-07-08 12:17:32 +03:00
outputs = [
"out"
"dev"
];
2022-11-03 12:05:34 +03:00
2020-04-05 15:40:32 +03:00
nativeBuildInputs = [
cmake
pkg-config
];
2022-04-30 19:03:44 +03:00
2024-07-08 12:17:32 +03:00
buildInputs =
[
asio
curl
ffmpeg
gnutls
lame
libev
game-music-emu
libmicrohttpd
libopenmpt
mpg123
ncurses
portaudio
taglib
]
++ lib.optionals systemdSupport [ systemd ]
++ lib.optionals stdenv.isLinux [
alsa-lib
pulseaudio
]
++ lib.optionals stdenv.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 15:40:32 +03:00
2024-07-08 12:17:32 +03:00
cmakeFlags = [ "-DDISABLE_STRIP=true" ];
2020-05-27 04:16:18 +03:00
postFixup = lib.optionalString stdenv.isDarwin ''
2024-07-08 12:18:56 +03: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 13:02:32 +03:00
'';
2022-07-26 00:11:12 +03:00
meta = {
2023-04-22 09:01:40 +03:00
description = "Terminal-based music player, library, and streaming audio server";
2020-04-05 15:40:32 +03:00
homepage = "https://musikcube.com/";
2024-07-08 12:17:32 +03:00
maintainers = with lib.maintainers; [
aanderse
afh
];
2024-07-08 12:18:56 +03:00
mainProgram = "musikcube";
license = lib.licenses.bsd3;
platforms = lib.platforms.all;
2020-04-05 15:40:32 +03:00
};
2024-07-08 12:18:56 +03:00
})