diff options
author | janus <janus@xn--kn-1ia.guru> | 2015-11-28 15:06:15 +0000 |
---|---|---|
committer | janus <janus@xn--kn-1ia.guru> | 2016-01-01 17:01:13 +0000 |
commit | 55aa9163cca34107b3e3ce7ce8d7bb76fa5717a0 (patch) | |
tree | 3e35217e4909c42136534ea37d887b04baa7a402 /pkgs/development/libraries/qt-4.x | |
parent | a472d836f674fe388018aaee75983e3400a77db4 (diff) |
FreeBSD: minor fixes, add notes and make stdenv more robust
Diffstat (limited to 'pkgs/development/libraries/qt-4.x')
-rw-r--r-- | pkgs/development/libraries/qt-4.x/4.8/default.nix | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/pkgs/development/libraries/qt-4.x/4.8/default.nix b/pkgs/development/libraries/qt-4.x/4.8/default.nix index 25b547bf1cf6f..17e0485b29fe0 100644 --- a/pkgs/development/libraries/qt-4.x/4.8/default.nix +++ b/pkgs/development/libraries/qt-4.x/4.8/default.nix @@ -85,7 +85,7 @@ stdenv.mkDerivation rec { -datadir $out/share/${name} -translationdir $out/share/${name}/translations " - '' + optionalString stdenv.isDarwin '' + '' + optionalString stdenv.cc.isClang '' sed -i 's/QMAKE_CC = gcc/QMAKE_CC = clang/' mkspecs/common/g++-base.conf sed -i 's/QMAKE_CXX = g++/QMAKE_CXX = clang++/' mkspecs/common/g++-base.conf ''; @@ -95,7 +95,7 @@ stdenv.mkDerivation rec { '' -v -no-separate-debug-info -release -no-fast -confirm-license -opensource - -opengl -xrender -xrandr -xinerama -xcursor -xinput -xfixes -fontconfig + -${if stdenv.isFreeBSD then "no-" else ""}opengl -xrender -xrandr -xinerama -xcursor -xinput -xfixes -fontconfig -qdbus -${if cups == null then "no-" else ""}cups -glib -dbus-linked -openssl-linked ${if mysql != null then "-plugin" else "-no"}-sql-mysql -system-sqlite @@ -122,17 +122,18 @@ stdenv.mkDerivation rec { # The following libraries are only used in plugins buildInputs = [ cups # Qt dlopen's libcups instead of linking to it - mysql.lib postgresql sqlite libjpeg libmng libtiff icu ] + postgresql sqlite libjpeg libmng libtiff icu ] + ++ optionals (mysql != null) [ mysql.lib ] ++ optionals gtkStyle [ gtk gdk_pixbuf ]; nativeBuildInputs = [ perl pkgconfig which ]; enableParallelBuilding = false; - NIX_CFLAGS_COMPILE = optionalString stdenv.isDarwin + NIX_CFLAGS_COMPILE = optionalString (stdenv.isFreeBSD || stdenv.isDarwin) "-I${glib}/include/glib-2.0 -I${glib}/lib/glib-2.0/include"; - NIX_LDFLAGS = optionalString stdenv.isDarwin + NIX_LDFLAGS = optionalString (stdenv.isFreeBSD || stdenv.isDarwin) "-lglib-2.0"; preBuild = optionalString stdenv.isDarwin '' |