about summary refs log tree commit diff
path: root/nixpkgs/pkgs/by-name/li/linien-gui/package.nix
blob: dd9ca7e4ca5834d165f34665f60251cde611b403 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
{ lib
, python3
, qt5
}:

python3.pkgs.buildPythonApplication rec {
  pname = "linien-gui";
  pyproject = true;

  inherit (python3.pkgs.linien-common) src version;

  sourceRoot = "${src.name}/linien-gui";

  nativeBuildInputs = with python3.pkgs; [
    setuptools
  ] ++ [
    qt5.wrapQtAppsHook
  ];

  # Makes qt-wayland appear in the qt paths injected by the wrapper - helps users
  # with `QT_QPA_PLATFORM=wayland` in their environment.
  buildInputs = [
    qt5.qtwayland
  ];

  propagatedBuildInputs = with python3.pkgs; [
    appdirs
    click
    pyqtgraph
    pyqt5
    superqt
    linien-client
  ];

  dontWrapQtApps = true;

  preFixup = ''
    makeWrapperArgs+=("''${qtWrapperArgs[@]}")
  '';

  meta = with lib; {
    description = "Graphical user interface of the Linien spectroscopy lock application";
    mainProgram = "linien";
    homepage = "https://github.com/linien-org/linien/tree/develop/linien-gui";
    license = licenses.gpl3Plus;
    maintainers = with maintainers; [ fsagbuya doronbehar ];
  };
}