event-sim/nixos/programs/hidviz/default.nix
fly 02e1fad297 Initial commit
Signed-off-by: fly <merspieler@alwaysdata.com>
2024-05-31 11:47:34 +00:00

58 lines
1 KiB
Nix

{ lib
, fetchFromGitHub
, cmake
, pkg-config
, stdenv
# Package dependencies
, qt6
, libusb1
, protobuf
, asio
}:
stdenv.mkDerivation rec {
pname = "hidviz";
version = "0.2";
src = fetchFromGitHub {
owner = "hidviz";
repo = pname;
rev = "v${version}";
sha256 = "sha256-9crHFYVNNxJjwJojwqB8qdAGyr1Ieux9qC3m3rpIJw0=";
};
#patches = [ ./fix_webkit_webengine.patch ];
dontWrapQtApps = true;
preConfigure = ''
substituteInPlace libhidx/cmake_modules/Findasio.cmake --replace '/usr/include/asio' '${lib.getDev asio}/include/asio'
'';
# installPhase = ''
# runHook preInstall
# mkdir -p $out/include
# mv libatools.a $out
# cp -r * $out/include/
# '';
nativeBuildInputs = [
cmake
pkg-config
qt6.qttools
];
buildInputs = [
qt6.qtwebengine
libusb1
protobuf
asio
];
meta = with lib; {
homepage = "https://github.com/hidviz/hidviz";
description = "A GUI application for in-depth analysis of USB HID class devices.";
license = licenses.gpl3;
platforms = platforms.all;
maintainers = with maintainers; [];
};
}