qt6.{qtdoc,qttools}: pin LLVM 20, misc cleanups (#444219)
This commit is contained in:
@@ -16,12 +16,7 @@ qtModule {
|
||||
'';
|
||||
nativeBuildInputs = [ (qttools.override { withClang = true; }) ];
|
||||
propagatedBuildInputs = [ qtdeclarative ];
|
||||
cmakeFlags = [
|
||||
"-DCMAKE_MESSAGE_LOG_LEVEL=STATUS"
|
||||
];
|
||||
dontUseNinjaBuild = true;
|
||||
buildFlags = [ "docs" ];
|
||||
dontUseNinjaInstall = true;
|
||||
installFlags = [ "install_docs" ];
|
||||
outputs = [ "out" ];
|
||||
|
||||
ninjaFlags = [ "docs" ];
|
||||
installTargets = [ "install_docs" ];
|
||||
}
|
||||
|
||||
@@ -6,32 +6,18 @@
|
||||
qtbase,
|
||||
qtdeclarative,
|
||||
cups,
|
||||
llvmPackages,
|
||||
llvmPackages_20,
|
||||
# clang-based c++ parser for qdoc and lupdate
|
||||
withClang ? false,
|
||||
}:
|
||||
|
||||
qtModule {
|
||||
pname = "qttools";
|
||||
buildInputs = lib.optionals withClang [
|
||||
llvmPackages.libclang
|
||||
llvmPackages.llvm
|
||||
];
|
||||
propagatedBuildInputs = [
|
||||
qtbase
|
||||
qtdeclarative
|
||||
]
|
||||
++ lib.optionals stdenv.hostPlatform.isDarwin [ cups ];
|
||||
cmakeFlags = lib.optionals (!stdenv.buildPlatform.canExecute stdenv.hostPlatform) [
|
||||
"-DQt6LinguistTools_DIR=${pkgsBuildBuild.qt6.qttools}/lib/cmake/Qt6LinguistTools"
|
||||
"-DQt6ToolsTools_DIR=${pkgsBuildBuild.qt6.qttools}/lib/cmake/Qt6ToolsTools"
|
||||
];
|
||||
|
||||
patches = [
|
||||
./paths.patch
|
||||
];
|
||||
env.NIX_CFLAGS_COMPILE = toString [
|
||||
"-DNIX_OUTPUT_OUT=\"${placeholder "out"}\""
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace \
|
||||
src/qdoc/catch/CMakeLists.txt \
|
||||
@@ -39,6 +25,32 @@ qtModule {
|
||||
src/qdoc/catch_conversions/CMakeLists.txt \
|
||||
--replace ''\'''${CMAKE_INSTALL_INCLUDEDIR}' "$out/include"
|
||||
'';
|
||||
|
||||
env.NIX_CFLAGS_COMPILE = toString [
|
||||
"-DNIX_OUTPUT_OUT=\"${placeholder "out"}\""
|
||||
];
|
||||
|
||||
# FIXME: update to LLVM 21 with Qt 6.10
|
||||
buildInputs = lib.optionals withClang [
|
||||
llvmPackages_20.libclang
|
||||
llvmPackages_20.llvm
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
qtbase
|
||||
qtdeclarative
|
||||
]
|
||||
++ lib.optionals stdenv.hostPlatform.isDarwin [ cups ];
|
||||
|
||||
cmakeFlags =
|
||||
lib.optionals (!stdenv.buildPlatform.canExecute stdenv.hostPlatform) [
|
||||
"-DQt6LinguistTools_DIR=${pkgsBuildBuild.qt6.qttools}/lib/cmake/Qt6LinguistTools"
|
||||
"-DQt6ToolsTools_DIR=${pkgsBuildBuild.qt6.qttools}/lib/cmake/Qt6ToolsTools"
|
||||
]
|
||||
++ lib.optionals withClang [
|
||||
"-DFEATURE_clang=ON"
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
mkdir -p "$dev"
|
||||
ln -s "$out/bin" "$dev/bin"
|
||||
|
||||
Reference in New Issue
Block a user