summaryrefslogtreecommitdiff
path: root/Modules/FortranCInterface/IntelVSImplicitPath/extract.cmake
blob: 055247cfb6eb543a7dad347cd98cd699d2ab87fb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
file(STRINGS env.txt LIB REGEX "^LIB=.*$")
string(REPLACE "LIB=" "" LIB "${LIB}" )
# change LIB from a string to a ; separated list of paths
set(LIB ${LIB})
# look at each path and try to find ifconsol.lib
foreach( dir ${LIB})
  file(TO_CMAKE_PATH "${dir}" dir)
  if(EXISTS "${dir}/ifconsol.lib")
    file(WRITE implict_link.txt ${dir})
    return()
  endif()
endforeach()