From: Carl Keinath <carl.keinath@gmail.com>
Date: Wed, 27 Aug 2025 13:13:40 +0200
Subject: install-private-libs-into-qml-dir

Forwarded: Not-Needed
---
 cmake/install-qml-module.cmake | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/cmake/install-qml-module.cmake b/cmake/install-qml-module.cmake
index d7bec6f..12a3c99 100644
--- a/cmake/install-qml-module.cmake
+++ b/cmake/install-qml-module.cmake
@@ -43,7 +43,11 @@ function(install_qml_module arg_TARGET)
     # If installed to the module dir, inter-module dependencies will not work
     # due to broken rpaths. The standard fix for this seems to be to just
     # put the library in /lib.
-    install(TARGETS "${arg_TARGET}")
+    install(
+        TARGETS "${arg_TARGET}"
+        LIBRARY DESTINATION "${module_dir}"
+        RUNTIME DESTINATION "${module_dir}"
+    )
 
     install(
         TARGETS "${module_plugin_target}"
