diff options
author | Bill Hoffman <bill.hoffman@kitware.com> | 2002-11-14 01:11:26 (GMT) |
---|---|---|
committer | Bill Hoffman <bill.hoffman@kitware.com> | 2002-11-14 01:11:26 (GMT) |
commit | 26e05fc060810bd6dbf65e4a34992409244a2f8a (patch) | |
tree | a38bf84614918bb472bea78612ab7cf4e0de3a0a /Modules/Platform/Windows-bcc32.cmake | |
parent | c1c3149d162ed2071db76d1b1ad4740ebb4c129d (diff) | |
download | CMake-26e05fc060810bd6dbf65e4a34992409244a2f8a.zip CMake-26e05fc060810bd6dbf65e4a34992409244a2f8a.tar.gz CMake-26e05fc060810bd6dbf65e4a34992409244a2f8a.tar.bz2 |
fix shared builds on borland and add debug stuff for makefiles
Diffstat (limited to 'Modules/Platform/Windows-bcc32.cmake')
-rw-r--r-- | Modules/Platform/Windows-bcc32.cmake | 28 |
1 files changed, 17 insertions, 11 deletions
diff --git a/Modules/Platform/Windows-bcc32.cmake b/Modules/Platform/Windows-bcc32.cmake index 363f5e1..4ccd790 100644 --- a/Modules/Platform/Windows-bcc32.cmake +++ b/Modules/Platform/Windows-bcc32.cmake @@ -1,19 +1,25 @@ SET(CMAKE_LIBRARY_PATH_FLAG "-L") SET(CMAKE_LINK_LIBRARY_FLAG "") -SET(CMAKE_SHARED_LIBRARY_CXX_FLAGS "-tWR") - +SET(CMAKE_SHARED_BUILD_CXX_FLAGS "-tWR") + +SET(CMAKE_START_TEMP_FILE "@&&|\n") +SET(CMAKE_END_TEMP_FILE "\n|") +# uncomment these out to debug makefiles +#SET(CMAKE_START_TEMP_FILE "") +#SET(CMAKE_END_TEMP_FILE "") +#SET(CMAKE_VERBOSE_MAKEFILE 1) # create a shared C++ library SET(CMAKE_CXX_CREATE_SHARED_LIBRARY - "<CMAKE_CXX_COMPILER> @&&|\n-e<TARGET> -tWD -tWR <LINK_LIBRARIES> <LINK_FLAGS> <OBJECTS>\n|" - "implib @&&|\n-w <TARGET_BASE>.lib <TARGET_BASE>.dll\n|" + "<CMAKE_CXX_COMPILER> ${CMAKE_START_TEMP_FILE}-e<TARGET> -tWD -tWR <LINK_LIBRARIES> <LINK_FLAGS> <OBJECTS>${CMAKE_END_TEMP_FILE}" + "implib ${CMAKE_START_TEMP_FILE}-w <TARGET_BASE>.lib <TARGET_BASE>.dll${CMAKE_END_TEMP_FILE}" ) SET(CMAKE_CXX_CREATE_SHARED_MODULE ${CMAKE_CXX_CREATE_SHARED_LIBRARY}) # create a C shared library SET(CMAKE_C_CREATE_SHARED_LIBRARY - "<CMAKE_C_COMPILER> @&&|\n-e<TARGET> -tWD <LINK_LIBRARIES> <LINK_FLAGS> <OBJECTS>\n|" - "implib @&&|\n-w <TARGET_BASE>.lib <TARGET_BASE>.dll\n|" + "<CMAKE_C_COMPILER> ${CMAKE_START_TEMP_FILE}-e<TARGET> -tWD <LINK_LIBRARIES> <LINK_FLAGS> <OBJECTS>${CMAKE_END_TEMP_FILE}" + "implib ${CMAKE_START_TEMP_FILE}-w <TARGET_BASE>.lib <TARGET_BASE>.dll${CMAKE_END_TEMP_FILE}" ) # create a C shared module just copy the shared library rule @@ -21,26 +27,26 @@ SET(CMAKE_C_CREATE_SHARED_MODULE ${CMAKE_C_CREATE_SHARED_LIBRARY}) # create a C++ static library -SET(CMAKE_CXX_CREATE_STATIC_LIBRARY "tlib @&&|\n/p512 /a <TARGET> <OBJECTS_QUOTED>\n|") +SET(CMAKE_CXX_CREATE_STATIC_LIBRARY "tlib ${CMAKE_START_TEMP_FILE}/p512 /a <TARGET> <OBJECTS_QUOTED>${CMAKE_END_TEMP_FILE}") # create a C static library SET(CMAKE_C_CREATE_STATIC_LIBRARY ${CMAKE_CXX_CREATE_STATIC_LIBRARY}) # compile a C++ file into an object file SET(CMAKE_CXX_COMPILE_OBJECT - "<CMAKE_CXX_COMPILER> @&&|\n-DWIN32 -P -o<OBJECT> <FLAGS> -c <SOURCE>\n|") + "<CMAKE_CXX_COMPILER> ${CMAKE_START_TEMP_FILE}-DWIN32 -P <FLAGS> -o<OBJECT> -c <SOURCE>${CMAKE_END_TEMP_FILE}") # compile a C file into an object file SET(CMAKE_C_COMPILE_OBJECT - "<CMAKE_C_COMPILER> @&&|\n-DWIN32 -o<OBJECT> <FLAGS> -c <SOURCE>\n|") + "<CMAKE_C_COMPILER> ${CMAKE_START_TEMP_FILE}-DWIN32 -o<OBJECT> <FLAGS> -c <SOURCE>${CMAKE_END_TEMP_FILE}") SET(CMAKE_C_LINK_EXECUTABLE - "<CMAKE_C_COMPILER> @&&|\n-e<TARGET> <FLAGS> <CMAKE_C_LINK_FLAGS> <LINK_LIBRARIES> <OBJECTS> \n|") + "<CMAKE_C_COMPILER> &&|\n-e<TARGET> <LINK_FLAGS> <FLAGS> <CMAKE_C_LINK_FLAGS> <LINK_LIBRARIES> <OBJECTS> ${CMAKE_END_TEMP_FILE}") SET(CMAKE_CXX_LINK_EXECUTABLE - "<CMAKE_CXX_COMPILER> @&&|\n -e<TARGET> <FLAGS> <CMAKE_CXX_LINK_FLAGS> <LINK_LIBRARIES> <OBJECTS> \n|") + "<CMAKE_CXX_COMPILER> ${CMAKE_START_TEMP_FILE} <LINK_FLAGS> -e<TARGET> <FLAGS> <CMAKE_CXX_LINK_FLAGS> <LINK_LIBRARIES> <OBJECTS> ${CMAKE_END_TEMP_FILE}") SET (CMAKE_BUILD_TYPE Debug CACHE STRING "Choose the type of build, options are: Debug Release RelWithDebInfo MinSizeRel.") |