gtk3: cleanup expression
This commit is contained in:
parent
db0655886d
commit
a7edafd0d3
1 changed files with 81 additions and 31 deletions
|
@ -1,33 +1,57 @@
|
||||||
{ stdenv, fetchurl, fetchpatch, pkgconfig, gettext, perl, makeWrapper, shared-mime-info, isocodes
|
{ stdenv
|
||||||
, expat, glib, cairo, pango, gdk_pixbuf, atk, at-spi2-atk, gobject-introspection, fribidi
|
, fetchurl
|
||||||
, xorg, epoxy, json-glib, libxkbcommon, gmp, gnome3, autoreconfHook, gsettings-desktop-schemas
|
, fetchpatch
|
||||||
|
, pkgconfig
|
||||||
|
, gettext
|
||||||
|
, perl
|
||||||
|
, makeWrapper
|
||||||
|
, shared-mime-info
|
||||||
|
, isocodes
|
||||||
|
, expat
|
||||||
|
, glib
|
||||||
|
, cairo
|
||||||
|
, pango
|
||||||
|
, gdk_pixbuf
|
||||||
|
, atk
|
||||||
|
, at-spi2-atk
|
||||||
|
, gobject-introspection
|
||||||
|
, fribidi
|
||||||
|
, xorg
|
||||||
|
, epoxy
|
||||||
|
, json-glib
|
||||||
|
, libxkbcommon
|
||||||
|
, gmp
|
||||||
|
, gnome3
|
||||||
|
, autoreconfHook
|
||||||
|
, gsettings-desktop-schemas
|
||||||
, x11Support ? stdenv.isLinux
|
, x11Support ? stdenv.isLinux
|
||||||
, waylandSupport ? stdenv.isLinux, mesa, wayland, wayland-protocols
|
, waylandSupport ? stdenv.isLinux
|
||||||
|
, mesa
|
||||||
|
, wayland
|
||||||
|
, wayland-protocols
|
||||||
, xineramaSupport ? stdenv.isLinux
|
, xineramaSupport ? stdenv.isLinux
|
||||||
, cupsSupport ? stdenv.isLinux, cups ? null
|
, cupsSupport ? stdenv.isLinux
|
||||||
, AppKit, Cocoa
|
, cups ? null
|
||||||
|
, AppKit
|
||||||
|
, Cocoa
|
||||||
}:
|
}:
|
||||||
|
|
||||||
assert cupsSupport -> cups != null;
|
assert cupsSupport -> cups != null;
|
||||||
|
|
||||||
with stdenv.lib;
|
with stdenv.lib;
|
||||||
|
|
||||||
let
|
|
||||||
version = "3.24.8";
|
|
||||||
in
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
name = "gtk+3-${version}";
|
pname = "gtk+3";
|
||||||
|
version = "3.24.8";
|
||||||
|
|
||||||
|
outputs = [ "out" "dev" ];
|
||||||
|
outputBin = "dev";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "mirror://gnome/sources/gtk+/${stdenv.lib.versions.majorMinor version}/gtk+-${version}.tar.xz";
|
url = "mirror://gnome/sources/gtk+/${stdenv.lib.versions.majorMinor version}/gtk+-${version}.tar.xz";
|
||||||
sha256 = "16f71bbkhwhndcsrpyhjia3b77cb5ksf5c45lyfgws4pkgg64sb6";
|
sha256 = "16f71bbkhwhndcsrpyhjia3b77cb5ksf5c45lyfgws4pkgg64sb6";
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = [ "out" "dev" ];
|
|
||||||
outputBin = "dev";
|
|
||||||
|
|
||||||
nativeBuildInputs = [ pkgconfig gettext gobject-introspection perl makeWrapper autoreconfHook ];
|
|
||||||
|
|
||||||
patches = [
|
patches = [
|
||||||
./3.0-immodules.cache.patch
|
./3.0-immodules.cache.patch
|
||||||
(fetchpatch {
|
(fetchpatch {
|
||||||
|
@ -42,23 +66,53 @@ stdenv.mkDerivation rec {
|
||||||
./3.0-darwin-x11.patch
|
./3.0-darwin-x11.patch
|
||||||
];
|
];
|
||||||
|
|
||||||
buildInputs = [ libxkbcommon epoxy json-glib isocodes ]
|
nativeBuildInputs = [
|
||||||
++ optional stdenv.isDarwin AppKit;
|
autoreconfHook
|
||||||
propagatedBuildInputs = with xorg; with stdenv.lib;
|
gettext
|
||||||
[ expat glib cairo pango gdk_pixbuf atk at-spi2-atk gsettings-desktop-schemas fribidi
|
gobject-introspection
|
||||||
libXrandr libXrender libXcomposite libXi libXcursor libSM libICE ]
|
makeWrapper
|
||||||
++ optional stdenv.isDarwin Cocoa # explicitly propagated, always needed
|
perl
|
||||||
++ optionals waylandSupport [ mesa wayland wayland-protocols ]
|
pkgconfig
|
||||||
++ optional xineramaSupport libXinerama
|
];
|
||||||
++ optional cupsSupport cups;
|
|
||||||
|
buildInputs = [
|
||||||
|
libxkbcommon
|
||||||
|
epoxy
|
||||||
|
json-glib
|
||||||
|
isocodes
|
||||||
|
]
|
||||||
|
++ optional stdenv.isDarwin AppKit
|
||||||
|
;
|
||||||
|
|
||||||
|
propagatedBuildInputs = with xorg; [
|
||||||
|
at-spi2-atk
|
||||||
|
atk
|
||||||
|
cairo
|
||||||
|
expat
|
||||||
|
fribidi
|
||||||
|
gdk_pixbuf
|
||||||
|
glib
|
||||||
|
gsettings-desktop-schemas
|
||||||
|
libICE
|
||||||
|
libSM
|
||||||
|
libXcomposite
|
||||||
|
libXcursor
|
||||||
|
libXi
|
||||||
|
libXrandr
|
||||||
|
libXrender
|
||||||
|
pango
|
||||||
|
]
|
||||||
|
++ optional stdenv.isDarwin Cocoa # explicitly propagated, always needed
|
||||||
|
++ optionals waylandSupport [ mesa wayland wayland-protocols ]
|
||||||
|
++ optional xineramaSupport libXinerama
|
||||||
|
++ optional cupsSupport cups
|
||||||
|
;
|
||||||
#TODO: colord?
|
#TODO: colord?
|
||||||
|
|
||||||
## (2019-06-12) Demos seem to install fine now. Keeping this around in case it fails again.
|
## (2019-06-12) Demos seem to install fine now. Keeping this around in case it fails again.
|
||||||
## (2014-03-27) demos fail to install, no idea where's the problem
|
## (2014-03-27) demos fail to install, no idea where's the problem
|
||||||
#preConfigure = "sed '/^SRC_SUBDIRS /s/demos//' -i Makefile.in";
|
#preConfigure = "sed '/^SRC_SUBDIRS /s/demos//' -i Makefile.in";
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
|
||||||
|
|
||||||
configureFlags = optional stdenv.isDarwin [
|
configureFlags = optional stdenv.isDarwin [
|
||||||
"--disable-debug"
|
"--disable-debug"
|
||||||
"--disable-dependency-tracking"
|
"--disable-dependency-tracking"
|
||||||
|
@ -94,9 +148,8 @@ stdenv.mkDerivation rec {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = {
|
||||||
description = "A multi-platform toolkit for creating graphical user interfaces";
|
description = "A multi-platform toolkit for creating graphical user interfaces";
|
||||||
|
|
||||||
longDescription = ''
|
longDescription = ''
|
||||||
GTK+ is a highly usable, feature rich toolkit for creating
|
GTK+ is a highly usable, feature rich toolkit for creating
|
||||||
graphical user interfaces which boasts cross platform
|
graphical user interfaces which boasts cross platform
|
||||||
|
@ -107,11 +160,8 @@ stdenv.mkDerivation rec {
|
||||||
proprietary software with GTK+ without any license fees or
|
proprietary software with GTK+ without any license fees or
|
||||||
royalties.
|
royalties.
|
||||||
'';
|
'';
|
||||||
|
|
||||||
homepage = https://www.gtk.org/;
|
homepage = https://www.gtk.org/;
|
||||||
|
|
||||||
license = licenses.lgpl2Plus;
|
license = licenses.lgpl2Plus;
|
||||||
|
|
||||||
maintainers = with maintainers; [ raskin vcunat lethalman ];
|
maintainers = with maintainers; [ raskin vcunat lethalman ];
|
||||||
platforms = platforms.all;
|
platforms = platforms.all;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue