summaryrefslogtreecommitdiff
path: root/mesonbuild/backend
diff options
context:
space:
mode:
authorEli Schwartz <eschwartz93@gmail.com>2025-03-20 12:16:06 -0400
committerEli Schwartz <eschwartz93@gmail.com>2025-03-20 13:44:41 -0400
commite5286aefd962df25dee58556c4ce6dafa4bfd1c3 (patch)
treeec418b03e473dba3126b55cab72389c594017e48 /mesonbuild/backend
parentd8f68703b792ff6e9cfc2674fdf9bbd53ac170ca (diff)
downloadmeson-e5286aefd962df25dee58556c4ce6dafa4bfd1c3.tar.gz
handle monorepo license files specified in project() via ../
We should simply remap these to elide the ../ as it's pretty obviously the natural expectation of using ../ to fetch files from outside the project and then drop them *into* the project. Monorepos will likely have a single license file (or set) under which the monorepo is licensed. But there will be many components, each of which may use a different build system, which are "standalone" for the most part. We already support this case as long as you build from the monorepo, but the resulting license file gets installed to ``` {licensedir}/../ ``` which is silly and unhelpful. Bug: https://github.com/apache/arrow/issues/36411
Diffstat (limited to 'mesonbuild/backend')
-rw-r--r--mesonbuild/backend/backends.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/mesonbuild/backend/backends.py b/mesonbuild/backend/backends.py
index feb002e54..a960537a8 100644
--- a/mesonbuild/backend/backends.py
+++ b/mesonbuild/backend/backends.py
@@ -1354,9 +1354,9 @@ class Backend:
d.data.append(InstallDataBase(ifilename, ofilename, out_name, None, '',
tag='devel', data_type='depmf'))
for m in self.build.dep_manifest.values():
- for ifilename, name in m.license_files:
- ofilename = os.path.join(odirname, name.relative_name())
- out_name = os.path.join(out_dir, name.relative_name())
+ for ifilename, name in m.license_mapping():
+ ofilename = os.path.join(odirname, name)
+ out_name = os.path.join(out_dir, name)
d.data.append(InstallDataBase(ifilename, ofilename, out_name, None,
m.subproject, tag='devel', data_type='depmf'))