From Luigi Calori, build fixes for Win32 build osg WxWidgets example

This commit is contained in:
Robert Osfield 2007-05-25 13:15:00 +00:00
parent 74d19eed34
commit 32931f90a8
2 changed files with 11 additions and 2 deletions

View File

@ -152,8 +152,11 @@ MACRO(SETUP_EXE IS_COMMANDLINE_APP)
ENDIF(NOT TARGET_LABEL)
IF(${IS_COMMANDLINE_APP})
ADD_EXECUTABLE(${TARGET_TARGETNAME} ${TARGET_SRC} ${TARGET_H})
ELSE(${IS_COMMANDLINE_APP})
IF(APPLE)
# SET(MACOSX_BUNDLE_LONG_VERSION_STRING "${OPENSCENEGRAPH_MAJOR_VERSION}.${OPENSCENEGRAPH_MINOR_VERSION}.${OPENSCENEGRAPH_PATCH_VERSION}")
# Short Version is the "marketing version". It is the version
@ -167,8 +170,13 @@ MACRO(SETUP_EXE IS_COMMANDLINE_APP)
# SET(MACOSX_BUNDLE_COPYRIGHT "")
# SET(MACOSX_BUNDLE_INFO_STRING "Info string, localized?")
ENDIF(APPLE)
IF(WIN32 AND REQUIRE_WINMAIN_FLAG)
ADD_EXECUTABLE(${TARGET_TARGETNAME} WIN32 ${TARGET_SRC} ${TARGET_H})
ELSE(WIN32 AND REQUIRE_WINMAIN_FLAG)
ADD_EXECUTABLE(${TARGET_TARGETNAME} MACOSX_BUNDLE ${TARGET_SRC} ${TARGET_H})
ENDIF(WIN32 AND REQUIRE_WINMAIN_FLAG)
ADD_EXECUTABLE(${TARGET_TARGETNAME} MACOSX_BUNDLE ${TARGET_SRC} ${TARGET_H})
ENDIF(${IS_COMMANDLINE_APP})
SET_TARGET_PROPERTIES(${TARGET_TARGETNAME} PROPERTIES PROJECT_LABEL "${TARGET_LABEL}")
SET_TARGET_PROPERTIES(${TARGET_TARGETNAME} PROPERTIES DEBUG_POSTFIX ${CMAKE_DEBUG_POSTFIX})

View File

@ -6,6 +6,7 @@ INCLUDE(${wxWidgets_USE_FILE})
#### end var setup ###
SETUP_EXAMPLE(osgsimpleviewerWX 1)
SET(REQUIRE_WINMAIN_FLAG ON)
SETUP_EXAMPLE(osgsimpleviewerWX)
TARGET_LINK_LIBRARIES("${TARGET_DEFAULT_PREFIX}osgsimpleviewerWX" ${wxWidgets_LIBRARIES})