From 45f1508f390c2765161fe2f90565b2ff4ee40680 Mon Sep 17 00:00:00 2001 From: outfoxxed Date: Wed, 4 Sep 2024 20:58:36 -0700 Subject: [PATCH] qt6.qtdeclarative: replace the qmlc version tag with the store path --- pkgs/development/libraries/qt-6/modules/qtdeclarative.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/pkgs/development/libraries/qt-6/modules/qtdeclarative.nix b/pkgs/development/libraries/qt-6/modules/qtdeclarative.nix index 9b82169511dc0..1f007e11c46c3 100644 --- a/pkgs/development/libraries/qt-6/modules/qtdeclarative.nix +++ b/pkgs/development/libraries/qt-6/modules/qtdeclarative.nix @@ -22,6 +22,14 @@ qtModule { ../patches/0002-qtdeclarative-also-use-versioned-qml-paths.patch ]; + # Only qml files with a matching tag will be loaded by qtdeclarative, + # so it is set to the unique store path of the build. + # The maximum length of the tag is 48 bytes, so the path is trimmed to + # only /nix/store/. + preConfigure = '' + echo ''${out:0:43} > .tag + ''; + cmakeFlags = [ "-DQt6ShaderToolsTools_DIR=${pkgsBuildBuild.qt6.qtshadertools}/lib/cmake/Qt6ShaderTools" # for some reason doesn't get found automatically on Darwin