[sdk/kde-builder] kde_builder_lib/module: refactor: Compare global and project source-dir instead of resolved absolute paths

Andrew Shark <[email protected]>
Newsgroups gmane.comp.kde.cvs
Message-ID <[email protected]>
Git commit 16bc7aeb0726e9ac9d74fd1c4974a63ed8fbe3fa by Andrew Shark.
Committed on 31/07/2026 at 19:24.
Pushed by ashark into branch 'master'.

refactor: Compare global and project source-dir instead of resolved absolute paths

M  +2    -4    kde_builder_lib/module/module.py

https://invent.kde.org/sdk/kde-builder/-/commit/16bc7aeb0726e9ac9d74fd1c4974a63ed8fbe3fa

diff --git a/kde_builder_lib/module/module.py b/kde_builder_lib/module/module.py
index 65da41db..517db27e 100644
--- a/kde_builder_lib/module/module.py
+++ b/kde_builder_lib/module/module.py
@@ -470,10 +470,8 @@ class Module(PathResolvingOptions):
              False on failure, True on success.
         """
         module_name = self.name
-        module_src_dir = self.get_source_dir()
-        kdesrc = ctx.get_source_dir()
-
-        if kdesrc != module_src_dir:
+        if ctx.get_option("source-dir") != self.get_option("source-dir"):
+            module_src_dir = self.get_source_dir()
             # This module has a different source directory, ensure it exists.
             if not Util.super_mkdir(module_src_dir):
                 logger_module.error(f"\tUnable to create separate source directory for r[{self.name}]: {module_src_dir}")
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.