2021-02-05 17:12:51 +00:00
|
|
|
{ lib, stdenv, fetchurl
|
2021-05-03 20:48:10 +00:00
|
|
|
, cmake, docbook_xml_dtd_45, docbook_xsl, doxygen, graphviz-nox, pkg-config, qttools, wrapQtAppsHook
|
2024-04-21 15:54:59 +00:00
|
|
|
, alsa-lib, fluidsynth, libpulseaudio, qtbase, qtsvg, sonivox, qt5compat ? null
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
let
|
|
|
|
isQt6 = lib.versions.major qtbase.version == "6";
|
|
|
|
in
|
2020-04-24 23:36:52 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "drumstick";
|
2024-04-21 15:54:59 +00:00
|
|
|
version = "2.9.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "mirror://sourceforge/drumstick/${version}/${pname}-${version}.tar.bz2";
|
2024-04-21 15:54:59 +00:00
|
|
|
hash = "sha256-p0N8EeCtVEPCGzPwiRxPdI1XT5XQ5pcKYEDJXbYYTrM=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2020-11-12 23:50:31 +00:00
|
|
|
patches = [
|
|
|
|
./drumstick-plugins.patch
|
|
|
|
];
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace library/rt/backendmanager.cpp --subst-var out
|
|
|
|
'';
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
outputs = [ "out" "dev" "man" ];
|
|
|
|
|
2020-11-12 23:50:31 +00:00
|
|
|
nativeBuildInputs = [
|
2021-05-03 20:48:10 +00:00
|
|
|
cmake docbook_xml_dtd_45 docbook_xml_dtd_45 docbook_xsl doxygen graphviz-nox pkg-config qttools wrapQtAppsHook
|
2020-11-12 23:50:31 +00:00
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildInputs = [
|
2023-03-27 19:17:25 +00:00
|
|
|
alsa-lib fluidsynth libpulseaudio qtbase qtsvg sonivox
|
2024-04-21 15:54:59 +00:00
|
|
|
] ++ lib.optionals isQt6 [ qt5compat ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-05-03 20:48:10 +00:00
|
|
|
cmakeFlags = [
|
2024-04-21 15:54:59 +00:00
|
|
|
(lib.cmakeBool "USE_DBUS" true)
|
|
|
|
(lib.cmakeBool "USE_QT5" (!isQt6))
|
2021-05-03 20:48:10 +00:00
|
|
|
];
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2024-04-21 15:54:59 +00:00
|
|
|
description = "MIDI libraries for Qt/C++";
|
2022-03-05 16:20:37 +00:00
|
|
|
homepage = "https://drumstick.sourceforge.io/";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.gpl2Plus;
|
2024-04-21 15:54:59 +00:00
|
|
|
maintainers = with maintainers; [ wegank ];
|
2020-04-24 23:36:52 +00:00
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|