From 98e5e1ddc5f7f75eea7622dbdbd67bada1cd00ef Mon Sep 17 00:00:00 2001 From: Daniel Stone Date: Wed, 15 Apr 2020 12:27:41 +0100 Subject: dependencies/cmake: Add Windows/VS library regex When finding dependencies from CMake, use a smarter regex to determine whether or not a dependency is actually a link argument, and pass through Windows link arguments properly. --- mesonbuild/dependencies/base.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mesonbuild/dependencies/base.py b/mesonbuild/dependencies/base.py index 50f4179..068e45e 100644 --- a/mesonbuild/dependencies/base.py +++ b/mesonbuild/dependencies/base.py @@ -1411,7 +1411,8 @@ class CMakeDependency(ExternalDependency): 'Valid targets are:\n{}'.format(name, list(self.traceparser.targets.keys()))) # Set dependencies with CMake targets - reg_is_lib = re.compile(r'^(-l[a-zA-Z0-9_]+|-pthread)$') + # recognise arguments we should pass directly to the linker + reg_is_lib = re.compile(r'^(-l[a-zA-Z0-9_]+|-pthread|-delayload:[a-zA-Z0-9_\.]+|[a-zA-Z0-9_]+\.lib)$') processed_targets = [] incDirs = [] compileDefinitions = [] -- cgit v1.1