Qt build error; lnk 2019 error + nmake



  • I am following this procedure for building Qt and integrating into vs2013

    *Build instructions

    • Visual C++ 2010 contains all necessary SDKs for Qt compilation. However if you plan to use Qt with Phonon you need to install DirectX SDK first.

    • Install Perl if you are going to compile Qt >= 4.8.0

    • Download and extract Qt 5.6.0 Source Code. (Qt 4.8.0 or Latest snapshot).
      Copy contents of the folder qt-everywhere-opensource-src-5.6.0 to the directory where you intend to install Qt. In our case this is C:\Qt\5.6.0.

    • Set up environmental variables

      QTDIR=C:\Qt\5.6.0

      QMAKESPEC=win32-msvc2013

    • Update PATH variable to include %QTDIR%\bin (I did not understand this option)

    • Start Visual Studio 2010 Command Prompt: Start > Programs > Microsoft Visual Studio 2013 > Visual Studio Tools > Visual Studio Command Prompt. Run following commands in it (every line is a different command: type it then press Enter):

      cd c:\Qt\5.6.0

      configure -debug-and-release -opensource -platform win32-msvc2013

      nmake

    Download and install Qt Visual Studio Add-in. Run Visual Studio 2010. Integrate just compiled Qt to IDE using menu Qt > Qt Options > Qt Versions > Add

    I am facing issue with step 7. configure works fine but nmake gives error.

    Below is the error:

    link /NOLOGO /DYNAMICBASE /NXCOMPAT /DEBUG /SUBSYSTEM:WINDOWS "/MANIFEST DEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='' processorArchitecture=''" /MANIFEST:embed /OUT:debug\adueditor.exe @C:\Users\z003npra\AppData\Local\Temp\nm211.tmp

    modbustcpclient.obj : error LNK2019: unresolved external symbol "public: void __thiscall QModbusClientPrivate::processQueueElement(class QModbusResponse const &,struct QModbusClientPrivate::QueueElement const &)" (processQueueElement@QModb usClientPrivate@@QAEXABVQModbusResponse@@ABUQueueElement@1@@Z) referenced in fun ction "public: void __thiscall ::operat or()(void)const " (??R@@QBEXXZ) debug\adueditor.exe : fatal error LNK1120: 1 unresolved externals

    NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\BIN\link.EXE"' : return code '0x460'Stop.

    NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\BIN\nmake.exe"' : return code '0x2' Stop.

    NMAKE : fatal error U1077: 'cd' : return code '0x2' Stop.

    NMAKE : fatal error U1077: 'cd' : return code '0x2' Stop.

    NMAKE : fatal error U1077: 'cd' : return code '0x2' Stop.

    NMAKE : fatal error U1077: 'cd' : return code '0x2' Stop.

    NMAKE : fatal error U1077: 'cd' : return code '0x2' Stop.

    Unable to Debug it. Please help me out with this.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.