OpenModelica


Forgot password? | Forgot username? | Register

OMEdit compilation in debug mode - OSG error

OMEdit compilation in debug mode - OSG error

Hello.

I'm trying to compile OMEdit in debug mode by using QtCreator from OMDev in Windows (in Release it's working). I installed the Qt and OSG debug libraries by following the OMDev readme but I'm still having problems to link the OSG libraries. I'm compiling in x86 mode but I installed both x86 and x64 libraries.

For example, a part of the compilation line is the following:
-LE:\OMDev\tools\msys\mingw32\lib -llibosgd.dll
and the following files are present on disk:
e:\OMDev\tools\msys\mingw32\lib\libosgd.dll.a
e:\OMDev\tools\msys\mingw32\bin\libosgd.dll

I can't find why these libraries are not linking.

Below is the full error message as a reference.

Thank you.

Code:

mingw32-make[1]: Entering directory 'e:/dev/OpenModelica/OMEdit/OMEditGUI'

E:/OMDev/tools/msys/mingw32/bin/mingw32-make -f Makefile.Debug
mingw32-make[2]: Entering directory 'e:/dev/OpenModelica/OMEdit/OMEditGUI'
g++ -Wl,--stack,16777216,--enable-auto-import,--large-address-aware -Wl,-subsystem,windows -mthreads -o ..\bin\OMEdit.exe debug/rc_omedit_res.o debug/main.o  -lglu32 -lopengl32 -lgdi32 -luser32 -lmingw32 -lqtmaind -L..\bin -lOMEdit -LE:\OMDev\tools\msys\mingw32\lib -llibosgd.dll -llibosgViewerd.dll -llibOpenThreadsd.dll -llibosgDBd.dll -llibosgGAd.dll -L..\OMEditLIB\Debugger\Parser -lGDBMIParser -Le:\dev\OpenModelica\build\lib\omc -lomantlr3 -lOMPlot -lomqwt -lomopcua -lOpenModelicaCompiler -lomcruntime -lOpenModelicaRuntimeC -lfmilib -lModelicaExternalC -lomcgc -lpthread -lshlwapi -lws2_32 -Le:\dev\OpenModelica\build\bin -lOMSimulator -lqjson E:\OMDev\tools\msys\mingw32\lib\libQt5WebKitWidgetsd.dll.a E:\OMDev\tools\msys\mingw32\lib\libQt5WebKitd.dll.a E:\OMDev\tools\msys\mingw32\lib\libQt5Svgd.dll.a E:\OMDev\tools\msys\mingw32\lib\libQt5OpenGLd.dll.a E:\OMDev\tools\msys\mingw32\lib\libQt5PrintSupportd.dll.a E:\OMDev\tools\msys\mingw32\lib\libQt5Widgetsd.dll.a E:\OMDev\tools\msys\mingw32\lib\libQt5Guid.dll.a E:\OMDev\tools\msys\mingw32\lib\libQt5XmlPatternsd.dll.a E:\OMDev\tools\msys\mingw32\lib\libQt5Networkd.dll.a E:\OMDev\tools\msys\mingw32\lib\libQt5Xmld.dll.a E:\OMDev\tools\msys\mingw32\lib\libQt5Concurrentd.dll.a E:\OMDev\tools\msys\mingw32\lib\libQt5Cored.dll.a
E:/OMDev/tools/msys/mingw32/bin/../lib/gcc/i686-w64-mingw32/5.3.0/../../../../i686-w64-mingw32/bin/ld.exe: cannot find -llibosgd.dll
E:/OMDev/tools/msys/mingw32/bin/../lib/gcc/i686-w64-mingw32/5.3.0/../../../../i686-w64-mingw32/bin/ld.exe: cannot find -llibosgViewerd.dll
E:/OMDev/tools/msys/mingw32/bin/../lib/gcc/i686-w64-mingw32/5.3.0/../../../../i686-w64-mingw32/bin/ld.exe: cannot find -llibOpenThreadsd.dll
E:/OMDev/tools/msys/mingw32/bin/../lib/gcc/i686-w64-mingw32/5.3.0/../../../../i686-w64-mingw32/bin/ld.exe: cannot find -llibosgDBd.dll
E:/OMDev/tools/msys/mingw32/bin/../lib/gcc/i686-w64-mingw32/5.3.0/../../../../i686-w64-mingw32/bin/ld.exe: cannot find -llibosgGAd.dll
collect2.exe: error: ld returned 1 exit status
Makefile.Debug:62: recipe for target '..\bin\OMEdit.exe' failed
mingw32-make[2]: *** [..\bin\OMEdit.exe] Error 1
mingw32-make[2]: Leaving directory 'e:/dev/OpenModelica/OMEdit/OMEditGUI'
Makefile:34: recipe for target 'debug' failed
mingw32-make[1]: *** [debug] Error 2
mingw32-make[1]: Leaving directory 'e:/dev/OpenModelica/OMEdit/OMEditGUI'
Makefile:82: recipe for target 'sub-OMEditGUI-make_first-ordered' failed
mingw32-make: *** [sub-OMEditGUI-make_first-ordered] Error 2

Administrator has disabled public posting. Please login or register in order to proceed.

Re: OMEdit compilation in debug mode - OSG error

Just edit: OpenModelica\OMEdit\OMEditGUI\OMEditGUI.win.config.pri and change the osg libs to the ones not using "d" at the end:

These:

Code:


LIBS += -llibosgd.dll -llibosgViewerd.dll -llibOpenThreadsd.dll -llibosgDBd.dll -llibosgGAd.dll

to these:

Code:


LIBS += -llibosg.dll -llibosgViewer.dll -llibOpenThreads.dll -llibosgDB.dll -llibosgGA.dll

I guess you don't need to debug the OSG part in OMEdit (3D visualization).

Administrator has disabled public posting. Please login or register in order to proceed.

Re: OMEdit compilation in debug mode - OSG error

Nice, that worked well. As you guessed I am not going to debug the OSG part so no problem.

Thank you.

Administrator has disabled public posting. Please login or register in order to proceed.

Re: OMEdit compilation in debug mode - OSG error

In case you want to debug OSG then read the section OpenSceneGraph DEBUG DLLS (optional) in INSTALL.txt file in OMDev.

Adeel.

Administrator has disabled public posting. Please login or register in order to proceed.
There are 0 guests and 0 other users also viewing this topic
You are here: