about summary refs log tree commit diff
path: root/pkgs/misc/opcua-client-gui/default.nix
blob: 22669706036597b0024ffd4593dc38f58ae0c430 (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
49
50
51
52
53
54
55
56
57
58
59
60
61
{ lib
, stdenv
, python3Packages
, fetchFromGitHub
, makeDesktopItem
, copyDesktopItems
, desktopToDarwinBundle
, wrapQtAppsHook
}:

python3Packages.buildPythonApplication rec {
  pname = "opcua-client-gui";
  version = "0.8.4";

  src = fetchFromGitHub {
    owner = "FreeOpcUa";
    repo = "opcua-client-gui";
    rev = version;
    hash = "sha256-0BH1Txr3z4a7iFcsfnovmBUreXMvIX2zpZa8QivQVx8=";
  };

  nativeBuildInputs = [ copyDesktopItems wrapQtAppsHook ]
    ++ lib.optionals stdenv.hostPlatform.isDarwin [ desktopToDarwinBundle ];

  makeWrapperArgs = [
    "\${qtWrapperArgs[@]}"
  ];

  propagatedBuildInputs = with python3Packages; [
    pyqt5
    asyncua
    opcua-widgets
    numpy
    pyqtgraph
  ];

  #This test uses a deprecated libarby, when updating the package check if the test was updated as well
  doCheck = false;

  desktopItems = [
    (makeDesktopItem {
      name = "opcua-client";
      exec = "opcua-client";
      comment = "OPC UA Client";
      type = "Application";
      #no icon because the app dosn't have one
      desktopName = "opcua-client";
      terminal = false;
      categories = [ "Utility" ];
    })
  ];

  meta = with lib; {
    description = "OPC UA GUI Client";
    homepage = "https://github.com/FreeOpcUa/opcua-client-gui";
    platforms = platforms.unix;
    license = licenses.gpl3Only;
    maintainers = [ ];
    mainProgram = "opcua-client";
  };
}