@@ -1,12 +1,55 @@
1−{ stdenv, fetchurl, perl, python2, ruby, bison, gperf, cmake, ninja
2−, pkgconfig, gettext, gobject-introspection, libnotify, gnutls, libgcrypt
3−, gtk3, wayland, libwebp, enchant2, xorg, libxkbcommon, epoxy, at-spi2-core
4−, libxml2, libsoup, libsecret, libxslt, harfbuzz, libpthreadstubs, pcre, nettle, libtasn1, p11-kit
5−, libidn, libedit, readline, libGL, libGLU, libintl, openjpeg
6−, enableGeoLocation ? true, geoclue2, sqlite
7−, enableGtk2Plugins ? false, gtk2 ? null
8−, gst-plugins-base, gst-plugins-bad, woff2
9−, bubblewrap, libseccomp, xdg-dbus-proxy, substituteAll
1+{ stdenv
2+, fetchurl
3+, perl
4+, python2
5+, ruby
6+, bison
7+, gperf
8+, cmake
9+, ninja
10+, pkgconfig
11+, gettext
12+, gobject-introspection
13+, libnotify
14+, gnutls
15+, libgcrypt
16+, gtk3
17+, wayland
18+, libwebp
19+, enchant2
20+, xorg
21+, libxkbcommon
22+, epoxy
23+, at-spi2-core
24+, libxml2
25+, libsoup
26+, libsecret
27+, libxslt
28+, harfbuzz
29+, libpthreadstubs
30+, pcre
31+, nettle
32+, libtasn1
33+, p11-kit
34+, libidn
35+, libedit
36+, readline
37+, libGL
38+, libGLU
39+, libintl
40+, openjpeg
41+, enableGeoLocation ? true
42+, geoclue2
43+, sqlite
44+, enableGtk2Plugins ? false
45+, gtk2 ? null
46+, gst-plugins-base
47+, gst-plugins-bad
48+, woff2
49+, bubblewrap
50+, libseccomp
51+, xdg-dbus-proxy
52+, substituteAll
1053}:
1154
1255assert enableGeoLocation -> geoclue2 != null;
@@ -14,18 +57,12 @@ assert enableGtk2Plugins -> gtk2 != null;
1457assert stdenv.isDarwin -> !enableGtk2Plugins;
1558
1659with stdenv.lib;
60+
1761stdenv.mkDerivation rec {
1862 pname = "webkitgtk";
1963 version = "2.26.2";
2064
21− meta = {
22− description = "Web content rendering engine, GTK port";
23− homepage = https://webkitgtk.org/;
24− license = licenses.bsd2;
25− platforms = platforms.linux;
26− hydraPlatforms = [];
27− maintainers = with maintainers; [ ];
28− };
65+ outputs = [ "out" "dev" ];
2966
3067 src = fetchurl {
3168 url = "https://webkitgtk.org/releases/${pname}-${version}.tar.xz";
@@ -40,54 +77,97 @@ stdenv.mkDerivation rec {
4077 ./libglvnd-headers.patch
4178 ];
4279
43− postPatch = ''
44− patchShebangs .
45− '';
46−
47− cmakeFlags = [
48− "-DPORT=GTK"
49− "-DUSE_LIBHYPHEN=OFF"
50− "-DENABLE_INTROSPECTION=ON"
51− "-DUSE_WPE_RENDERER=OFF"
52− ]
53− ++ optional (!enableGtk2Plugins) "-DENABLE_PLUGIN_PROCESS_GTK2=OFF"
54− ++ optional stdenv.isLinux "-DENABLE_GLES2=ON"
55− ++ optionals stdenv.isDarwin [
56− "-DUSE_SYSTEM_MALLOC=ON"
57− "-DUSE_ACCELERATE=0"
58− "-DENABLE_MINIBROWSER=OFF"
59− "-DENABLE_VIDEO=ON"
60− "-DENABLE_QUARTZ_TARGET=ON"
61− "-DENABLE_X11_TARGET=OFF"
62− "-DENABLE_OPENGL=OFF"
63− "-DENABLE_WEB_AUDIO=OFF"
64− "-DENABLE_WEBGL=OFF"
65− "-DENABLE_GRAPHICS_CONTEXT_3D=OFF"
66− "-DENABLE_GTKDOC=OFF"
67− ];
68−
6980 nativeBuildInputs = [
70− cmake ninja perl python2 ruby bison gperf
71− pkgconfig gettext gobject-introspection
81+ bison
82+ cmake
83+ gettext
84+ gobject-introspection
85+ gperf
86+ ninja
87+ perl
88+ pkgconfig
89+ python2
90+ ruby
7291 ];
7392
7493 buildInputs = [
75− libintl libwebp enchant2 libnotify gnutls pcre nettle libidn libgcrypt woff2
76− libxml2 libsecret libxslt harfbuzz libpthreadstubs libtasn1 p11-kit openjpeg
77− sqlite gst-plugins-base gst-plugins-bad libxkbcommon epoxy at-spi2-core
78− libGL libGLU
94+ at-spi2-core
95+ enchant2
96+ epoxy
97+ gnutls
98+ gst-plugins-bad
99+ gst-plugins-base
100+ harfbuzz
101+ libGL
102+ libGLU
103+ libgcrypt
104+ libidn
105+ libintl
106+ libnotify
107+ libpthreadstubs
108+ libsecret
109+ libtasn1
110+ libwebp
111+ libxkbcommon
112+ libxml2
113+ libxslt
114+ nettle
115+ openjpeg
116+ p11-kit
117+ pcre
118+ sqlite
119+ woff2
120+ ] ++ (with xorg; [
121+ libXdamage
122+ libXdmcp
123+ libXt
124+ libXtst
125+ ]) ++ optionals stdenv.isDarwin [
126+ libedit
127+ readline
128+ ] ++ optionals stdenv.isLinux [
129+ bubblewrap
130+ libseccomp
131+ wayland
132+ xdg-dbus-proxy
79133 ] ++ optional enableGeoLocation geoclue2
80− ++ optional enableGtk2Plugins gtk2
81− ++ (with xorg; [ libXdmcp libXt libXtst libXdamage ])
82− ++ optionals stdenv.isDarwin [ libedit readline ]
83− ++ optionals stdenv.isLinux [
84− wayland bubblewrap libseccomp xdg-dbus-proxy
85− ];
134+ ++ optional enableGtk2Plugins gtk2;
86135
87136 propagatedBuildInputs = [
88− libsoup gtk3
137+ gtk3
138+ libsoup
89139 ];
90140
91− outputs = [ "out" "dev" ];
141+ cmakeFlags = [
142+ "-DENABLE_INTROSPECTION=ON"
143+ "-DPORT=GTK"
144+ "-DUSE_LIBHYPHEN=OFF"
145+ "-DUSE_WPE_RENDERER=OFF"
146+ ] ++ optionals stdenv.isDarwin [
147+ "-DENABLE_GRAPHICS_CONTEXT_3D=OFF"
148+ "-DENABLE_GTKDOC=OFF"
149+ "-DENABLE_MINIBROWSER=OFF"
150+ "-DENABLE_OPENGL=OFF"
151+ "-DENABLE_QUARTZ_TARGET=ON"
152+ "-DENABLE_VIDEO=ON"
153+ "-DENABLE_WEBGL=OFF"
154+ "-DENABLE_WEB_AUDIO=OFF"
155+ "-DENABLE_X11_TARGET=OFF"
156+ "-DUSE_ACCELERATE=0"
157+ "-DUSE_SYSTEM_MALLOC=ON"
158+ ] ++ optional (!enableGtk2Plugins) "-DENABLE_PLUGIN_PROCESS_GTK2=OFF"
159+ ++ optional stdenv.isLinux "-DENABLE_GLES2=ON";
160+
161+ postPatch = ''
162+ patchShebangs .
163+ '';
92164
165+ meta = {
166+ description = "Web content rendering engine, GTK port";
167+ homepage = https://webkitgtk.org/;
168+ license = licenses.bsd2;
169+ platforms = platforms.linux;
170+ hydraPlatforms = [];
171+ maintainers = with maintainers; [];
172+ };
93173}