webkitgtk: add darwin support

This commit is contained in:
Ryan Trinkle
2016-03-30 09:40:36 +02:00
committed by Vladimír Čunát
parent e498a645c1
commit 8605dab964
13 changed files with 259 additions and 19 deletions
+19 -5
View File
@@ -4,6 +4,7 @@
, xcbSupport ? true # no longer experimental since 1.12
, glSupport ? true, mesa_noglu ? null # mesa is no longer a big dependency
, pdfSupport ? true
, darwin
}:
assert glSupport -> mesa_noglu != null;
@@ -11,14 +12,21 @@ assert glSupport -> mesa_noglu != null;
with { inherit (stdenv.lib) optional optionals; };
stdenv.mkDerivation rec {
name = "cairo-1.14.4";
name = "cairo-1.14.6";
src = fetchurl {
url = "http://cairographics.org/releases/${name}.tar.xz";
sha256 = "05p75r914d809711yg9rapgmmi4hymzbarhd3w0yrfadhiy9rv7n";
sha256 = "0lmjlzmghmr27y615px9hkm552x7ap6pmq9mfbzr6smp8y2b6g31";
};
nativeBuildInputs = [ pkgconfig libiconv ] ++ libintlOrEmpty;
nativeBuildInputs = [
pkgconfig
libiconv
] ++ libintlOrEmpty ++ optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks; [
CoreGraphics
ApplicationServices
Carbon
]);
propagatedBuildInputs =
with xorg; [ xorg.xlibsWrapper fontconfig expat freetype pixman zlib libpng ]
@@ -28,11 +36,17 @@ stdenv.mkDerivation rec {
++ optionals glSupport [ mesa_noglu ]
;
configureFlags = [ "--enable-tee" ]
configureFlags = if stdenv.isDarwin then [
"--disable-dependency-tracking"
"--enable-quartz"
"--enable-quartz-font"
"--enable-quartz-image"
"--enable-ft"
] else ([ "--enable-tee" ]
++ optional xcbSupport "--enable-xcb"
++ optional glSupport "--enable-gl"
++ optional pdfSupport "--enable-pdf"
;
);
preConfigure =
# On FreeBSD, `-ldl' doesn't exist.