1 SET(CMAKE_LIBRARY_PATH_FLAG "-LIBPATH:")
2 SET(CMAKE_LINK_LIBRARY_FLAG "")
4 IF(CMAKE_VERBOSE_MAKEFILE)
6 ELSE(CMAKE_VERBOSE_MAKEFILE)
7 SET(CMAKE_CL_NOLOGO "/nologo")
8 ENDIF(CMAKE_VERBOSE_MAKEFILE)
10 SET(CMAKE_Fortran_MODDIR_FLAG "-module:")
12 SET(CMAKE_Fortran_CREATE_SHARED_LIBRARY
13 "link ${CMAKE_CL_NOLOGO} ${CMAKE_START_TEMP_FILE} /out:<TARGET> /dll <LINK_FLAGS> <OBJECTS> <LINK_LIBRARIES> ${CMAKE_END_TEMP_FILE}")
15 SET(CMAKE_Fortran_CREATE_SHARED_MODULE ${CMAKE_Fortran_CREATE_SHARED_LIBRARY})
17 # create a C++ static library
18 SET(CMAKE_Fortran_CREATE_STATIC_LIBRARY "lib ${CMAKE_CL_NOLOGO} <LINK_FLAGS> /out:<TARGET> <OBJECTS> ")
20 # compile a C++ file into an object file
21 SET(CMAKE_Fortran_COMPILE_OBJECT
22 "<CMAKE_Fortran_COMPILER> ${CMAKE_START_TEMP_FILE} ${CMAKE_CL_NOLOGO} /fpp /Fo<OBJECT> <DEFINES> <FLAGS> -c <SOURCE>${CMAKE_END_TEMP_FILE}")
24 SET(CMAKE_COMPILE_RESOURCE "rc <FLAGS> /fo<OBJECT> <SOURCE>")
26 SET(CMAKE_Fortran_LINK_EXECUTABLE
27 "<CMAKE_Fortran_COMPILER> ${CMAKE_CL_NOLOGO} ${CMAKE_START_TEMP_FILE} <FLAGS> <OBJECTS> /Fe<TARGET> -link <CMAKE_Fortran_LINK_FLAGS> <LINK_FLAGS> <LINK_LIBRARIES>${CMAKE_END_TEMP_FILE}")
29 SET(CMAKE_CREATE_WIN32_EXE /subsystem:windows)
30 SET(CMAKE_CREATE_CONSOLE_EXE /subsystem:console)
32 IF(CMAKE_GENERATOR MATCHES "Visual Studio 6")
33 SET (CMAKE_NO_BUILD_TYPE 1)
34 ENDIF(CMAKE_GENERATOR MATCHES "Visual Studio 6")
35 IF(CMAKE_GENERATOR MATCHES "Visual Studio 7" OR CMAKE_GENERATOR MATCHES "Visual Studio 8")
36 SET (CMAKE_NO_BUILD_TYPE 1)
37 SET (CMAKE_CONFIGURATION_TYPES "Debug;Release;MinSizeRel;RelWithDebInfo" CACHE STRING
38 "Semicolon separated list of supported configuration types, only supports Debug, Release, MinSizeRel, and RelWithDebInfo, anything else will be ignored.")
39 ENDIF(CMAKE_GENERATOR MATCHES "Visual Studio 7" OR CMAKE_GENERATOR MATCHES "Visual Studio 8")
40 # does the compiler support pdbtype and is it the newer compiler
42 SET(CMAKE_BUILD_TYPE_INIT Debug)
43 SET (CMAKE_Fortran_FLAGS_INIT "/W1")
44 SET (CMAKE_Fortran_FLAGS_DEBUG_INIT "/debug:full")
45 SET (CMAKE_Fortran_FLAGS_MINSIZEREL_INIT "/O2 /D NDEBUG")
46 SET (CMAKE_Fortran_FLAGS_RELEASE_INIT "/MD /O1 /D NDEBUG")
47 SET (CMAKE_Fortran_FLAGS_RELWITHDEBINFO_INIT "/O1 /debug:full /D NDEBUG")
49 SET (CMAKE_Fortran_STANDARD_LIBRARIES_INIT "user32.lib")
51 # executable linker flags
52 SET (CMAKE_LINK_DEF_FILE_FLAG "/DEF:")
53 SET (CMAKE_EXE_LINKER_FLAGS_INIT " /INCREMENTAL:YES")
54 IF (CMAKE_COMPILER_SUPPORTS_PDBTYPE)
55 SET (CMAKE_EXE_LINKER_FLAGS_DEBUG_INIT "/debug /pdbtype:sept")
56 SET (CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO_INIT "/debug /pdbtype:sept")
57 ELSE (CMAKE_COMPILER_SUPPORTS_PDBTYPE)
58 SET (CMAKE_EXE_LINKER_FLAGS_DEBUG_INIT "/debug")
59 SET (CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO_INIT "/debug")
60 ENDIF (CMAKE_COMPILER_SUPPORTS_PDBTYPE)
62 SET (CMAKE_SHARED_LINKER_FLAGS_INIT ${CMAKE_EXE_LINKER_FLAGS_INIT})
63 SET (CMAKE_SHARED_LINKER_FLAGS_DEBUG_INIT ${CMAKE_EXE_LINKER_FLAGS_DEBUG_INIT})
64 SET (CMAKE_SHARED_LINKER_FLAGS_RELWITHDEBINFO_INIT ${CMAKE_EXE_LINKER_FLAGS_DEBUG_INIT})
65 SET (CMAKE_MODULE_LINKER_FLAGS_INIT ${CMAKE_SHARED_LINKER_FLAGS_INIT})
66 SET (CMAKE_MODULE_LINKER_FLAGS_DEBUG_INIT ${CMAKE_SHARED_LINKER_FLAGS_DEBUG_INIT})
67 SET (CMAKE_MODULE_LINKER_FLAGS_RELWITHDEBINFO_INIT ${CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO_INIT})