Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register

OMEdit. Link error

OMEdit. Link error

Hi

I am download from svn source code OpenModelica. I am using last QtSdk, visual studio 2010, mico-2.3.13 and qwt 6.0.1. Mico, Qwt, OMPlot building without errors. But OMEdit give link error:

Code:


LINK : warning LNK4044: unrecognized option '/enable-auto-import'; ignored

PlotWidget.obj : error LNK2019: unresolved external symbol "public: static struct QMetaObject const OMPlot::PlotWindow::staticMetaObject" (?staticMetaObject@PlotWindow@OMPlot@@2UQMetaObject@@B) referenced in function "class OMPlot::PlotWindow * __cdecl qobject_cast<class OMPlot::PlotWindow *>(class QObject *)" (??$qobject_cast@PAVPlotWindow@OMPlot@@@@YAPAVPlotWindow@OMPlot@@PAVQObject@@@Z)

PlotWindowContainer.obj : error LNK2001: unresolved external symbol "public: static struct QMetaObject const OMPlot::PlotWindow::staticMetaObject" (?staticMetaObject@PlotWindow@OMPlot@@2UQMetaObject@@B)

OMPlot.lib(PlotWindow.obj) : error LNK2001: unresolved external symbol "public: static struct QMetaObject const OMPlot::PlotWindow::staticMetaObject" (?staticMetaObject@PlotWindow@OMPlot@@2UQMetaObject@@B)

OMPlot.lib(PlotWindow.obj) : error LNK2019: unresolved external symbol "protected: void __thiscall OMPlot::PlotWindow::closingDown(void)" (?closingDown@PlotWindow@OMPlot@@IAEXXZ) referenced in function "public: virtual void __thiscall OMPlot::PlotWindow::closeEvent(class QCloseEvent *)" (?closeEvent@PlotWindow@OMPlot@@UAEXPAVQCloseEvent@@@Z)

OMPlot.lib(PlotWindow.obj) : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall OMPlot::PlotWindow::metaObject(void)const " (?metaObject@PlotWindow@OMPlot@@UBEPBUQMetaObject@@XZ)

OMPlot.lib(PlotWindow.obj) : error LNK2001: unresolved external symbol "public: virtual void * __thiscall OMPlot::PlotWindow::qt_metacast(char const *)" (?qt_metacast@PlotWindow@OMPlot@@UAEPAXPBD@Z)

OMPlot.lib(PlotWindow.obj) : error LNK2001: unresolved external symbol "public: virtual int __thiscall OMPlot::PlotWindow::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@PlotWindow@OMPlot@@UAEHW4Call@QMetaObject@@HPAPAX@Z)

OMPlot.lib(Plot.obj) : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall OMPlot::Plot::metaObject(void)const " (?metaObject@Plot@OMPlot@@UBEPBUQMetaObject@@XZ)

OMPlot.lib(Plot.obj) : error LNK2001: unresolved external symbol "public: virtual void * __thiscall OMPlot::Plot::qt_metacast(char const *)" (?qt_metacast@Plot@OMPlot@@UAEPAXPBD@Z)

OMPlot.lib(Plot.obj) : error LNK2001: unresolved external symbol "public: virtual int __thiscall OMPlot::Plot::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@Plot@OMPlot@@UAEHW4Call@QMetaObject@@HPAPAX@Z)

OMPlot.lib(PlotPanner.obj) : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall OMPlot::PlotPanner::metaObject(void)const " (?metaObject@PlotPanner@OMPlot@@UBEPBUQMetaObject@@XZ)

OMPlot.lib(PlotPanner.obj) : error LNK2001: unresolved external symbol "public: virtual void * __thiscall OMPlot::PlotPanner::qt_metacast(char const *)" (?qt_metacast@PlotPanner@OMPlot@@UAEPAXPBD@Z)

OMPlot.lib(PlotPanner.obj) : error LNK2001: unresolved external symbol "public: virtual int __thiscall OMPlot::PlotPanner::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@PlotPanner@OMPlot@@UAEHW4Call@QMetaObject@@HPAPAX@Z)

OMPlot.lib(PlotZoomer.obj) : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall OMPlot::PlotZoomer::metaObject(void)const " (?metaObject@PlotZoomer@OMPlot@@UBEPBUQMetaObject@@XZ)

OMPlot.lib(PlotZoomer.obj) : error LNK2001: unresolved external symbol "public: virtual void * __thiscall OMPlot::PlotZoomer::qt_metacast(char const *)" (?qt_metacast@PlotZoomer@OMPlot@@UAEPAXPBD@Z)

OMPlot.lib(PlotZoomer.obj) : error LNK2001: unresolved external symbol "public: virtual int __thiscall OMPlot::PlotZoomer::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@PlotZoomer@OMPlot@@UAEHW4Call@QMetaObject@@HPAPAX@Z)

OMPlot.lib(Legend.obj) : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall OMPlot::Legend::metaObject(void)const " (?metaObject@Legend@OMPlot@@UBEPBUQMetaObject@@XZ)

OMPlot.lib(Legend.obj) : error LNK2001: unresolved external symbol "public: virtual void * __thiscall OMPlot::Legend::qt_metacast(char const *)" (?qt_metacast@Legend@OMPlot@@UAEPAXPBD@Z)

OMPlot.lib(Legend.obj) : error LNK2001: unresolved external symbol "public: virtual int __thiscall OMPlot::Legend::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@Legend@OMPlot@@UAEHW4Call@QMetaObject@@HPAPAX@Z)
..\bin\OMEdit.exe : fatal error LNK1120: 17 unresolved externals

Can you help me?

I think it's link with the flag 'enable-auto-import'.

P.S. Sorry for my bad English!

Edited by: Niko - Feb-15-12 14:40:22

Re: OMEdit. Link error

Hi,

We use mingw for compilation. If you want to use visual studio 2010 you should compile everything from scratch which i suppose you are doing. You must build OMPlot.lib before building OMEdit and link it with OMEdit.

You can also try to remove the --enable-auto-import flag. I guess its just a gcc flag.

Adeel.

Re: OMEdit. Link error

Thank you! I'm solve the problem.

There are 0 guests and 0 other users also viewing this topic
You are here: