diff options
author | Thomas Tuegel <ttuegel@gmail.com> | 2017-02-03 09:57:58 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-02-03 09:57:58 -0600 |
commit | 74f5672a1ced6b1fd4857ad27a488ca5561874e1 (patch) | |
tree | 93d105998f309179b1309784a413251b5cd1d7bf | |
parent | 698f178d4ed1f04f58936fcfb1a0c0753ee69679 (diff) | |
parent | 8a67af13f46a75427958320f2d354294be8a1e62 (diff) | |
download | nixlib-74f5672a1ced6b1fd4857ad27a488ca5561874e1.tar nixlib-74f5672a1ced6b1fd4857ad27a488ca5561874e1.tar.gz nixlib-74f5672a1ced6b1fd4857ad27a488ca5561874e1.tar.bz2 nixlib-74f5672a1ced6b1fd4857ad27a488ca5561874e1.tar.lz nixlib-74f5672a1ced6b1fd4857ad27a488ca5561874e1.tar.xz nixlib-74f5672a1ced6b1fd4857ad27a488ca5561874e1.tar.zst nixlib-74f5672a1ced6b1fd4857ad27a488ca5561874e1.zip |
Merge pull request #22406 from abbradar/qtenv
Qt 5: Use buildEnv for env, don't use it for packages
-rw-r--r-- | pkgs/applications/audio/qjackctl/default.nix | 9 | ||||
-rw-r--r-- | pkgs/applications/misc/keepassx/community.nix | 4 | ||||
-rw-r--r-- | pkgs/applications/office/cb2bib/default.nix | 15 | ||||
-rw-r--r-- | pkgs/applications/video/vokoscreen/default.nix | 15 | ||||
-rw-r--r-- | pkgs/development/libraries/qt-5/qt-env.nix | 44 | ||||
-rw-r--r-- | pkgs/games/multimc/default.nix | 6 | ||||
-rw-r--r-- | pkgs/top-level/all-packages.nix | 12 |
7 files changed, 51 insertions, 54 deletions
diff --git a/pkgs/applications/audio/qjackctl/default.nix b/pkgs/applications/audio/qjackctl/default.nix index c84e5cdfb494..52b94ca07d9e 100644 --- a/pkgs/applications/audio/qjackctl/default.nix +++ b/pkgs/applications/audio/qjackctl/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, alsaLib, libjack2, dbus, qt5 }: +{ stdenv, fetchurl, alsaLib, libjack2, dbus, qtbase, qttools, qtx11extras }: stdenv.mkDerivation rec { version = "0.4.3"; @@ -12,14 +12,15 @@ stdenv.mkDerivation rec { }; buildInputs = [ - qt5.full - qt5.qtx11extras + qtbase + qtx11extras + qttools alsaLib libjack2 dbus ]; - configureFlags = "--enable-jack-version"; + configureFlags = [ "--enable-jack-version" ]; meta = with stdenv.lib; { description = "A Qt application to control the JACK sound server daemon"; diff --git a/pkgs/applications/misc/keepassx/community.nix b/pkgs/applications/misc/keepassx/community.nix index 075de4dcb652..58b45786c40e 100644 --- a/pkgs/applications/misc/keepassx/community.nix +++ b/pkgs/applications/misc/keepassx/community.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, cmake, libgcrypt, qt5, zlib, libmicrohttpd, libXtst }: +{ stdenv, fetchFromGitHub, cmake, libgcrypt, zlib, libmicrohttpd, libXtst, qtbase, qttools }: stdenv.mkDerivation rec { name = "keepassx-community-${version}"; @@ -11,7 +11,7 @@ stdenv.mkDerivation rec { sha256 = "0qwmi9f8ik3vkwl1kx7g3079h5ia4wl87y42nr5dal3ic1jc941p"; }; - buildInputs = [ cmake libgcrypt zlib qt5.full libXtst libmicrohttpd ]; + buildInputs = [ cmake libgcrypt zlib qtbase qttools libXtst libmicrohttpd ]; meta = { description = "Fork of the keepassX password-manager with additional http-interface to allow browser-integration an use with plugins such as PasslFox (https://github.com/pfn/passifox). See also keepassX2."; diff --git a/pkgs/applications/office/cb2bib/default.nix b/pkgs/applications/office/cb2bib/default.nix index aa246d241ca6..abff61b881fc 100644 --- a/pkgs/applications/office/cb2bib/default.nix +++ b/pkgs/applications/office/cb2bib/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt5Full, lzo, libX11 }: +{ stdenv, fetchurl, qmakeHook, qtbase, qtwebkit, qtx11extras, lzo, libX11 }: stdenv.mkDerivation rec { name = pname + "-" + version; @@ -8,10 +8,13 @@ stdenv.mkDerivation rec { url = "http://www.molspaces.com/dl/progs/${name}.tar.gz"; sha256 = "0yz79v023w1229wzck3gij0iqah1xg8rg4a352q8idvg7bdmyfin"; }; - buildInputs = [ qt5Full lzo libX11 ]; - QTDIR=qt5Full; - configurePhase ='' - ./configure --prefix $out + buildInputs = [ qtbase qtwebkit qtx11extras lzo libX11 ]; + nativeBuildInputs = [ qmakeHook ]; + + configurePhase = '' + runHook preConfigure + ./configure --prefix $out --qmakepath $QMAKE + runHook postConfigure ''; meta = with stdenv.lib; { @@ -21,4 +24,4 @@ stdenv.mkDerivation rec { license = licenses.gpl3; }; -} \ No newline at end of file +} diff --git a/pkgs/applications/video/vokoscreen/default.nix b/pkgs/applications/video/vokoscreen/default.nix index 7a9ea5f9095b..204580b108f7 100644 --- a/pkgs/applications/video/vokoscreen/default.nix +++ b/pkgs/applications/video/vokoscreen/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchgit -, pkgconfig, qt5, alsaLib, libv4l, xorg +, pkgconfig, qtbase, qttools, qmakeHook, qtx11extras, alsaLib, libv4l, libXrandr , ffmpeg }: @@ -12,13 +12,14 @@ stdenv.mkDerivation { }; buildInputs = [ - alsaLib.dev - libv4l.dev + alsaLib + libv4l pkgconfig - qt5.full - qt5.qmakeHook - qt5.qtx11extras - xorg.libXrandr.dev + qtbase + qttools + qmakeHook + qtx11extras + libXrandr ]; patches = [ diff --git a/pkgs/development/libraries/qt-5/qt-env.nix b/pkgs/development/libraries/qt-5/qt-env.nix index b2b7121d51d5..fad68fbd7450 100644 --- a/pkgs/development/libraries/qt-5/qt-env.nix +++ b/pkgs/development/libraries/qt-5/qt-env.nix @@ -1,28 +1,22 @@ -{ lib, runCommand, lndir, qtbase }: name: paths: +{ lib, buildEnv, qtbase }: name: paths: -runCommand name { qtbase = qtbase.dev; paths = lib.chooseDevOutputs paths; } '' +buildEnv { + inherit name; + paths = [ qtbase ] ++ paths; -mkdir -p "$out/bin" "$out/mkspecs" "$out/include" "$out/lib" "$out/share" + pathsToLink = [ "/bin" "/mkspecs" "/include" "/lib" "/share" ]; + extraOutputsToInstall = [ "dev" ]; -cp "$qtbase/bin/qmake" "$out/bin" -cat >"$out/bin/qt.conf" <<EOF -[Paths] -Prefix = $out -Plugins = lib/qt5/plugins -Imports = lib/qt5/imports -Qml2Imports = lib/qt5/qml -Documentation = share/doc/qt5 -EOF - -for pkg in $paths $qtbase; do - if [[ -d "$pkg/mkspecs" ]]; then - ${lndir}/bin/lndir -silent "$pkg/mkspecs" "$out/mkspecs" - - for dir in bin include lib share; do - if [[ -d "$pkg/$dir" ]]; then - ${lndir}/bin/lndir -silent "$pkg/$dir" "$out/$dir" - fi - done - fi -done -'' + postBuild = '' + rm "$out/bin/qmake" + cp "${qtbase.dev}/bin/qmake" "$out/bin" + cat >"$out/bin/qt.conf" <<EOF + [Paths] + Prefix = $out + Plugins = lib/qt5/plugins + Imports = lib/qt5/imports + Qml2Imports = lib/qt5/qml + Documentation = share/doc/qt5 + EOF + ''; +} diff --git a/pkgs/games/multimc/default.nix b/pkgs/games/multimc/default.nix index 71c7e300a639..67f0a87df659 100644 --- a/pkgs/games/multimc/default.nix +++ b/pkgs/games/multimc/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, cmake, qt5Full, jdk, zlib, file, makeWrapper, xorg, libpulseaudio, qt5 }: +{ stdenv, fetchFromGitHub, cmake, jdk, zlib, file, makeWrapper, xorg, libpulseaudio, qtbase, quazip }: let libnbt = fetchFromGitHub { @@ -16,7 +16,7 @@ stdenv.mkDerivation { rev = "895d8ab4699f1b50bf03532c967a91f5ecb62a50"; sha256 = "179vc1iv57fx4g4h1wy8yvyvdm671jnvp6zi8pcr1n6azqhwklds"; }; - buildInputs = [ cmake qt5Full jdk zlib file makeWrapper ]; + buildInputs = [ cmake qtbase jdk zlib file makeWrapper ]; libpath = with xorg; [ libX11 libXext libXcursor libXrandr libXxf86vm libpulseaudio ]; postUnpack = '' @@ -24,7 +24,7 @@ stdenv.mkDerivation { cp -r ${libnbt} $sourceRoot/depends/libnbtplusplus chmod 755 -R $sourceRoot/depends/libnbtplusplus mkdir -pv $sourceRoot/build/ - cp -v ${qt5.quazip.src} $sourceRoot/build/quazip-0.7.1.tar.gz + cp -v ${quazip.src} $sourceRoot/build/quazip-0.7.1.tar.gz ''; patches = [ ./multimc.patch ]; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index cfbd552a3aac..b0ae2343e23a 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -12632,9 +12632,7 @@ with pkgs; cava = callPackage ../applications/audio/cava { }; - cb2bib = callPackage ../applications/office/cb2bib { - inherit (xorg) libX11; - }; + cb2bib = qt5.callPackage ../applications/office/cb2bib { }; cbatticon = callPackage ../applications/misc/cbatticon { }; @@ -13147,7 +13145,7 @@ with pkgs; keepassx = callPackage ../applications/misc/keepassx { }; keepassx2 = callPackage ../applications/misc/keepassx/2.0.nix { }; - keepassx-community = callPackage ../applications/misc/keepassx/community.nix { }; + keepassx-community = qt5.callPackage ../applications/misc/keepassx/community.nix { }; inherit (gnome3) evince; evolution_data_server = gnome3.evolution_data_server; @@ -14674,7 +14672,7 @@ with pkgs; qgroundcontrol = qt55.callPackage ../applications/science/robotics/qgroundcontrol { }; - qjackctl = callPackage ../applications/audio/qjackctl { }; + qjackctl = qt5.callPackage ../applications/audio/qjackctl { }; qmidinet = callPackage ../applications/audio/qmidinet { }; @@ -16139,7 +16137,7 @@ with pkgs; minecraft-server = callPackage ../games/minecraft-server { }; - multimc = callPackage ../games/multimc { }; + multimc = qt5.callPackage ../games/multimc { }; minetest = callPackage ../games/minetest { libpng = libpng12; @@ -17837,7 +17835,7 @@ with pkgs; vips = callPackage ../tools/graphics/vips { }; nip2 = callPackage ../tools/graphics/nip2 { }; - vokoscreen = callPackage ../applications/video/vokoscreen { }; + vokoscreen = qt5.callPackage ../applications/video/vokoscreen { }; wavegain = callPackage ../applications/audio/wavegain { }; |