diff --git a/mesonbuild/modules/external_project.py b/mesonbuild/modules/external_project.py index 4874f42aa6ee..6cc325b4f5c0 100644 --- a/mesonbuild/modules/external_project.py +++ b/mesonbuild/modules/external_project.py @@ -94,7 +94,7 @@ def __init__(self, # will install files into "c:/bar/c:/foo" which is an invalid path. # Work around that issue by removing the drive from prefix. if self.prefix.drive: - self.prefix = Path(relpath(self.prefix, self.prefix.drive)) + self.prefix = Path('/' + relpath(self.prefix, self.prefix.drive + '/')) # self.prefix is an absolute path, so we cannot append it to another path. self.rel_prefix = Path(relpath(self.prefix, self.prefix.root))