nixpkgs-suyu/pkgs/development/libraries/qt-5/qt-env.nix
Nikolay Amiantov 99a83fbe1d qt5.env: use buildEnv
This both simplifies the code and ensures that libraries are linked too.
2017-02-03 18:16:51 +03:00

22 lines
493 B
Nix

{ lib, buildEnv, qtbase }: name: paths:
buildEnv {
inherit name;
paths = [ qtbase ] ++ paths;
pathsToLink = [ "/bin" "/mkspecs" "/include" "/lib" "/share" ];
extraOutputsToInstall = [ "dev" ];
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
'';
}