summary refs log tree commit diff
path: root/pkgs/development/tools/database/sqlitebrowser/default.nix
blob: 054eabdb5e43953a21423ec6fe6070eb6c7cf9bd (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
{ mkDerivation, lib, fetchFromGitHub, cmake, antlr
, qtbase, qttools, qscintilla, sqlite }:

mkDerivation rec {
  version = "3.10.1";
  name = "sqlitebrowser-${version}";

  src = fetchFromGitHub {
    repo   = "sqlitebrowser";
    owner  = "sqlitebrowser";
    rev    = "v${version}";
    sha256 = "1brzam8yv6sbdmbqsp7vglhd6wlx49g2ap8llr271zrkld4k3kar";
  };

  buildInputs = [ qtbase qscintilla sqlite ];

  nativeBuildInputs = [ cmake antlr qttools ];

  enableParallelBuilding = true;

  # We have to patch out Test and PrintSupport to make this work with Qt 5.9
  # It can go when the application supports 5.9
  postPatch = ''
    substituteInPlace CMakeLists.txt \
      --replace Test         "" \
      --replace PrintSupport ""

    substituteInPlace libs/qcustomplot-source/CMakeLists.txt \
      --replace PrintSupport ""
  '';

  meta = with lib; {
    description = "DB Browser for SQLite";
    homepage = http://sqlitebrowser.org/;
    license = licenses.gpl3;
    maintainers = with maintainers; [ ];
    platforms = platforms.linux; # can only test on linux
  };
}