From a2bc47df1a55530cb370590003836033d1b31e13 Mon Sep 17 00:00:00 2001 From: Brad King Date: Wed, 27 Feb 2013 15:33:39 -0500 Subject: [PATCH] Recognize ld with toolchain prefix (#13960) Teach CMAKE_PARSE_IMPLICIT_LINK_INFO to recognize linker invocations of the form "-ld" e.g. "x86_64-pc-linux-gnu-ld". --- Modules/CMakeParseImplicitLinkInfo.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Modules/CMakeParseImplicitLinkInfo.cmake b/Modules/CMakeParseImplicitLinkInfo.cmake index 80e02188a..fa03630d3 100644 --- a/Modules/CMakeParseImplicitLinkInfo.cmake +++ b/Modules/CMakeParseImplicitLinkInfo.cmake @@ -29,7 +29,7 @@ function(CMAKE_PARSE_IMPLICIT_LINK_INFO text lib_var dir_var fwk_var log_var obj endif() # Construct a regex to match linker lines. It must match both the # whole line and just the command (argv[0]). - set(linker_regex "^( *|.*[/\\])(${linker}|ld|collect2)[^/\\]*( |$)") + set(linker_regex "^( *|.*[/\\])(${linker}|([^/\\]+-)?ld|collect2)[^/\\]*( |$)") set(linker_exclude_regex "collect2 version ") set(log "${log} link line regex: [${linker_regex}]\n") string(REGEX REPLACE "\r?\n" ";" output_lines "${text}")