try to do this
cd %QTDIR%\src\plugins\sqldrivers\psql
qmake "INCLUDEPATH+=%PSQLDIR%\psql\include" "LIBS+=%PSQLDIR%\lib\libpq.lib" psql.pro
mingw32-make