nixpkgs/pkgs/data/documentation/zeal/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

65 lines
1.6 KiB
Nix
Raw Normal View History

{ lib
, stdenv
, fetchFromGitHub
, cmake
, extra-cmake-modules
, pkg-config
, qtbase
, qtimageformats
, qtwebengine
, qtx11extras ? null # qt5 only
, libarchive
, libXdmcp
, libpthreadstubs
, wrapQtAppsHook
, xcbutilkeysyms
}:
2015-01-28 00:02:50 +01:00
let
isQt5 = lib.versions.major qtbase.version == "5";
in stdenv.mkDerivation rec {
pname = "zeal";
version = "0.6.20221022";
2015-01-28 00:02:50 +01:00
src = fetchFromGitHub {
2020-07-01 03:54:33 +02:00
owner = "zealdocs";
repo = "zeal";
rev = "7ea03e4bb9754020e902a2989f56f4bc42b85c82";
sha256 = "sha256-BozRLlws56i9P7Qtc5qPZWgJR5yhYqnLQsEdsymt5us=";
2015-01-28 00:02:50 +01:00
};
2020-07-01 03:54:33 +02:00
# we only need this if we are using a version that hasn't been released. We
# could also match on the "VERSION x.y.z" bit but then it would have to be
# updated based on whatever is the latest release, so instead just rewrite the
# line.
postPatch = ''
sed -i CMakeLists.txt \
-e 's@^project.*@project(Zeal VERSION ${version})@'
'';
nativeBuildInputs = [ cmake extra-cmake-modules pkg-config wrapQtAppsHook ];
2020-07-01 03:54:33 +02:00
buildInputs =
[
qtbase
qtimageformats
qtwebengine
libarchive
libXdmcp
libpthreadstubs
xcbutilkeysyms
] ++ lib.optionals isQt5 [ qtx11extras ];
2015-01-28 00:02:50 +01:00
meta = with lib; {
description = "A simple offline API documentation browser";
2015-01-28 00:02:50 +01:00
longDescription = ''
Zeal is a simple offline API documentation browser inspired by Dash (macOS
2015-01-28 00:02:50 +01:00
app), available for Linux and Windows.
'';
2020-07-01 03:54:33 +02:00
homepage = "https://zealdocs.org/";
license = licenses.gpl3;
2017-12-11 01:05:54 +01:00
maintainers = with maintainers; [ skeidel peterhoeg ];
2020-07-01 03:54:33 +02:00
platforms = platforms.linux;
2015-01-28 00:02:50 +01:00
};
}