Results 1 to 5 of 5

Thread: Qt 4.1.4 plugin QPSQL

  1. #1
    Join Date
    Jan 2006
    Posts
    73
    Thanks
    16
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Qt 4.1.4 plugin QPSQL

    Hello,
    I just dowloaded Qt 4.1.4 and I tried to compile the plugin for postgreSQL without success. It compiled fine with Qt 4.1.3.
    I am getting the error message below (I am posting a part of it only).
    Thanks for any help
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:464: error: `PQfinish' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp: In member function `virtual bool QPSQLDriver::open(const QString&, const QString&, const QString&, const QString&, in
    t, const QString&)':
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:535: error: `PQconnectdb' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:536: error: `PQstatus' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:536: error: `CONNECTION_BAD' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp: In member function `virtual void QPSQLDriver::close()':
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:555: error: `PQfinish' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp: In member function `virtual bool QPSQLDriver::beginTransaction()':
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:573: error: `PQexec' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:574: error: `PQresultStatus' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:574: error: `PGRES_COMMAND_OK' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:575: error: `PQclear' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp: In member function `virtual bool QPSQLDriver::commitTransaction()':
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:590: error: `PQexec' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:591: error: `PQresultStatus' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:591: error: `PGRES_COMMAND_OK' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:592: error: `PQclear' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp: In member function `virtual bool QPSQLDriver::rollbackTransaction()':
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:607: error: `PQexec' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:608: error: `PQresultStatus' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:608: error: `PGRES_COMMAND_OK' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:611: error: `PQclear' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp: In member function `virtual QString QPSQLDriver::formatValue(const QSqlField&, bool) const':
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:873: error: `PQescapeBytea' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp: In member function `virtual bool QPSQLDriver::isOpen() const':
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:903: error: `PQstatus' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:903: error: `CONNECTION_OK' undeclared (first use this function)
    mingw32-make[1]: *** [tmp\obj\release_shared\qsql_psql.o] Error 1
    mingw32-make[1]: Leaving directory `C:/Qt/4.1.4/src/plugins/sqldrivers/psql'
    mingw32-make: *** [release] Error 2
    Last edited by jacek; 22nd June 2006 at 21:25. Reason: changed [ code ] to [ quote ] to allow wrapping of long lines

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Qt 4.1.4 plugin QPSQL

    Could you post the first error message?

  3. #3
    Join Date
    Jan 2006
    Posts
    73
    Thanks
    16
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Qt 4.1.4 plugin QPSQL

    I am posting below the full error message:
    C:\Qt\4.1.4\src\plugins\sqldrivers\psql>qmake -o Makefile "INCLUDEPATH+=C:\psql\include" "LIBS+=C:\psql\lib\ms\libpq.lib" psql.pro

    C:\Qt\4.1.4\src\plugins\sqldrivers\psql>make
    mingw32-make -f Makefile.Release
    mingw32-make[1]: Entering directory `C:/Qt/4.1.4/src/plugins/sqldrivers/psql'
    g++ -c -O2 -O2 -frtti -fexceptions -Wall -DUNICODE -DQT_LARGEFILE_SUPPORT -DQT_NO_CAST_TO_ASCII -DQT_NO_CAST_FROM_ASCII -DQT_DLL -DQT_NO_DEBUG -DQT_PLUGIN -DQ
    T_SQL_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -I"C:/Qt/4.1.4/include/QtCore" -I"C:/Qt/4.1.4/include/QtSql" -I"C:/Qt/4.1.4/include" -I"c:\psql\include" -I"C:/Qt/
    4.1.4/include/ActiveQt" -I"tmp\moc\release_shared" -I"." -I"..\..\..\..\mkspecs\win32-g++" -o tmp\obj\release_shared\qsql_psql.o ..\..\..\sql\drivers\psql\qsq
    l_psql.cpp
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:37:22: libpq-fe.h: No such file or directory
    ..\..\..\sql\drivers\psql\qsql_psql.cpp: In function `QSqlError qMakeError(const QString&, QSqlError::ErrorType, const QPSQLDriverPrivate*)':
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:122: error: `PQerrorMessage' undeclared (first use this function)
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:122: error: (Each undeclared identifier is reported only once for each function it appears in.)
    [...]
    mingw32-make[1]: *** [tmp\obj\release_shared\qsql_psql.o] Error 1
    mingw32-make[1]: Leaving directory `C:/Qt/4.1.4/src/plugins/sqldrivers/psql'
    mingw32-make: *** [release] Error 2
    Last edited by jacek; 22nd June 2006 at 22:05. Reason: shortened the quote, so it doesn't break the page layout

  4. #4
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Qt 4.1.4 plugin QPSQL

    Quote Originally Posted by jcr
    ..\..\..\sql\drivers\psql\qsql_psql.cpp:37:22: libpq-fe.h: No such file or directory
    Do you have this file somewhere on your disk? Are you sure that "C:\psql\include" is a correct path?

  5. The following user says thank you to jacek for this useful post:

    jcr (22nd June 2006)

  6. #5
    Join Date
    Jan 2006
    Posts
    73
    Thanks
    16
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Qt 4.1.4 plugin QPSQL

    My apologies, here. I am embarrassed... I should have read the error code better.
    My path to the postgreSQL directory was wrong it was psql\8.1\... and not psql\...
    Thanks!

Similar Threads

  1. Testing a custom Plugin
    By maluta in forum Qt Programming
    Replies: 5
    Last Post: 31st October 2006, 15:09
  2. Replies: 5
    Last Post: 23rd May 2006, 11:40
  3. creating table plugin
    By mgurbuz in forum Qt Programming
    Replies: 3
    Last Post: 28th April 2006, 13:50
  4. Application plugin on windows
    By Eyee in forum Qt Programming
    Replies: 2
    Last Post: 22nd March 2006, 17:36
  5. Managing widget plugin in Qt Designer
    By yellowmat in forum Newbie
    Replies: 8
    Last Post: 31st January 2006, 09:58

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.