depot/third_party/nixpkgs/pkgs/development/libraries/qt-6/modules/qtdeclarative.nix
Default email c594a97518 Project import generated by Copybara.
GitOrigin-RevId: 301aada7a64812853f2e2634a530ef5d34505048
2022-10-21 20:38:19 +02:00

39 lines
864 B
Nix

{ qtModule
, qtbase
, qtshadertools
, openssl
, python3
}:
qtModule {
pname = "qtdeclarative";
qtInputs = [ qtbase qtshadertools ];
propagatedBuildInputs = [ openssl python3 ];
preConfigure = ''
export LD_LIBRARY_PATH="$PWD/build/lib''${LD_LIBRARY_PATH:+:}$LD_LIBRARY_PATH"
'';
cmakeFlags = [
"-DQT6_INSTALL_PREFIX=${placeholder "out"}"
"-DQT_INSTALL_PREFIX=${placeholder "out"}"
];
postInstall = ''
substituteInPlace "$out/lib/cmake/Qt6Qml/Qt6QmlMacros.cmake" \
--replace ''\'''${QT6_INSTALL_PREFIX}' "$dev"
'';
devTools = [
"bin/qml"
"bin/qmlcachegen"
"bin/qmleasing"
"bin/qmlimportscanner"
"bin/qmllint"
"bin/qmlmin"
"bin/qmlplugindump"
"bin/qmlprofiler"
"bin/qmlscene"
"bin/qmltestrunner"
];
NIX_CFLAGS_COMPILE = [
"-fmacro-prefix-map=${qtbase.dev}=qtbase.dev"
];
}