Merge pull request #1872 from darktohka/cmake-regex-fix
[cmake] Fix CMake build on newer CMake versions
This commit is contained in:
commit
60d0fe2eda
|
@ -142,8 +142,8 @@ endif ()
|
||||||
|
|
||||||
## Extract variables from Makefile files
|
## Extract variables from Makefile files
|
||||||
function (extract_make_variable variable makefile_source)
|
function (extract_make_variable variable makefile_source)
|
||||||
string(REGEX MATCH "${variable} = ([^$]+)\\$" temp ${makefile_source})
|
string(REGEX MATCH "${variable} = ([^$]+)\\$" temp "${makefile_source}")
|
||||||
string(REGEX MATCHALL "[^ \n\t\\]+" listVar ${CMAKE_MATCH_1})
|
string(REGEX MATCHALL "[^ \n\t\\]+" listVar "${CMAKE_MATCH_1}")
|
||||||
set (${variable} ${listVar} PARENT_SCOPE)
|
set (${variable} ${listVar} PARENT_SCOPE)
|
||||||
endfunction ()
|
endfunction ()
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue