From 8a7d373795f197dbc492ad95e3ad4d1b60ba0d07 Mon Sep 17 00:00:00 2001 From: Johannes Bornhold Date: Sat, 14 Jan 2017 23:53:56 +0100 Subject: [PATCH] Darwin gtk quartz follow up (#21883) * gtk2-x11: Add gtk2 configuration with X11 backend After making quartz the default for darwin, some builds started to fail since they only support gtk with the X11 backend. * apvlv: Use gtk2-x11 on darwin * gpicview: Use gtk2-x11 for darwin * lxappearance: Use gtk2-x11 for darwin * fontforge-gtk: Use gtk2-x11 for darwin * gbdfed: Use gtk2-x11 for darwin --- pkgs/development/libraries/gtk+/2.x.nix | 2 +- pkgs/top-level/all-packages.nix | 19 +++++++++++++++---- 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/pkgs/development/libraries/gtk+/2.x.nix b/pkgs/development/libraries/gtk+/2.x.nix index bcbbecd242dc..306e2db29ce9 100644 --- a/pkgs/development/libraries/gtk+/2.x.nix +++ b/pkgs/development/libraries/gtk+/2.x.nix @@ -41,7 +41,7 @@ stdenv.mkDerivation rec { ++ libintlOrEmpty ++ optional xineramaSupport libXinerama ++ optionals cupsSupport [ cups ] - ++ optionals (gdktarget == "quartz") [ AppKit Cocoa ]; + ++ optionals stdenv.isDarwin [ AppKit Cocoa ]; configureFlags = [ "--with-gdktarget=${gdktarget}" diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index f0e889f9666a..5cfb05aed6ce 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1738,6 +1738,7 @@ in }); fontforge-gtk = callPackage ../tools/misc/fontforge { withGTK = true; + gtk2 = gtk2-x11; inherit (darwin.apple_sdk.frameworks) Carbon Cocoa; }; @@ -1842,7 +1843,7 @@ in gazebo-headless = gazeboSimulator.gazebo6-headless; gbdfed = callPackage ../tools/misc/gbdfed { - gtk = gtk2; + gtk = gtk2-x11; }; gdmap = callPackage ../tools/system/gdmap { }; @@ -5623,7 +5624,9 @@ in kanif = callPackage ../applications/networking/cluster/kanif { }; - lxappearance = callPackage ../desktops/lxde/core/lxappearance {}; + lxappearance = callPackage ../desktops/lxde/core/lxappearance { + gtk2 = gtk2-x11; + }; lxmenu-data = callPackage ../desktops/lxde/core/lxmenu-data.nix { }; @@ -7512,6 +7515,10 @@ in inherit (darwin.apple_sdk.frameworks) AppKit Cocoa; }; + gtk2-x11 = gtk2.override { + gdktarget = "x11"; + }; + gtk3 = callPackage ../development/libraries/gtk+/3.x.nix { }; gtkmm2 = callPackage ../development/libraries/gtkmm/2.x.nix { }; @@ -13173,7 +13180,9 @@ in gpa = callPackage ../applications/misc/gpa { }; - gpicview = callPackage ../applications/graphics/gpicview { }; + gpicview = callPackage ../applications/graphics/gpicview { + gtk2 = gtk2-x11; + }; gqrx = callPackage ../applications/misc/gqrx { }; @@ -15668,7 +15677,9 @@ in inherit (gnome2) libgnomeprint libgnomeprintui libgnomecanvas; }; - apvlv = callPackage ../applications/misc/apvlv { }; + apvlv = callPackage ../applications/misc/apvlv { + gtk2 = gtk2-x11; + }; xpdf = callPackage ../applications/misc/xpdf { base14Fonts = "${ghostscript}/share/ghostscript/fonts";