summaryrefslogtreecommitdiffstats
path: root/pkgs/by-name/ds/dsremote/package.nix
blob: 0ddc9f6350482f77b09954a47c98b55e3d101648 (plain)
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
{
  lib,
  stdenv,
  fetchFromGitLab,
  qt5,
}:
stdenv.mkDerivation {
  pname = "dsremote";
  version = "0-unstable-2025-07-07";

  src = fetchFromGitLab {
    owner = "Teuniz";
    repo = "DSRemote";
    rev = "b290debcfecd4fecf2069fb958bd43fe9e5ce5e1";
    hash = "sha256-7a13T8MwIFDhrXe7xqB84D6MwfTYs1gJj6VWs4JbzEM=";
  };

  nativeBuildInputs = [
    qt5.qmake
    qt5.wrapQtAppsHook
    qt5.qtbase
  ];

  hardeningDisable = [ "fortify" ];

  postPatch = ''
    substituteInPlace dsremote.pro \
      --replace-fail "/usr/" "$out/" \
      --replace-fail "/etc/" "$out/etc/"
  '';

  meta = {
    description = "Rigol DS1000Z remote control and waveform viewer";
    homepage = "https://www.teuniz.net/DSRemote";
    license = lib.licenses.gpl3Plus;
    platforms = lib.platforms.linux;
    maintainers = with lib.maintainers; [ mksafavi ];
    mainProgram = "dsremote";
  };
}