From Mathieu Marache, "Suibject: CMakeList ADD_DEFINITION for CMAKE_DEBUG_POSTFIX broken

I needed a -DCMAKE_DEBUG_POSTFIX="d" not a -D"CMAKE_DEBUG_POSTFIX=d".

This corrects the build for the CMake 2.4 and 2.6 series

The error was in compiling osgDB/Registry.cpp
"
This commit is contained in:
Robert Osfield 2008-06-23 11:14:06 +00:00
parent 87b74c1f54
commit 62fb2d4634

View File

@ -349,9 +349,9 @@ ENDIF("${CMAKE_SOURCE_DIR}" STREQUAL "${CMAKE_BINARY_DIR}")
SET(CMAKE_DEBUG_POSTFIX "d" CACHE STRING "add a postfix, usually d on windows") SET(CMAKE_DEBUG_POSTFIX "d" CACHE STRING "add a postfix, usually d on windows")
IF(${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} GREATER 4) IF(${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} GREATER 4)
ADD_DEFINITIONS("-DOSG_DEBUG_POSTFIX=${CMAKE_DEBUG_POSTFIX} ") ADD_DEFINITIONS(-DOSG_DEBUG_POSTFIX="${CMAKE_DEBUG_POSTFIX}")
ELSE(${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} GREATER 4) ELSE(${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} GREATER 4)
ADD_DEFINITIONS("-DOSG_DEBUG_POSTFIX='\"${CMAKE_DEBUG_POSTFIX}\"'") ADD_DEFINITIONS(-DOSG_DEBUG_POSTFIX='\"${CMAKE_DEBUG_POSTFIX}\"')
ENDIF(${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} GREATER 4) ENDIF(${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} GREATER 4)
IF(UNIX AND NOT WIN32 AND NOT APPLE) IF(UNIX AND NOT WIN32 AND NOT APPLE)
IF(CMAKE_BUILD_TYPE STREQUAL "Debug") IF(CMAKE_BUILD_TYPE STREQUAL "Debug")