[osg-users] [build] OSX X11 Build System Failures

Ravi Mathur ravidavi at utexas.edu
Thu Jun 23 13:43:54 PDT 2016


Hi all,

A few of the newer OSG components explicitly reference osgViewer::GraphicsWindowCocoa in their code. This causes link errors when compiling OSG on MacOS with OSG_WINDOWING_SYSTEM set to X11.

The affected components are: avfoundation (osgdb), osgmultitouch (examples), osgoscdevice (examples). Currently the only check done in their CMake scripts is IF(APPLE), which implicitly assumes that everyone on Mac is building Cocoa.

One simple fix is to add a check at the beginning of the affected components' CMakeLists.txt files. e.g.:

Code:

IF(NOT (OSG_WINDOWING_SYSTEM STREQUAL "Cocoa"))
  RETURN()
ENDIF()



This will only build that component if the windowing system is Cocoa.

Thoughts appreciated,
Ravi

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=67767#67767








More information about the osg-users mailing list