From Stephan Huber, "while debugging a problem in finding plugins on OS X I discovered, that

the conditional directives for setting the prepend-string in
createLibraryNameForExtension were not in effect, because of the mixture
of different #ifdef styles.

I removed the conditional part for __APPLE__ completely to be more
standard-conform with other platforms (plugins should be located in
osgPlugins-X.X.X/). Because of the wrong syntax of the conditional
compile the old code was not used anyway -- so no functional change.
"

Merged from svn/trunk using:

svn merge -r 10149:10150 http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgDB
This commit is contained in:
Robert Osfield
2009-05-07 13:24:49 +00:00
parent e1c5969b0e
commit 4ae4b9fdf5

View File

@@ -640,13 +640,8 @@ std::string Registry::createLibraryNameForExtension(const std::string& ext)
ExtensionAliasMap::iterator itr=_extAliasMap.find(lowercase_ext);
if (itr!=_extAliasMap.end() && ext != itr->second) return createLibraryNameForExtension(itr->second);
#ifdef OSG_JAVA_BUILD
#if defined(OSG_JAVA_BUILD)
static std::string prepend = std::string("osgPlugins-")+std::string(osgGetVersion())+std::string("/java");
#elseif defined(__APPLE__)
// OSX is rather a mess in FileUtils.cpp w.r.t its appendPlatformSpecificLibraryFilePaths implementation
// as it hardwires the plugin name to PlugIns. This *needs* fixing to use the naming convention as all
// other platforms.
static std::string prepend = "";
#else
static std::string prepend = std::string("osgPlugins-")+std::string(osgGetVersion())+std::string("/");
#endif