2024-01-02 11:29:13 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, boost
|
|
|
|
, fetchFromGitHub
|
|
|
|
, git
|
|
|
|
, makeWrapper
|
|
|
|
, meson
|
|
|
|
, ninja
|
|
|
|
, pkg-config
|
|
|
|
, python3
|
|
|
|
, qtbase
|
|
|
|
, qtcharts
|
|
|
|
, tuxclocker-plugins
|
2024-02-29 20:09:43 +00:00
|
|
|
, tuxclocker-without-unfree
|
2024-01-02 11:29:13 +00:00
|
|
|
, wrapQtAppsHook
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation (finalAttrs: {
|
|
|
|
pname = "tuxclocker";
|
2024-02-29 20:09:43 +00:00
|
|
|
version = "1.5.1";
|
2024-01-02 11:29:13 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Lurkki14";
|
|
|
|
repo = "tuxclocker";
|
|
|
|
fetchSubmodules = true;
|
2024-02-29 20:09:43 +00:00
|
|
|
rev = finalAttrs.version;
|
|
|
|
hash = "sha256-QLKLqTCpVMWxlDINa8Bo1vgCDcjwovoaXUs/PdMnxv0=";
|
2024-01-02 11:29:13 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
# Meson doesn't find boost without these
|
|
|
|
BOOST_INCLUDEDIR = "${lib.getDev boost}/include";
|
|
|
|
BOOST_LIBRARYDIR = "${lib.getLib boost}/lib";
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
git
|
|
|
|
makeWrapper
|
|
|
|
meson
|
|
|
|
ninja
|
|
|
|
pkg-config
|
|
|
|
wrapQtAppsHook
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
boost
|
|
|
|
qtbase
|
|
|
|
qtcharts
|
|
|
|
];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
wrapProgram "$out/bin/tuxclockerd" \
|
|
|
|
--prefix "TEXTDOMAINDIR" : "${tuxclocker-plugins}/share/locale" \
|
|
|
|
--prefix "TUXCLOCKER_PLUGIN_PATH" : "${tuxclocker-plugins}/lib/tuxclocker/plugins" \
|
|
|
|
--prefix "PYTHONPATH" : "${python3.pkgs.hwdata}/${python3.sitePackages}"
|
|
|
|
'';
|
|
|
|
|
|
|
|
mesonFlags = [
|
|
|
|
"-Dplugins=false"
|
|
|
|
];
|
|
|
|
|
2024-02-29 20:09:43 +00:00
|
|
|
passthru.tests = {
|
|
|
|
inherit tuxclocker-without-unfree;
|
|
|
|
};
|
|
|
|
|
2024-01-02 11:29:13 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Qt overclocking tool for GNU/Linux";
|
|
|
|
homepage = "https://github.com/Lurkki14/tuxclocker";
|
|
|
|
license = licenses.gpl3Only;
|
|
|
|
maintainers = with maintainers; [ lurkki ];
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
})
|