depot/third_party/nixpkgs/pkgs/applications/misc/qlcplus/default.nix
Default email bcb2f287e1 Project import generated by Copybara.
GitOrigin-RevId: d603719ec6e294f034936c0d0dc06f689d91b6c3
2024-06-20 20:27:18 +05:30

49 lines
1.4 KiB
Nix

{ lib, mkDerivation, fetchFromGitHub, qmake, pkg-config, udev
, qtmultimedia, qtscript, qtserialport, alsa-lib, ola, libftdi1, libusb-compat-0_1
, libsndfile, libmad
}:
mkDerivation rec {
pname = "qlcplus";
version = "4.13.1";
src = fetchFromGitHub {
owner = "mcallegari";
repo = "qlcplus";
rev = "QLC+_${version}";
sha256 = "sha256-AKmPxHOlMtea3q0NDULp3XfJ0JnYeF/iFUJw0dDOiio=";
};
nativeBuildInputs = [ qmake pkg-config ];
buildInputs = [
udev qtmultimedia qtscript qtserialport alsa-lib ola libftdi1 libusb-compat-0_1 libsndfile libmad
];
qmakeFlags = [ "INSTALLROOT=$(out)" ];
postPatch = ''
patchShebangs .
sed -i -e '/unix:!macx:INSTALLROOT += \/usr/d' \
-e "s@\$\$LIBSDIR/qt4/plugins@''${qtPluginPrefix}@" \
-e "s@/etc/udev/rules.d@''${out}/lib/udev/rules.d@" \
variables.pri
# Fix gcc-13 build failure by removing blanket -Werror.
fgrep Werror variables.pri
substituteInPlace variables.pri --replace-fail "QMAKE_CXXFLAGS += -Werror" ""
'';
enableParallelBuilding = true;
postInstall = ''
ln -sf $out/lib/*/libqlcplus* $out/lib
'';
meta = with lib; {
description = "Free and cross-platform software to control DMX or analog lighting systems like moving heads, dimmers, scanners etc";
maintainers = [ ];
license = licenses.asl20;
platforms = platforms.all;
homepage = "https://www.qlcplus.org/";
};
}