Hello Gerrit,

The OpenExr library still does cause problems for me. After spotting the 
dynamic link library problem I did switch to static linking but still uses 
my own build system setup. The only notably difference of the support 
libraries provided by the OpenSG setup is the naming scheme.

My libraries are named as follows:

ilmimf.lib and ilmimfD.lib
ilmhalf.lib and ilmhalfD.lib
ilmiex.lib and ilmiexD.lib
ilmthread.lib and ilmthreadD.lib

Since I do not use the OSG_USE_OSGSUPPORT_LIBS flag the FindOpenExr.cmake 
script comes into play. The first problem with this is that it does not 
respect the dependency to the illmthread library which is used. I added the 
necessary FIND_LIBRARY statements for this library for debug and release. 
You can find this changed file on:
http://drop.io/OpenSG_RenderEngine

Additionally, I added variables OPENEXR_LIBRARIES_RELEASE and 
OPENEXR_LIBRARIES_DEBUG for the different types. Now I'm at the core of my 
problem, because I did not find a way to use these debug and release 
libraries properly. Running cmake with this FindOpenEXR.cmake script results 
in msvc project files refering only to the release libraries of OpenExr for 
all build types. This, however, does not work for the debug build types.
In the same context the debug/release variables for the other support 
libraries are also not respected. As these are simple C libraries this is 
not such a serious problem. However, not so for OpenExr. Here the proper 
build type is required.

In file ConfigurePackages.cmake is a small error in line 166. The statement

OSG_FIND_PACKAGE(OpenEXR)

must be replaced by

OSG_FIND_PACKAGE(OPENEXR)

otherwise the FIND_PACKAGE call in BuildFunctions.cmake does not provide a 
correct ${Name}_FOUND flag.

I'm not sure the following is helpful but I did solve the build type 
dependency problem in my cmake projects as in the example below:

target_link_libraries(
    png
        debug ${ZLIB_D_LIBRARY}
        optimized ${ZLIB_LIBRARY}


Best,
Johannes




------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to