Sunday, 15 February 2015

c++ - Unresolved External Symbol LNK2019 with WinRT component for COM-based lib -


I am using a third party COM-based library which the engine is using in a native WinRT component Should work as a cover in third party Lib is an engine for third party. Lib and an engine h file is setup in my project

I am getting LNK 2019 for the following CPP file: < / P>

  #include "pch.h" #include "engine.h" Zero Components: Init () {compat & lt; IEngine & gt; SpEngine; Setting settings; CreateEngine (& amp; Settings, & amp; spEngine); }   

The code is compiled properly and the engine. LB VS is setup in the project settings of 2012. Also the engine. Dumpbib / export for the lib that indicates that CreateEngine has been exposed. I can also use other types defined in Engine.h, but as soon as the CreateEngine is called, a linker error is called:

  error 1 error LNK2019: unsolved exotic symbol CreateEngine @ The function referenced in "Public: Virtual Zero __cdecl   

Engine.h defines CreateEngine in this way:

  STDAPI CreateEngine (_In_ Settings * pSettings , _Outptr_Ingine ** ppEngine);   

Where STDAPI is the usual macro:

  #define STDAPI extern "c" HRESULT __stdcall   

anyone Also consider?

With the help of inspiration it explained: I was using the built-in lib for ARM After changing an x86 build configuration that it was linking properly.

No comments:

Post a Comment