Closed AlexOct closed 1 year ago
There a CMake mechanism I know of that can be used directly with osgstaticviewer.
Building the OSG static adds complexity to build and is rather niche for OSG usage which is designed primarily to work with shared libraries and use the plugins dynamically, unless you really need it I'd not bother.
If static build is important to your project then perhaps just moving onto the VulkanSceneGraph would be helpful, it builds by default as static lib and the loaders are designed from day one to support static builds.
When I created the example like osgstaticviewer by using cmake.I can't load static lib from the path to plugins-{$version} (eg. plugins-3.6.5),during compilation.so i cant find lib like
..\..\lib\osgPlugins-3.6.5\osgdb_ive.lib
I load other lib in the way likes :find_package(osgText REQUIRED)
andtarget_link_libraries($OSGTEXT_LIBRARY_RELEASE)
Is there any function in cmake that can help me find the path to plugins.