aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/modules/fs.py
diff options
context:
space:
mode:
authorMichael Hirsch, Ph.D <scivision@users.noreply.github.com>2019-11-17 00:22:53 -0500
committerMichael Hirsch, Ph.D <scivision@users.noreply.github.com>2019-11-17 00:22:53 -0500
commit0cb48cdc793dfce8c5eeb17e447cbe169e1836d7 (patch)
tree2a85b48a1b5f109612d8f3fc8723341679ef4480 /mesonbuild/modules/fs.py
parent2ae96f859583ed1aa1e78df73ba2895a2604fa8b (diff)
downloadmeson-0cb48cdc793dfce8c5eeb17e447cbe169e1836d7.zip
meson-0cb48cdc793dfce8c5eeb17e447cbe169e1836d7.tar.gz
meson-0cb48cdc793dfce8c5eeb17e447cbe169e1836d7.tar.bz2
fs: make replace_suffix not expand file to absolute path, just manipulate the string
Diffstat (limited to 'mesonbuild/modules/fs.py')
-rw-r--r--mesonbuild/modules/fs.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/mesonbuild/modules/fs.py b/mesonbuild/modules/fs.py
index 0c8ed8e..86861ae 100644
--- a/mesonbuild/modules/fs.py
+++ b/mesonbuild/modules/fs.py
@@ -114,7 +114,7 @@ class FSModule(ExtensionModule):
def replace_suffix(self, state: 'ModuleState', args: typing.Sequence[str], kwargs: dict) -> ModuleReturnValue:
if len(args) != 2:
MesonException('method takes exactly two arguments.')
- original = PurePath(state.source_root) / state.subdir / args[0]
+ original = PurePath(args[0])
new = original.with_suffix(args[1])
return ModuleReturnValue(str(new), [])