Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
80 lines
1.6 KiB
Nix
80 lines
1.6 KiB
Nix
{
|
|
lib,
|
|
stdenv,
|
|
fetchFromGitHub,
|
|
installShellFiles,
|
|
cmake,
|
|
libxslt,
|
|
docbook_xsl_ns,
|
|
libsForQt5,
|
|
libusb1,
|
|
yaml-cpp,
|
|
}:
|
|
|
|
let
|
|
inherit (stdenv.hostPlatform) isLinux;
|
|
in
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "qdmr";
|
|
version = "0.12.3";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "hmatuschek";
|
|
repo = "qdmr";
|
|
rev = "v${version}";
|
|
hash = "sha256-rb59zbYpIziqXWTjTApWXnkcpRiAUIqPiInEJdsYd48=";
|
|
};
|
|
|
|
nativeBuildInputs = [
|
|
cmake
|
|
libxslt
|
|
libsForQt5.wrapQtAppsHook
|
|
installShellFiles
|
|
];
|
|
|
|
buildInputs = [
|
|
libusb1
|
|
libsForQt5.qtlocation
|
|
libsForQt5.qtserialport
|
|
libsForQt5.qttools
|
|
libsForQt5.qtbase
|
|
yaml-cpp
|
|
];
|
|
|
|
postPatch =
|
|
let
|
|
file = "doc/docbook_man.${if isLinux then "debian" else "macports"}.xsl";
|
|
path =
|
|
if isLinux then
|
|
"/usr/share/xml/docbook/stylesheet/docbook-xsl"
|
|
else
|
|
"/opt/local/share/xsl/docbook-xsl-nons";
|
|
in
|
|
''
|
|
substituteInPlace ${file} \
|
|
--replace ${path}/manpages/docbook\.xsl ${docbook_xsl_ns}/xml/xsl/docbook/manpages/docbook.xsl
|
|
'';
|
|
|
|
cmakeFlags = [
|
|
"-DBUILD_MAN=ON"
|
|
"-DCMAKE_INSTALL_FULL_MANDIR=share/man"
|
|
"-DINSTALL_UDEV_RULES=OFF"
|
|
];
|
|
|
|
postInstall = lib.optionalString isLinux ''
|
|
mkdir -p "$out/etc/udev/rules.d"
|
|
cp ${src}/dist/99-qdmr.rules $out/etc/udev/rules.d/
|
|
'';
|
|
|
|
doInstallCheck = true;
|
|
|
|
meta = {
|
|
description = "GUI application and command line tool for programming DMR radios";
|
|
homepage = "https://dm3mat.darc.de/qdmr/";
|
|
license = lib.licenses.gpl3Plus;
|
|
maintainers = with lib.maintainers; [ _0x4A6F ];
|
|
platforms = lib.platforms.linux ++ lib.platforms.darwin;
|
|
};
|
|
}
|