From Mourad Boufarguine, "With the present CMakeLists, the directory ${PROJECT_BINARY_DIR}/include is added to the include path before ${OpenSceneGraph_SOURCE_DIR}/include. This causes problems whenever a header file is changed when updating OSG, because cpp files are build against the old header files contained in ${PROJECT_BINARY_DIR}/include rather than the new ones in ${OpenSceneGraph_SOURCE_DIR}/include. Inverting the order of the two drectories in the include path solves the problem.
Attached is the modified CMakeLists.txt."
This commit is contained in:
parent
3d6b53b218
commit
60dd9ad7d0
@ -158,16 +158,16 @@ IF(UNIX)
|
||||
ENDIF( CMAKE_SYSTEM MATCHES "Linux" )
|
||||
ENDIF()
|
||||
|
||||
# Make the headers visible to everything
|
||||
IF(NOT ${PROJECT_BINARY_DIR} EQUAL ${PROJECT_SOURCE_DIR})
|
||||
INCLUDE_DIRECTORIES(${PROJECT_BINARY_DIR}/include)
|
||||
ENDIF()
|
||||
|
||||
INCLUDE_DIRECTORIES(
|
||||
${OpenSceneGraph_SOURCE_DIR}/include
|
||||
${OPENGL_INCLUDE_DIR}
|
||||
)
|
||||
|
||||
# Make the headers visible to everything
|
||||
IF(NOT ${PROJECT_BINARY_DIR} EQUAL ${PROJECT_SOURCE_DIR})
|
||||
INCLUDE_DIRECTORIES(${PROJECT_BINARY_DIR}/include)
|
||||
ENDIF()
|
||||
|
||||
# Common global definitions
|
||||
#ADD_DEFINITIONS(-D)
|
||||
# Platform specific definitions
|
||||
|
Loading…
Reference in New Issue
Block a user