summary refs log tree commit diff
path: root/pkgs/development/libraries/qt-5
diff options
context:
space:
mode:
authorThomas Tuegel <ttuegel@gmail.com>2015-10-07 08:48:40 -0500
committerThomas Tuegel <ttuegel@gmail.com>2015-10-30 16:10:37 -0500
commitb44923561b49595d5f3d5727c1d3971029f9f6dc (patch)
treeb6c97fe208deed4b56c5d0cc1d3ad4d0f6553919 /pkgs/development/libraries/qt-5
parentb102fa5a07f0121a0a51455ffd045fac6e505e92 (diff)
downloadnixpkgs-b44923561b49595d5f3d5727c1d3971029f9f6dc.tar
nixpkgs-b44923561b49595d5f3d5727c1d3971029f9f6dc.tar.gz
nixpkgs-b44923561b49595d5f3d5727c1d3971029f9f6dc.tar.bz2
nixpkgs-b44923561b49595d5f3d5727c1d3971029f9f6dc.tar.lz
nixpkgs-b44923561b49595d5f3d5727c1d3971029f9f6dc.tar.xz
nixpkgs-b44923561b49595d5f3d5727c1d3971029f9f6dc.tar.zst
nixpkgs-b44923561b49595d5f3d5727c1d3971029f9f6dc.zip
qtbase: include current package in runtime paths
The runtime paths QT_PLUGIN_PATH, QML_IMPORT_PATH, QML2_IMPORT_PATH, and
XDG_DATA_DIRS did not include the appropriate paths from the current
package being built because addToSearchPath does not add directories
which don't exist.
Diffstat (limited to 'pkgs/development/libraries/qt-5')
-rw-r--r--pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh9
1 files changed, 5 insertions, 4 deletions
diff --git a/pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh b/pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh
index 9f1bafc9f49..15d4818ccc7 100644
--- a/pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh
+++ b/pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh
@@ -88,10 +88,11 @@ Documentation = share/doc/qt5
 EOF
 
 export QMAKE="$qtOut/bin/qmake"
-addToSearchPath QT_PLUGIN_PATH "$out/lib/qt5/plugins"
-addToSearchPath QML_IMPORT_PATH "$out/lib/qt5/imports"
-addToSearchPath QML2_IMPORT_PATH "$out/lib/qt5/qml"
-addToSearchPath XDG_DATA_DIRS "$out/share"
+# cannot use addToSearchPath because these directories may not exist yet
+export QT_PLUGIN_PATH="$QT_PLUGIN_PATH${QT_PLUGIN_PATH:+:}$out/lib/qt5/plugins"
+export QML_IMPORT_PATH="$QML_IMPORT_PATH${QML_IMPORT_PATH:+:}$out/lib/qt5/imports"
+export QML2_IMPORT_PATH="$QML2_IMPORT_PATH${QML2_IMPORT_PATH:+:}$out/lib/qt5/qml"
+export XDG_DATA_DIRS="$XDG_DATA_DIRS${XDG_DATA_DIRS:+:}$out/share"
 
 envHooks+=(addQtModule)
 preConfigurePhases+=(setQMakePath)