python313Packages.pyais: 2.8.3 -> 2.8.4 (#378375)
[NixPkgs.git] / pkgs / tools / graphics / hobbits / default.nix
blob6a429f9e7065667a17ec61c9b9eda26141b6a532
2   lib,
3   stdenv,
4   mkDerivation,
5   fetchFromGitHub,
6   cmake,
7   pkg-config,
8   pffft,
9   libpcap,
10   libusb1,
11   python3,
12   wrapQtAppsHook,
15 stdenv.mkDerivation rec {
16   pname = "hobbits";
17   version = "0.54.1";
19   src = fetchFromGitHub {
20     owner = "Mahlet-Inc";
21     repo = "hobbits";
22     rev = "v${version}";
23     hash = "sha256-SbSuw5e2ll/wU5UBV0MOlvCXb4rvPtsE4l8XzRbBiLI=";
24   };
26   postPatch = ''
27     substituteInPlace src/hobbits-core/settingsdata.cpp \
28       --replace "pythonHome = \"/usr\"" "pythonHome = \"${python3}\""
29     substituteInPlace cmake/gitversion.cmake \
30       --replace "[Mystery Build]" "${version}"
31   '';
33   buildInputs = [
34     pffft
35     libpcap
36     libusb1
37     python3
38   ];
40   nativeBuildInputs = [
41     cmake
42     pkg-config
43     wrapQtAppsHook
44   ];
46   cmakeFlags = [ "-DUSE_SYSTEM_PFFFT=ON" ];
48   env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.hostPlatform.isAarch64 "-Wno-error=narrowing";
50   meta = with lib; {
51     description = "Multi-platform GUI for bit-based analysis, processing, and visualization";
52     homepage = "https://github.com/Mahlet-Inc/hobbits";
53     license = licenses.mit;
54     maintainers = with maintainers; [ sikmir ];
55     platforms = platforms.linux;
56   };