Added support for version of the osgPlugins directory, which now gets versioned
according to the OpenSceneGraph/CMakeLists.txt and the include/osg/Version settings. These changes mean that the 1.9.5 release will have a libs/osgPlugins-1.9.5 directory.
This commit is contained in:
@@ -65,6 +65,7 @@
|
||||
#endif
|
||||
|
||||
#include <osg/Notify>
|
||||
#include <osg/Version>
|
||||
|
||||
#include <osgDB/FileUtils>
|
||||
#include <osgDB/FileNameUtils>
|
||||
@@ -73,6 +74,9 @@
|
||||
#include <errno.h>
|
||||
#include <stack>
|
||||
|
||||
|
||||
const std::string OSG_PLUGINS(std::string("osgPlugins-")+std::string(osgGetVersion())+std::string("/"));
|
||||
|
||||
bool osgDB::makeDirectory( const std::string &path )
|
||||
{
|
||||
if (path.empty())
|
||||
@@ -315,7 +319,7 @@ std::string osgDB::findLibraryFile(const std::string& filename,CaseSensitivity c
|
||||
|
||||
// failed with direct paths,
|
||||
// now try prepending the filename with "osgPlugins/"
|
||||
return findFileInPath("osgPlugins/"+simpleFileName,filepath,caseSensitivity);
|
||||
return findFileInPath(OSG_PLUGINS+simpleFileName,filepath,caseSensitivity);
|
||||
}
|
||||
|
||||
std::string osgDB::findFileInDirectory(const std::string& fileName,const std::string& dirName,CaseSensitivity caseSensitivity)
|
||||
|
||||
Reference in New Issue
Block a user