Results 1 to 2 of 2

Thread: Problems in building the OCI plugin using VS 2010 and Qt5.3.2

  1. #1
    Join Date
    Nov 2007
    Location
    Italy
    Posts
    691
    Thanks
    59
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Problems in building the OCI plugin using VS 2010 and Qt5.3.2

    Hi to all, I have some problem in building the OCI plugin using QT 5.3.2 and VS2010 as compiler.
    First of all I downloaded the qt5.3.2 src code and then I followed the instructions listed here:

    How to Build the OCI Plugin on Windows
    Choosing the option "Programmer" in the Oracle Client Installer from the Oracle Client Installation CD is generally sufficient to build the plugin. For some versions of Oracle Client, you may also need to select the "Call Interface (OCI)" option if it is available.
    Build the plugin as follows (here it is assumed that Oracle Client is installed in C:\oracle):
    set INCLUDE=%INCLUDE%;c:\oracle\oci\include
    set LIB=%LIB%;c:\oracle\oci\lib\msvc
    cd %QTDIR%\src\plugins\sqldrivers\oci
    qmake oci.pro
    nmake
    In my case ( I installed Oracle 11g Express edition ), the installation is a bit different (C:\oraclexe\app\oracle\product\11.2.0\server ).
    So these are the steps I followed:

    1) C:\oraclexe\app\oracle\product\11.2.0\server>set INCLUDE=%INCLUDE%;C:\oraclexe\app\oracle\product\1 1.2.0\server\oci\include
    2) C:\oraclexe\app\oracle\product\11.2.0\server>set LIB=%LIB%;C:\oraclexe\app\oracle\product\11.2.0\se rver\oci\lib\MSVC
    3) C:\oraclexe\app\oracle\product\11.2.0\server>cd Libs\Qt\Qt5.3.2\5.3\src\qtbase\src\plugins\sqldriv ers\oci
    4) qmake oci.pro
    5) nmake
    And this is the output I got:

    Creating library ..\..\..\..\plugins\sqldrivers\qsqloci.lib and object ..\..\..\..\plugins\sqldrivers\qsqloci.exp
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIDescriptorAlloc referenced in function "public: __thiscall QOCIRowId::QOCIRowId(struct OCIEnv *)" (??0QOCIRowId@@QAE@PAUOCIEnv@@@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIDescriptorFree referenced in function "public: __thiscall QOCIRowId::~QOCIRowId(void)" (??1QOCIRowId@@QAE@XZ)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIHandleAlloc referenced in function "public: void __thiscall QOCIDriverPrivate::allocErrorHandle(void)" (?allocErrorHandle@QOCIDriverPrivate@@QAEXXZ)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIErrorGet referenced
    in function "class QString __cdecl qOraWarn(struct OCIError *,int *)" (?qOraWarn@@YA?AVQString@@PAUOCIError@@PAH@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCINumberFromInt referenced in function "class QByteArray __cdecl qMakeOCINumber(__int64 const &,struct OCIError *)" (?qMakeOCINumber@@YA?AVQByteArray@@AB_JPAUOCIError @@@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCINumberToInt referenced in function "__int64 __cdecl qMakeLongLong(char const *,struct OCIError *)"(?qMakeLongLong@@YA_JPBDPAUOCIError@@@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIAttrGet referencedin function "protected: virtual int __thiscall QOCIResult::numRowsAffected(void)" (?nuRowsAffected@QOCIResult@@MAEHXZ)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCILobRead referencedin function "int __cdecl qReadLob<class QString,2>(class QString &,struct QOCIResultPrivate const *,struct OCILobLocator *)" (??$qReadLob@VQString@@$01@@YAHAAVQ
    String@@PBUQOCIResultPrivate@@PAUOCILobLocator@@@Z )
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCILobGetLength referenced in function "int __cdecl qReadLob<class QString,2>(class QString &,struct QOCIResultPrivate const *,struct OCILobLocator *)" (??qReadLob@VQString@@$01@@YAHAAVQString@@PBUQOCIR esultPrivate@@PAUOCILobLocator@@@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCILobCharSetForm referenced in function "int __cdecl qReadLob<class QString,2>(class QString &,struct
    QOCIResultPrivate const *,struct OCILobLocator *)" (??$qReadLob@VQString@@$01@@
    YAHAAVQString@@PBUQOCIResultPrivate@@PAUOCILobLoca tor@@@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIAttrSet referenced
    in function "public: void __thiscall QOCIResultPrivate::setCharset(void *,unsign
    ed int)const " (?setCharset@QOCIResultPrivate@@QBEXPAXI@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIEnvCreate reference
    d in function "public: __thiscall QOCIDriver::QOCIDriver(class QObject *)" (??0Q
    OCIDriver@@QAE@PAVQObject@@@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIHandleFree referenc
    ed in function "public: virtual void __thiscall QOCIDriver::close(void)" (?close
    @QOCIDriver@@UAEXXZ)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIServerDetach refere
    nced in function "public: virtual void __thiscall QOCIDriver::close(void)" (?clo
    se@QOCIDriver@@UAEXXZ)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCISessionEnd referenc
    ed in function "public: virtual void __thiscall QOCIDriver::close(void)" (?close
    @QOCIDriver@@UAEXXZ)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCITransStart referenc
    ed in function "protected: virtual bool __thiscall QOCIDriver::beginTransaction(
    void)" (?beginTransaction@QOCIDriver@@MAE_NXZ)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCITransCommit referen
    ced in function "protected: virtual bool __thiscall QOCIDriver::commitTransactio
    n(void)" (?commitTransaction@QOCIDriver@@MAE_NXZ)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCITransRollback refer
    enced in function "protected: virtual bool __thiscall QOCIDriver::rollbackTransa
    ction(void)" (?rollbackTransaction@QOCIDriver@@MAE_NXZ)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIStmtPrepare referen
    ced in function "public: virtual bool __thiscall QOCIResult:repare(class QStri
    ng const &)" (?prepare@QOCIResult@@UAE_NABVQString@@@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIServerVersion refer
    enced in function "public: virtual bool __thiscall QOCIDriver:pen(class QStrin
    g const &,class QString const &,class QString const &,class QString const &,int,
    class QString const &)" (?open@QOCIDriver@@UAE_NABVQString@@000H0@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCISessionBegin refere
    nced in function "public: virtual bool __thiscall QOCIDriver:pen(class QString
    const &,class QString const &,class QString const &,class QString const &,int,c
    lass QString const &)" (?open@QOCIDriver@@UAE_NABVQString@@000H0@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIServerAttach refere
    nced in function "public: virtual bool __thiscall QOCIDriver:pen(class QString
    const &,class QString const &,class QString const &,class QString const &,int,c
    lass QString const &)" (?open@QOCIDriver@@UAE_NABVQString@@000H0@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIStmtFetch reference
    d in function "public: int __thiscall QOCICols::readPiecewise(class QVector<clas
    s QVariant> &,int)" (?readPiecewise@QOCICols@@QAEHAAV?$QVector@VQVaria nt@@@@H@Z)

    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIStmtSetPieceInfo re
    ferenced in function "public: int __thiscall QOCICols::readPiecewise(class QVect
    or<class QVariant> &,int)" (?readPiecewise@QOCICols@@QAEHAAV?$QVector@VQVaria nt@
    @@@H@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIStmtGetPieceInfo re
    ferenced in function "public: int __thiscall QOCICols::readPiecewise(class QVect
    or<class QVariant> &,int)" (?readPiecewise@QOCICols@@QAEHAAV?$QVector@VQVaria nt@
    @@@H@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIDefineByPos referen
    ced in function "public: __thiscall QOCICols::QOCICols(int,struct QOCIResultPriv
    ate *)" (??0QOCICols@@QAE@HPAUQOCIResultPrivate@@@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIParamGet referenced
    in function "public: __thiscall QOCICols::QOCICols(int,struct QOCIResultPrivate
    *)" (??0QOCICols@@QAE@HPAUQOCIResultPrivate@@@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIBindByPos reference
    d in function "public: int __thiscall QOCIResultPrivate::bindValue(struct OCIStm
    t *,struct OCIBind * *,struct OCIError *,int,class QVariant const &,void *,unsig
    ned short *,class QList<class QByteArray> &)" (?bindValue@QOCIResultPrivate@@QAE
    HPAUOCIStmt@@PAPAUOCIBind@@PAUOCIError@@HABVQVaria nt@@PAXPAGAAV?$QList@VQByteArr
    ay@@@@@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIStmtExecute referen
    ced in function "public: static bool __cdecl QOCICols::execBatch(struct QOCIResu
    ltPrivate *,class QVector<class QVariant> &,bool)" (?execBatch@QOCICols@@SA_NPAU
    QOCIResultPrivate@@AAV?$QVector@VQVariant@@@@_N@Z)
    qsql_oci.obj : error LNK2019: unresolved external symbol _OCIBindArrayOfStruct r
    eferenced in function "public: static bool __cdecl QOCICols::execBatch(struct QO
    CIResultPrivate *,class QVector<class QVariant> &,bool)" (?execBatch@QOCICols@@S
    A_NPAUQOCIResultPrivate@@AAV?$QVector@VQVariant@@@ @_N@Z)
    ..\..\..\..\plugins\sqldrivers\qsqloci.dll : fatal error LNK1120: 30 unresolved
    externals
    NMAKE : fatal error U1077: '"c:\Program Files (x86)\Microsoft Visual Studio 10.0
    \VC\BIN\link.EXE"' : return code '0x460'
    Stop.
    NMAKE : fatal error U1077: '"c:\Program Files (x86)\Microsoft Visual Studio 10.0
    \VC\BIN\nmake.exe"' : return code '0x2'
    Stop.

    Can I have some help please? Seems it can not link against the oracle lib.

    Regards,
    Franco
    Last edited by franco.amato; 9th October 2014 at 01:01.
    Franco Amato

  2. #2
    Join Date
    Feb 2012
    Location
    Warsaw, Poland
    Posts
    37
    Thanks
    3
    Thanked 6 Times in 6 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows Android

    Default Re: Problems in building the OCI plugin using VS 2010 and Qt5.3.2


Similar Threads

  1. Building Qt 5 examples with Visual Studio 2010
    By user_mail07 in forum Installation and Deployment
    Replies: 0
    Last Post: 14th February 2013, 19:34
  2. Problems building Qt 5 static with MSVC 2010
    By prophetofreason in forum Installation and Deployment
    Replies: 1
    Last Post: 28th January 2013, 17:45
  3. Building Qt 4.8.3 - cross-compile using MSVC 2010 x64 tools
    By oleg_stepanenko@bk.ru in forum Installation and Deployment
    Replies: 0
    Last Post: 4th December 2012, 09:08
  4. problems building the QMYSQL plugin on Windows 64 using MinGW 64
    By carpanta in forum Installation and Deployment
    Replies: 1
    Last Post: 24th April 2012, 20:13
  5. Problems building mysql plugin for Qt 4.1.2 on windows XP
    By Philip_Anselmo in forum Installation and Deployment
    Replies: 3
    Last Post: 17th May 2006, 15:38

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.