Hi Farshid,
Correct, but what about the plug-ins and examples? They aren't
installed in OSG_ROOT\bin. So if you only copy the DLLs in
OSG_ROOT\bin, when trying to load a plug-in (installed in
OSG_ROOT\bin\osgPlugins-X.Y.Z) or running an example (installed in
OSG_ROOT\shared\OpenSceneGraph\bin) that requires an external DLL,
this last one will thus be searched in the PATH, with the risk of
finding a similarly named DLL elsewhere in the filesystem before
reaching the expected on in OSG_ROOT\bin. How do you manage this
situation on your own?
Cheers,
Émeric
2014-09-24 19:12 GMT+02:00 Farshid Lashkari <[email protected]>:
> Hi Émeric,
>
> Placing the external libraries in OSG_ROOT\bin should work as long as the
> main executable is also in OSG_ROOT\bin. Windows should first search for
> DLLs in the same folder as the executable before searching in PATH. So there
> is no need to add your application to PATH, or worry about conflicting DLLs
> in PATH. I've deployed my application like this for years and never had any
> issues.
>
> Cheers,
> Farshid
>
>
> On Wed, Sep 24, 2014 at 10:03 AM, Émeric MASCHINO
> <[email protected]> wrote:
>>
>> Hi,
>>
>> What's the best practice regarding OSG deployment on Windows? Indeed,
>> several plug-ins depend on external libraries. Is it best to put the
>> required DLLs in OSG_ROOT\bin\osgPlugins-X.Y.Z or rather in
>> OSG_ROOT\bin, thus ensuring that OSG_ROOT\bin is in the PATH so that
>> the plug-ins can find them?
>>
>> With this last approach, there's only one copy of each DLL shared by
>> the OSG applications, plug-ins and examples. The drawback is that if a
>> similarly named DLL is found in the PATH before reaching OSG_ROOT\bin,
>> an incorrect DLL may be loaded.
>>
>> By contrast, copying the required DLLs in
>> OSG_ROOT\bin\osgPlugins-X.Y.Z may also require copying them in
>> OSG_ROOT\bin as well as in OSG_ROOT\share\OpenSceneGraph\bin.
>>
>> Any advice on what's better?
>>
>> Émeric
>> _______________________________________________
>> osg-users mailing list
>> [email protected]
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
>
>
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org