From 3e84e78c3fcd2575a4159c3a1619833a7a80ef17 Mon Sep 17 00:00:00 2001 From: Chuck Atkins Date: Wed, 3 Sep 2014 17:00:48 -0400 Subject: Use a more reliable regex for extracting binary INFO strings A few different regular expressions were being used in various places to extract info strings from binaries. This uses a consistent regex amongst all of them now. This also fixes the broken ABI detection for Cray compilers. --- Modules/FortranCInterface/Detect.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Modules/FortranCInterface') diff --git a/Modules/FortranCInterface/Detect.cmake b/Modules/FortranCInterface/Detect.cmake index ceb1db4a8c..bee7dae351 100644 --- a/Modules/FortranCInterface/Detect.cmake +++ b/Modules/FortranCInterface/Detect.cmake @@ -67,7 +67,7 @@ endif() set(FortranCInterface_SYMBOLS) if(FortranCInterface_EXE) file(STRINGS "${FortranCInterface_EXE}" _info_strings - LIMIT_COUNT 8 REGEX "INFO:[^[]*\\[") + LIMIT_COUNT 8 REGEX "INFO:[A-Za-z0-9_]+\\[[^]]*\\]") foreach(info ${_info_strings}) if("${info}" MATCHES "INFO:symbol\\[([^]]*)\\]") list(APPEND FortranCInterface_SYMBOLS ${CMAKE_MATCH_1}) -- cgit v1.2.1