2022-06-16 17:23:12 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, fetchpatch, qtbase, qmake, wrapQtAppsHook, trousers }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
version = "0.8.1";
|
|
|
|
pname = "tpmmanager";
|
|
|
|
|
2022-03-30 09:31:56 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Rohde-Schwarz";
|
|
|
|
repo = "TPMManager";
|
|
|
|
rev = "v${version}";
|
2022-06-16 17:23:12 +00:00
|
|
|
sha256 = "sha256-UZYn4ssbvLpdB0DssT7MXqQZCu1KkLf/Bsb45Rvgm+E=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
patches = [
|
|
|
|
# build with Qt5
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/Rohde-Schwarz/TPMManager/commit/f62c0f2de2097af9b504c80d6193818e6e4ca84f.patch";
|
|
|
|
sha256 = "sha256-gMhDNN2UkX2lJf/oJEzOkCvF6+EGdIj9xwtXb1rCeys=";
|
|
|
|
})
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/Rohde-Schwarz/TPMManager/commit/c287a841ac6b057ed35799949211866b9f533561.patch";
|
|
|
|
sha256 = "sha256-2ZyUml8Q9bKQLVZWr18AzLt8VYLICXH9VDeq6B5Xfto=";
|
|
|
|
})
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
nativeBuildInputs = [ qmake wrapQtAppsHook ];
|
|
|
|
|
|
|
|
buildInputs = [ qtbase trousers ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
install -Dpm755 -D bin/tpmmanager $out/bin/tpmmanager
|
|
|
|
|
|
|
|
mkdir -p $out/share/applications
|
|
|
|
cat > $out/share/applications/tpmmanager.desktop <<EOF
|
|
|
|
[Desktop Entry]
|
|
|
|
Type=Application
|
|
|
|
Version=1.0
|
|
|
|
Name=tpmmanager
|
|
|
|
Comment=TPM manager
|
|
|
|
Exec=$out/bin/tpmmanager
|
|
|
|
Terminal=false
|
|
|
|
EOF
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
homepage = "https://projects.sirrix.com/trac/tpmmanager";
|
|
|
|
description = "Tool for managing the TPM";
|
2021-01-15 22:18:51 +00:00
|
|
|
license = lib.licenses.gpl2;
|
2022-07-14 12:49:19 +00:00
|
|
|
maintainers = with lib.maintainers; [ ];
|
2021-01-15 22:18:51 +00:00
|
|
|
platforms = with lib.platforms; linux;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|