Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{
2 lib,
3 stdenv,
4 fetchurl,
5 fetchpatch,
6 autoreconfHook,
7 pkg-config,
8 gtk3,
9 intltool,
10 gnome,
11 adwaita-icon-theme,
12 enchant,
13 isocodes,
14 gsettings-desktop-schemas,
15}:
16
17stdenv.mkDerivation rec {
18 pname = "gtkhtml";
19 version = "4.10.0";
20
21 src = fetchurl {
22 url = "mirror://gnome/sources/gtkhtml/${lib.versions.majorMinor version}/gtkhtml-${version}.tar.xz";
23 hash = "sha256-yjtkJPssesXZy4/a+2kxj6LoJcnPbtF9HjjZsp5WBsM=";
24 };
25
26 patches = [
27 # Enables enchant2 support.
28 # Upstream is dead, no further releases are coming.
29 (fetchpatch {
30 name = "enchant-2.patch";
31 url = "https://aur.archlinux.org/cgit/aur.git/plain/enchant-2.patch?h=gtkhtml4&id=0218303a63d64c04d6483a6fe9bb55063fcfaa43";
32 hash = "sha256-f0OToWGHZwxvqf+0qosfA9FfwJ/IXfjIPP5/WrcvArI=";
33 extraPrefix = "";
34 })
35 # Resolves a GCC14 missing typecast error
36 ./typecast.diff
37 ];
38
39 passthru = {
40 updateScript = gnome.updateScript { packageName = "gtkhtml"; };
41 };
42
43 nativeBuildInputs = [
44 autoreconfHook
45 pkg-config
46 intltool
47 ];
48
49 buildInputs = [
50 gtk3
51 adwaita-icon-theme
52 gsettings-desktop-schemas
53 ];
54
55 propagatedBuildInputs = [
56 enchant
57 isocodes
58 ];
59
60 meta = with lib; {
61 platforms = platforms.linux;
62 maintainers = [ ];
63 };
64}