diff options
Diffstat (limited to 'pkgs/development/libraries/gtk+/3.x.nix')
-rw-r--r-- | pkgs/development/libraries/gtk+/3.x.nix | 29 |
1 files changed, 18 insertions, 11 deletions
diff --git a/pkgs/development/libraries/gtk+/3.x.nix b/pkgs/development/libraries/gtk+/3.x.nix index f738f76ca029..a2da4c7b0339 100644 --- a/pkgs/development/libraries/gtk+/3.x.nix +++ b/pkgs/development/libraries/gtk+/3.x.nix @@ -1,12 +1,11 @@ { stdenv, fetchurl, pkgconfig, gettext, perl , expat, glib, cairo, pango, gdk_pixbuf, atk, at_spi2_atk, gobjectIntrospection -, xlibs, x11, wayland, libxkbcommon, epoxy +, xorg, wayland, epoxy, json_glib, libxkbcommon, gmp , xineramaSupport ? stdenv.isLinux , cupsSupport ? stdenv.isLinux, cups ? null , darwin }: -assert xineramaSupport -> xlibs.libXinerama != null; assert cupsSupport -> cups != null; with stdenv.lib; @@ -24,17 +23,22 @@ stdenv.mkDerivation rec { sha256 = "107aeb9a4244ce3c044becdd6dffc32d83202595181597180d4c736302a71852"; }; + outputs = [ "dev" "out" ]; + outputBin = "dev"; + nativeBuildInputs = [ pkgconfig gettext gobjectIntrospection perl ]; - buildInputs = [ libxkbcommon epoxy ]; - propagatedBuildInputs = with xlibs; with stdenv.lib; - [ expat glib cairo pango gdk_pixbuf atk at_spi2_atk libXrandr libXrender libXcomposite libXi libXcursor ] + buildInputs = [ libxkbcommon epoxy json_glib ]; + propagatedBuildInputs = with xorg; with stdenv.lib; + [ expat glib cairo pango gdk_pixbuf atk at_spi2_atk + libXrandr libXrender libXcomposite libXi libXcursor libSM libICE ] ++ optionals stdenv.isLinux [ wayland ] ++ optional stdenv.isDarwin (with darwin.apple_sdk.frameworks; [ AppKit Cocoa ]) ++ optional xineramaSupport libXinerama ++ optional cupsSupport cups; + #TODO: colord? - NIX_LDFLAGS = if stdenv.isDarwin then "-lintl" else null; + NIX_LDFLAGS = stdenv.lib.optionalString stdenv.isDarwin "-lintl"; # demos fail to install, no idea where's the problem preConfigure = "sed '/^SRC_SUBDIRS /s/demos//' -i Makefile.in"; @@ -49,7 +53,10 @@ stdenv.mkDerivation rec { "--enable-quartz-backend" ]; - postInstall = "rm -rf $out/share/gtk-doc"; + postInstall = '' + substituteInPlace "$out/lib/gtk-3.0/3.0.0/printbackends/libprintbackend-cups.la" \ + --replace '-L${gmp.dev}/lib' '-L${gmp.out}/lib' + ''; passthru = { gtkExeEnvPostBuild = '' @@ -58,7 +65,7 @@ stdenv.mkDerivation rec { ''; # workaround for bug of nix-mode for Emacs */ ''; }; - meta = { + meta = with stdenv.lib; { description = "A multi-platform toolkit for creating graphical user interfaces"; longDescription = '' @@ -74,9 +81,9 @@ stdenv.mkDerivation rec { homepage = http://www.gtk.org/; - license = stdenv.lib.licenses.lgpl2Plus; + license = licenses.lgpl2Plus; - maintainers = with stdenv.lib.maintainers; [ urkud raskin vcunat lethalman ]; - platforms = stdenv.lib.platforms.all; + maintainers = with maintainers; [ urkud raskin vcunat lethalman ]; + platforms = platforms.all; }; } |