summaryrefslogtreecommitdiff
path: root/mesonbuild/backend/xcodebackend.py
diff options
context:
space:
mode:
authorAlbert Tang <tangalbert919@yahoo.com>2023-09-20 12:39:19 -0500
committerEli Schwartz <eschwartz93@gmail.com>2024-01-26 00:42:24 -0500
commitdf6926250d39583d1289d91f0b06c5a980190320 (patch)
tree545a7fb45d659759c4128cf485e989c5bec85048 /mesonbuild/backend/xcodebackend.py
parentd2740cf0d1ce049bb77da24e0a620292b7ff424d (diff)
downloadmeson-df6926250d39583d1289d91f0b06c5a980190320.tar.gz
backends: Make object_filename_from_source() backend-agnostic
Some backends may need to use its own target directories instead of our default one. For this, introduce an optional argument "targetdir" that will still use our default one when not specified.
Diffstat (limited to 'mesonbuild/backend/xcodebackend.py')
-rw-r--r--mesonbuild/backend/xcodebackend.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/mesonbuild/backend/xcodebackend.py b/mesonbuild/backend/xcodebackend.py
index 989b2bf9a..c951819a5 100644
--- a/mesonbuild/backend/xcodebackend.py
+++ b/mesonbuild/backend/xcodebackend.py
@@ -230,7 +230,7 @@ class XCodeBackend(backends.Backend):
os.makedirs(os.path.join(self.environment.get_build_dir(), dirname), exist_ok=True)
return dirname
- def object_filename_from_source(self, target: build.BuildTarget, source: mesonlib.FileOrString) -> str:
+ def object_filename_from_source(self, target: build.BuildTarget, source: mesonlib.FileOrString, targetdir: T.Optional[str] = None) -> str:
# Xcode has the following naming scheme:
# projectname.build/debug/prog@exe.build/Objects-normal/x86_64/func.o
project = self.build.project_name