Honor module .def files with MinGW tools (#9997)

Since commit 024d05ad (Fix use of module .def files for MS tools,
2009-09-29) module .def files work for any platform that sets
CMAKE_LINK_DEF_FILE_FLAG correctly.  Set it in the Windows-GNU platform
information file to enable support with MinGW tools.  Also enable the
test added by commit 0db2c850 (Test use of module .def files for MS
tools, 2009-09-29) for MinGW and MSYS generators.
This commit is contained in:
Brad King 2011-02-21 13:30:10 -05:00
parent 1ca15f85f1
commit 6a61a8a538
2 changed files with 5 additions and 1 deletions

View File

@ -43,6 +43,7 @@ endif()
set(CMAKE_DL_LIBS "")
set(CMAKE_LIBRARY_PATH_FLAG "-L")
set(CMAKE_LINK_LIBRARY_FLAG "-l")
set(CMAKE_LINK_DEF_FILE_FLAG "-Wl,")
set(CMAKE_LINK_LIBRARY_SUFFIX "")
set(CMAKE_CREATE_WIN32_EXE "-mwindows")

View File

@ -1082,8 +1082,11 @@ ${CMake_BINARY_DIR}/bin/cmake -DVERSION=master -P ${CMake_SOURCE_DIR}/Utilities/
IF(CMAKE_TEST_MSVC)
ADD_TEST_MACRO(ForceInclude foo)
ADD_TEST_MACRO(PrecompiledHeader foo)
ENDIF()
IF(CMAKE_TEST_MSVC OR
"${CMAKE_TEST_GENERATOR}" MATCHES "(MSYS|MinGW) Makefiles")
ADD_TEST_MACRO(ModuleDefinition example_exe)
ENDIF(CMAKE_TEST_MSVC)
ENDIF()
ADD_TEST_MACRO(CheckCompilerRelatedVariables CheckCompilerRelatedVariables)