Intel Fortran for Windows and IPO
Seems like CMAKE_Fortran_CREATE_STATIC_LIBRARY contains hardcoded lib
command. It leads to link errors when I try to use Fortran(ifort) library compiled with /Qipo
option in C++ project(MSVC). Currently I'm using this hack in my Fortran project:
project(Foo Fortran)
if(WIN32 AND ${CMAKE_Fortran_CREATE_STATIC_LIBRARY} MATCHES "^lib.*")
set(CMAKE_Fortran_CREATE_STATIC_LIBRARY "xi${CMAKE_Fortran_CREATE_STATIC_LIBRARY}") #use xilib instead of lib
endif()
But, I think, CMake should be able to do it without such hacks.
Edited by Brad King