Build PostgreSQL driver for Qt 4.7.4 on GNU/Linux
-
Yes, there is where I looked, but I didn't find it, instead I found qsql_psql.pri
-
I have qsql_psql.pri here: QtSDK/QtSources/4.7.3/src/sql/drivers/psql/qsql_psql.pri
-
I have it too, but when I try to build the driver, I have the errors described in my first post
-
So you have qsql_psql.pri in both location ?
- QtSDK/QtSources/4.7.3/src/plugins/sqldrivers/psql
- QtSDK/QtSources/4.7.3/src/sql/drivers/psql
At location 1 should be psql.pro
-
Ok, sorry, you're right.
I find psql.pro in QtSDK/QtSources/4.7.3/src/plugins/sqldrivers/psql and build the driver.
Thanks for your help. -
I 'm know it's old topic.But I have the same problem. So I will be happy. If you tell me what comand You were writing in Yours terminall qmake ??? and make???.But any path??? Like this :
_cd $QTDIR/src/plugins/sqldrivers/psql qmake -o Makefile "INCLUDEPATH+=/usr/include/pgsql" "LIBS+=-L/usr/lib -lpq" psql.pro make_
-
Hi
@
cd QtSDK/QtSources/4.7.3/src/plugins/sqldrivers/psql
qmake "INCLUDEPATH+=/usr/include/pgsql" "LIBS+=-L/usr/lib -lpq" psql.pro
make
@Hope it helps you
-
Hi,thanks.
But still not working.This is my terminal.
marcin@marcin-K50IN:~$ cd /home/marcin/Pobrane/qt-everywhere-opensource-src-4.7.3/src/plugins/sqldrivers/psql
marcin@marcin-K50IN:~/Pobrane/qt-everywhere-opensource-src-4.7.3/src/plugins/sqldrivers/psql$ qmake "INCLUDEPATH+=/usr/include/pgsql" "LIBS+=-L/usr/lib -lpq" psql.pro
marcin@marcin-K50IN:~/Pobrane/qt-everywhere-opensource-src-4.7.3/src/plugins/sqldrivers/psql$ make g++ -c -pipe -O2 -fvisibility=hidden -fvisibility-inlines-hidden -D_REENTRANT -Wall -W -fPIC -DQT_NO_CAST_TO_ASCII -DQT_NO_CAST_FROM_ASCII -DQT_NO_DEBUG -DQT_PLUGIN -DQT_SQL_LIB -DQT_CORE_LIB -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtSql -I/usr/include/qt4 -I/usr/include/pgsql -I. -o main.o main.cpp
main.cpp:42: fatal error: qsqldriverplugin.h: Nie ma takiego pliku ani katalogu(In eng.The directory dosen't exist)
compilation terminated.
make: *** [main.o] Błąd 1
marcin@marcin-K50IN:~/Pobrane/qt-everywhere-opensource-src-4.7.3/src/plugins/sqldrivers/psql$Im using Ubuntu 10.10. And I install Qt by website , not source. I should change path for all header files, no way.?!
-
"I just figured this out with MySQL":http://developer.qt.nokia.com/forums/viewthread/8206 but it's the same process. I also compiled the postgresql driver at the same time with success.
Good luck.
-
Thanks for all. Special thanks for bobby.Great it's working.