3
0
Fork 0
forked from mirrors/nixpkgs

Qt 4.6: add more SQL backends and libXi

Also install qch docs by default

svn path=/nixpkgs/trunk/; revision=21605
This commit is contained in:
Yury G. Kudryashov 2010-05-05 18:17:25 +00:00
parent d21dc14966
commit b8186141e3
2 changed files with 29 additions and 17 deletions
pkgs
development/libraries/qt-4.6
top-level

View file

@ -1,10 +1,12 @@
{ stdenv, fetchurl, lib
, libXft, libXrender, randrproto, xextproto, libXinerama, xineramaproto, libXcursor, libXmu
, libXext, libXfixes, inputproto, fixesproto, libXrandr, freetype, fontconfig
, zlib, libjpeg, mysql, libpng, which, mesa, openssl, dbus, cups, pkgconfig, libtiff, glib
, buildDemos ? false, buildExamples ? false, keepDocumentation ? false}:
, zlib, libjpeg, libpng, which, mesa, openssl, dbus, cups, pkgconfig, libtiff, glib
, mysql, postgresql
, perl, coreutils, libXi, sqlite, alsaLib
, buildDemos ? false, buildExamples ? false, useDocs ? true}:
stdenv.mkDerivation {
stdenv.mkDerivation rec {
name = "qt-4.6.2";
src = fetchurl {
@ -12,16 +14,24 @@ stdenv.mkDerivation {
sha256 = "1bpz59y907zz2p67mnf5ckvxh7n2glr6pz1f9fmngkkdn3fm2vqp";
};
setupHook = ./setup-hook.sh;
preConfigure = ''
export LD_LIBRARY_PATH="`pwd`/lib:$LD_LIBRARY_PATH"
configureFlags+="
-docdir $out/share/doc/${name}
-plugindir $out/lib/qt4/plugins
-examplesdir $out/share/doc/${name}/examples
-demosdir $out/share/doc/${name}/demos
-datadir $out/share/qt4
"
'';
propagatedBuildInputs = [
alsaLib
sqlite
libXft
libXrender
libXrandr
libXi
randrproto
xextproto
libXinerama
@ -30,6 +40,7 @@ stdenv.mkDerivation {
zlib
libjpeg
mysql
postgresql
libpng
which
mesa
@ -48,6 +59,8 @@ stdenv.mkDerivation {
libtiff
];
buildInputs = [ perl ];
# libQtNetwork will call libQtCore for it to dlopen openssl.
NIX_LDFLAGS = "-rpath ${openssl}/lib";
# Don't shrink the rpath, to keep ${openssl} in it.
@ -59,29 +72,27 @@ stdenv.mkDerivation {
-v -no-separate-debug-info -release
-system-zlib -system-libpng -system-libjpeg -fast
-qt-gif -confirm-license -opensource
-opengl -xrender -xrandr -xinerama -xcursor -qt-sql-mysql
-opengl -xrender -xrandr -xinerama -xcursor -qt-sql-mysql -system-sqlite
-qdbus -cups -glib -xfixes -dbus-linked
-fontconfig -I${freetype}/include/freetype2
-exceptions -xmlpatterns
${if buildDemos == true then "" else "-nomake demos"}
${if buildExamples == true then "" else "-nomake examples"}
${if useDocs then "" else "-nomake docs"}
'';
patchPhase = ''
substituteInPlace configure --replace /bin/pwd pwd
substituteInPlace src/corelib/global/global.pri --replace /bin/ls ${coreutils}/bin/ls
sed -e 's@/usr@/FOO@' -i config.tests/*/*.test -i mkspecs/*/*.conf
'';
# Remove the documentation: it takes up >= 130 MB, which is more
# than half of the installed size. Ideally we should put this in a
# separate package (as well as the Qt Designer).
postInstall = ''
${if keepDocumentation == false then "rm -rf $out/doc" else ""}
'';
postInstall = if useDocs then "rm -rf $out/share/doc/${name}/{html,src}" else "";
meta = {
homepage = http://www.qtsoftware.com/downloads/opensource/appdev/linux-x11-cpp;
homepage = http://qt.nokia.com/products;
description = "A cross-platform application framework for C++";
license = "GPL/LGPL";
maintainers = [ lib.maintainers.sander ];
maintainers = with lib.maintainers; [ sander urkud ];
};
}

View file

@ -5012,11 +5012,12 @@ let
inherit (gnome) glib;
};
qt46 = import ../development/libraries/qt-4.6 {
qt46 = makeOverridable (import ../development/libraries/qt-4.6) {
inherit fetchurl stdenv lib zlib libjpeg libpng which mysql mesa openssl cups dbus
fontconfig freetype pkgconfig libtiff;
fontconfig freetype pkgconfig libtiff perl coreutils sqlite alsaLib
postgresql;
inherit (xlibs) xextproto libXft libXrender libXrandr randrproto
libXmu libXinerama xineramaproto libXcursor libXext
libXmu libXinerama xineramaproto libXcursor libXext libXi
inputproto fixesproto libXfixes;
inherit (gnome) glib;
};