Hi Robert,

On 18 November 2014 18:17, Robert Graf <[email protected]> wrote:

> Hi Robert, thanks for checking in. Setting OSG_WINDOWING_SYSTEM to "Cocoa"
> in CMake resolves the linker issue.
>
> Currently, the CMake build configuration defaults OSG_WINDOWING_SYSTEM to
> "Carbon" when building on OSX, but when examples are built, the linker
> fails as indicated in this forum thread.
>
> It looks like a solution is to use Carbon for <= OSX 10.4 and Cocoa > OSX
> 10.4, as indicated in the thread link below:
>
> http:// t34445. graphics-openscenegraph-cvs. graphictalk.
> info/using-cocoa-by-default-on-10-x-x-5-t34445. html
>

The OSG should only be building Carbon for OSX 10.4 and before, otherwise
it should be building against Cocoa.  The relevant section in the
src/osgViewer/CMakeLists.txt is:

    IF(APPLE AND NOT ANDROID)

        IF(OSG_BUILD_PLATFORM_IPHONE OR OSG_BUILD_PLATFORM_IPHONE_SIMULATOR)
            SET(OSG_WINDOWING_SYSTEM "IOS" CACHE STRING "Windowing system
type for graphics window creation, options only IOS.")
        ELSE()
            IF(${OSG_OSX_SDK_NAME} STREQUAL "macosx10.4" OR
               ${OSG_OSX_SDK_NAME} STREQUAL "macosx10.3" OR
               ${OSG_OSX_SDK_NAME} STREQUAL "macosx10.2" OR
               ${OSG_OSX_SDK_NAME} STREQUAL "macosx10.1")
                SET(OSG_WINDOWING_SYSTEM "Carbon" CACHE STRING "Windowing
system type for graphics window creation, options Carbon, Cocoa or X11.")
            ELSE()
                SET(OSG_WINDOWING_SYSTEM "Cocoa" CACHE STRING "Windowing
system type for graphics window creation, options Carbon, Cocoa or X11.")
            ENDIF()
        ENDIF()

Which raises the question how it came about your system is compiling
against the wrong version.  What OSX version are you using?

Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to