2017-08-28 11:05:48 +01:00
|
|
|
{ stdenv, fetchurl, fetchpatch, perl, python, ruby, bison, gperf, flex
|
2018-12-02 11:41:15 +00:00
|
|
|
, pkgconfig, which, gettext, gobject-introspection, pruneLibtoolFiles
|
2015-01-06 16:34:24 +00:00
|
|
|
, gtk2, gtk3, wayland, libwebp, enchant, sqlite
|
2015-10-20 21:49:30 +01:00
|
|
|
, libxml2, libsoup, libsecret, libxslt, harfbuzz, xorg
|
2016-07-28 03:45:54 +01:00
|
|
|
, gst-plugins-base, libobjc
|
2014-10-09 11:26:20 +01:00
|
|
|
, withGtk2 ? false
|
2016-03-29 17:04:46 +01:00
|
|
|
, enableIntrospection ? !stdenv.isDarwin
|
|
|
|
, enableCredentialStorage ? !stdenv.isDarwin
|
|
|
|
, readline, libedit
|
2014-10-09 11:26:20 +01:00
|
|
|
}:
|
|
|
|
|
2016-03-29 17:04:46 +01:00
|
|
|
assert stdenv.isDarwin -> !enableIntrospection;
|
|
|
|
assert stdenv.isDarwin -> !enableCredentialStorage;
|
|
|
|
|
|
|
|
with stdenv.lib;
|
2014-10-09 11:26:20 +01:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "webkitgtk-${version}";
|
2016-07-15 13:15:13 +01:00
|
|
|
version = "2.4.11";
|
2014-10-09 11:26:20 +01:00
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Web content rendering engine, GTK+ port";
|
2017-08-01 21:03:30 +01:00
|
|
|
homepage = http://webkitgtk.org/;
|
2014-10-09 11:26:20 +01:00
|
|
|
license = licenses.bsd2;
|
2016-07-28 03:45:54 +01:00
|
|
|
platforms = with platforms; linux ++ darwin;
|
2016-03-13 08:08:15 +00:00
|
|
|
maintainers = [];
|
2017-02-26 20:04:58 +00:00
|
|
|
knownVulnerabilities = [
|
|
|
|
"WSA-2016-0004"
|
|
|
|
"WSA-2016-0005"
|
|
|
|
"WSA-2016-0006"
|
|
|
|
"WSA-2017-0001"
|
|
|
|
"WSA-2017-0002"
|
|
|
|
];
|
2014-10-09 11:26:20 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
src = fetchurl {
|
2018-06-28 19:43:35 +01:00
|
|
|
url = "https://webkitgtk.org/releases/${name}.tar.xz";
|
2016-07-15 13:15:13 +01:00
|
|
|
sha256 = "1xsvnvyvlywwyf6m9ainpsg87jkxjmd37q6zgz9cxb7v3c2ym2jq";
|
2014-10-09 11:26:20 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
CC = "cc";
|
|
|
|
|
|
|
|
prePatch = ''
|
|
|
|
patchShebangs Tools/gtk
|
|
|
|
'';
|
2016-03-29 17:04:46 +01:00
|
|
|
patches = [
|
|
|
|
./webcore-svg-libxml-cflags.patch
|
2017-08-28 11:05:48 +01:00
|
|
|
(fetchpatch {
|
|
|
|
url = https://raw.githubusercontent.com/gentoo/gentoo/7c5457e265bd40c156a8fe6b2ff94a4e34bcea8e/net-libs/webkit-gtk/files/webkit-gtk-2.4.9-gcc-6.patch;
|
|
|
|
sha256 = "0ll93dr5vxd40wvly1jaw41lvw86krac0jc6k6cacrps4i5ql5j0";
|
|
|
|
})
|
2016-03-29 17:04:46 +01:00
|
|
|
] ++ optionals stdenv.isDarwin [
|
2016-07-28 03:45:54 +01:00
|
|
|
./configure.patch
|
2016-03-29 17:04:46 +01:00
|
|
|
./quartz-webcore.patch
|
|
|
|
./libc++.patch
|
|
|
|
./plugin-none.patch
|
2017-09-04 15:56:34 +01:00
|
|
|
] ++ optionals stdenv.hostPlatform.isMusl [
|
|
|
|
./fix-execinfo.patch
|
2016-03-29 17:04:46 +01:00
|
|
|
];
|
webkitgtk-2.4: security update, fix and parallel build
NEWS claims security fixes:
CVE-2014-1344, CVE-2014-1384, CVE-2014-1385, CVE-2014-1386,
CVE-2014-1387, CVE-2014-1388, CVE-2014-1389, CVE-2014-1390.
Otherwise NEWS seems safe, basically only containing bugfixes.
Parallel building should work now, thanks to make update :-)
tested with 8 threads, once webkitgtk24x and webkitgtk2.
2015-04-24 08:59:52 +01:00
|
|
|
|
2014-10-09 11:26:20 +01:00
|
|
|
configureFlags = with stdenv.lib; [
|
|
|
|
"--disable-geolocation"
|
2016-07-15 13:15:13 +01:00
|
|
|
"--disable-jit"
|
2016-09-05 16:43:38 +01:00
|
|
|
# needed for parallel building
|
|
|
|
"--enable-dependency-tracking"
|
2014-10-09 11:26:20 +01:00
|
|
|
(optionalString enableIntrospection "--enable-introspection")
|
2016-03-29 17:04:46 +01:00
|
|
|
] ++ optional withGtk2 [
|
2014-10-09 11:26:20 +01:00
|
|
|
"--with-gtk=2.0"
|
2016-03-29 17:04:46 +01:00
|
|
|
] ++ optionals (withGtk2 || stdenv.isDarwin) [
|
2014-10-09 11:26:20 +01:00
|
|
|
"--disable-webkit2"
|
2016-03-29 17:04:46 +01:00
|
|
|
] ++ optionals stdenv.isDarwin [
|
|
|
|
"--disable-x11-target"
|
|
|
|
"--enable-quartz-target"
|
|
|
|
"--disable-web-audio"
|
2017-03-31 13:51:43 +01:00
|
|
|
"CFLAGS=-DJSC_OBJC_API_ENABLED=0"
|
|
|
|
"CXXFLAGS=-DJSC_OBJC_API_ENABLED=0"
|
2016-03-29 17:04:46 +01:00
|
|
|
] ++ optionals (!enableCredentialStorage) [
|
|
|
|
"--disable-credential-storage"
|
2014-10-09 11:26:20 +01:00
|
|
|
];
|
|
|
|
|
2018-09-09 14:56:58 +01:00
|
|
|
NIX_CFLAGS_COMPILE = [
|
|
|
|
"-DU_NOEXCEPT="
|
|
|
|
"-Wno-expansion-to-defined"
|
|
|
|
];
|
2016-03-29 17:04:46 +01:00
|
|
|
|
2014-10-09 11:26:20 +01:00
|
|
|
dontAddDisableDepTrack = true;
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
2015-09-29 17:11:03 +01:00
|
|
|
perl python ruby bison gperf flex
|
2018-12-02 11:41:15 +00:00
|
|
|
pkgconfig which gettext gobject-introspection pruneLibtoolFiles
|
2014-10-09 11:26:20 +01:00
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
2016-03-29 17:04:46 +01:00
|
|
|
gtk2 libwebp enchant
|
|
|
|
libxml2 libxslt
|
2018-05-09 02:33:38 +01:00
|
|
|
gst-plugins-base sqlite xorg.libXt xorg.libXdamage
|
2016-03-29 17:04:46 +01:00
|
|
|
] ++ optionals enableCredentialStorage [
|
|
|
|
libsecret
|
|
|
|
] ++ (if stdenv.isDarwin then [
|
2016-07-28 03:45:54 +01:00
|
|
|
readline libedit libobjc
|
2016-03-29 17:04:46 +01:00
|
|
|
] else [
|
|
|
|
wayland
|
|
|
|
]);
|
2014-10-09 11:26:20 +01:00
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2015-09-29 17:11:03 +01:00
|
|
|
libsoup harfbuzz/*icu in *.la*/
|
2014-10-09 11:26:20 +01:00
|
|
|
(if withGtk2 then gtk2 else gtk3)
|
|
|
|
];
|
|
|
|
|
2016-09-05 16:43:38 +01:00
|
|
|
enableParallelBuilding = true;
|
webkitgtk-2.4: security update, fix and parallel build
NEWS claims security fixes:
CVE-2014-1344, CVE-2014-1384, CVE-2014-1385, CVE-2014-1386,
CVE-2014-1387, CVE-2014-1388, CVE-2014-1389, CVE-2014-1390.
Otherwise NEWS seems safe, basically only containing bugfixes.
Parallel building should work now, thanks to make update :-)
tested with 8 threads, once webkitgtk24x and webkitgtk2.
2015-04-24 08:59:52 +01:00
|
|
|
|
2015-05-25 13:05:07 +01:00
|
|
|
}
|