Results 1 to 4 of 4

Thread: Problems building mysql plugin for Qt 4.1.2 on windows XP

  1. #1
    Join Date
    Apr 2006
    Posts
    40
    Thanks
    12
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Question Problems building mysql plugin for Qt 4.1.2 on windows XP

    Hello I've made the plugin without any problems worked with it... before

    But now I have a little problem but i don't see where could it be located..
    I just do everything as normal:
    cd c:\mysql\lib\opt (c:\mysql is where our MySQL is installed)
    reimp -d libmysql.lib (reimp comes with MinGW utilities)
    dlltool -k --input-def libmysql.def --dllname libmysql.dll --output-lib libmysql.a

    cd c:\qt\src\plugins\sqldrivers\mysql (c:\qt is where qt is installed)
    qmake -o Makefile "INCLUDEPATH+=C:\MYSQL\INCLUDE" "LIBS+=-LC:\MYSQL\LIB\OPT -lmysql" mysql.pro

    make
    but I get this output on make:

    C:\Qt\4.1.2\src\plugins\sqldrivers\mysql>qmake -o Makefile "INCLUEDPATH+=C:\mysq
    l\include" "LIBS+=-lC:\mysql\lib\opt -lmysql" mysql.pro

    C:\Qt\4.1.2\src\plugins\sqldrivers\mysql>make
    mingw32-make -f Makefile.Release
    mingw32-make[1]: Entering directory `C:/Qt/4.1.2/src/plugins/sqldrivers/mysql'
    g++ -c -O2 -O2 -frtti -fexceptions -Wall -DUNICODE -DQT_LARGEFILE_SUPPORT -DQT_N
    O_CAST_TO_ASCII -DQT_NO_CAST_FROM_ASCII -DQT_DLL -DQT_NO_DEBUG -DQT_PLUGIN -DQT_
    SQL_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -I"C:/Qt/4.1.2/include/QtCore" -I"C:/Q
    t/4.1.2/include/QtSql" -I"C:/Qt/4.1.2/include" -I"C:/Qt/4.1.2/include/ActiveQt"
    -I"tmp\moc\release_shared" -I"." -I"C:/Qt/4.1.2/mkspecs/win32-g++" -o tmp\obj\re
    lease_shared\main.o main.cpp
    In file included from main.cpp:26:
    ../../../sql/drivers/mysql/qsql_mysql.h:34:19: mysql.h: No such file or director
    y
    In file included from main.cpp:26:
    ../../../sql/drivers/mysql/qsql_mysql.h:82: error: expected `)' before '*' token

    mingw32-make[1]: *** [tmp\obj\release_shared\main.o] Error 1
    mingw32-make[1]: Leaving directory `C:/Qt/4.1.2/src/plugins/sqldrivers/mysql'
    mingw32-make: *** [release] Error 2
    I've tryed these four ways:

    qmake -o Makefile "INCLUDEPATH+=C:\MYSQL\INCLUDE" "LIBS+=-LC:\MYSQL\LIB\OPT -lmysql" mysql.pro

    qmake -o Makefile "INCLUDEPATH+=C:\MYSQL\INCLUDE" "LIBS+=-LC:\MYSQL\LIB\OPT\libmysql.lib" mysql.pro

    qmake -o Makefile "INCLUDEPATH+=C:\MYSQL\INCLUDE" "LIBS+=C:\MYSQL\LIB\OPT\libmysql.lib" mysql.pro

    qmake -o Makefile "INCLUDEPATH+=C:\MYSQL\INCLUDE" "LIBS+=-LC:\MYSQL\LIB\OPT\libmysql.a" mysql.pro
    Any idea on what's wrong?

    Help please
    Battle Programmer Ph1L
    Philip_Anselmo
    Greetings From Osorno - Chile

  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: Problems building mysql plugin for Qt 4.1.2 on windows XP

    It should be INCLUDEPATH not INCLUEDPATH.

  3. #3
    Join Date
    Mar 2006
    Posts
    58
    Thanks
    2
    Thanked 3 Times in 3 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Problems building mysql plugin for Qt 4.1.2 on windows XP


  4. #4
    Join Date
    Apr 2006
    Posts
    40
    Thanks
    12
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Red face Re: Problems building mysql plugin for Qt 4.1.2 on windows XP

    C:\Qt\412A7D~1.2\src\plugins\SQLDRI~1\mysql>qmake -o Makefile "INCLUDEPATH+=c:\mysql\include" "LIBS+=-Lc:\mysql\lib\opt -lmysql" mysql.pro

    C:\Qt\412A7D~1.2\src\plugins\SQLDRI~1\mysql>make
    mingw32-make -f Makefile.Debug all
    mingw32-make[1]: Entering directory `C:/Qt/412A7D~1.2/src/plugins/SQLDRI~1/mysql
    '
    g++ -mthreads -Wl,-enable-stdcall-fixup -Wl,-enable-auto-import -Wl,-enable-runt
    ime-pseudo-reloc -shared -Wl,--out-implib,C:\Qt\4.1.2\plugins\sqldrivers\libqsql
    mysqld.a -o "C:\Qt\4.1.2\plugins\sqldrivers\qsqlmysqld.dll " tmp\obj\debug_shared
    \main.o tmp\obj\debug_shared\qsql_mysql.o -L"C:\Qt\4.1.2\lib" -L"C:\Qt\4.1.2\li
    b" -Lc:\mysql\lib\opt -Lc:\mysql\lib\opt -lmysql -lQtSqld4 -lQtCored4
    C:\MinGW\bin\..\lib\gcc\mingw32\3.4.2\..\..\..\..\ mingw32\bin\ld.exe: cannot fin
    d -lQtSqld4
    collect2: ld returned 1 exit status
    mingw32-make[1]: *** [C:\Qt\4.1.2\plugins\sqldrivers\qsqlmysqld.dll] Error 1
    mingw32-make[1]: Leaving directory `C:/Qt/412A7D~1.2/src/plugins/SQLDRI~1/mysql'

    mingw32-make: *** [debug-all] Error 2


    I've tryied with configure too
    passing the -I c:\mysql\include
    and -L c:\mysql\lib\opt

    I even used the Qt 4.1.2 (Cuild Debug Libraries) link on the Startup Menu... I also edited the qtvars.bat so it included the mysql plugin modifing this line on the bat

    configure -plugin-sql-mysql -plugin-sql-sqlite -plugin-sql-odbc -qt-libpng -qt-libjpeg -I c:\mysql\include -L c:\mysql\lib\opt
    I added the ones on black
    but in the end it sais this:

    g++ -c -include tmp\obj\debug_shared\qt_gui_pch.h -g -g -Wall -frtti -fexception
    s -DQT_SHARED -DQT_THREAD_SUPPORT -DUNICODE -DQT_LARGEFILE_SUPPORT -DQT_BUILD_GU
    I_LIB -DQT_MAKEDLL -DQT_NO_CAST_TO_ASCII -DQT3_SUPPORT -DQT_MOC_COMPAT -DQT_RAST
    ER_IMAGEENGINE -DQT_RASTER_PAINTENGINE -DQT_HAVE_SSE -DQT_PDF_SUPPORT -DQT_NO_ST
    YLE_MAC -DQT_DLL -DQT_CORE_LIB -I"C:/Qt/4.1.2/include/QtCore" -I"C:/Qt/4.1.2/inc
    lude" -I"C:/mysql/include" -I"C:/Qt/4.1.2/include/QtGui" -I"tmp" -I"..\3rdparty\
    wintab" -I"..\3rdparty\libpng" -I"..\3rdparty\zlib" -I"C:/Qt/4.1.2/include/Activ
    eQt" -I"tmp\moc\debug_shared" -I"." -I"C:/Qt/4.1.2/mkspecs/win32-g++" -o tmp\obj
    \debug_shared\qrc_qstyle.o tmp\rcc\debug_shared\qrc_qstyle.cpp
    windres -i QtGuid_resource.rc -o tmp\obj\debug_shared\QtGuid_resource.o --includ
    e-dir=.
    g++ -mthreads -Wl,-enable-stdcall-fixup -Wl,-enable-auto-import -Wl,-enable-runt
    ime-pseudo-reloc -shared -Wl,--out-implib,C:\Qt\4.1.2\lib\libQtGuid4.a -o "..\..
    \lib\QtGuid4.dll" object_script.QtGuid.Debug -L"C:\Qt\4.1.2\lib" -L"C:\Qt\4.1.2
    \lib" -lgdi32 -lcomdlg32 -loleaut32 -limm32 -lwinmm -lwinspool -lws2_32 -lole32
    -luuid -luser32 tmp\obj\debug_shared\QtGuid_resource.o -Lc:\mysql\lib\opt -lmsim
    g32 -lshell32 -lQtCored4
    collect2: ld returned 5 exit status
    mingw32-make[2]: *** [..\..\lib\QtGuid4.dll] Error 1
    mingw32-make[2]: Leaving directory `C:/Qt/4.1.2/src/gui'
    mingw32-make[1]: *** [debug] Error 2
    mingw32-make[1]: Leaving directory `C:/Qt/4.1.2/src/gui'
    mingw32-make: *** [debug-gui] Error 2
    That's all the errors it shows me on console... damn console... I can't post the first lines.. as it's too long for the windows 'console'

    is there a way to compile on linux for windows? as I have to work on xp in a vmware on this fedora thats a pentium 3 550Mhz with 192MB on ram and it's used by at least 4 users at the same time...

    If there's a way to get the plugins from somewhere .. for a Qt 4.1.2 Open Source for windows.. xp with MinGW 3.4
    Last edited by Philip_Anselmo; 17th May 2006 at 21:34.
    Battle Programmer Ph1L
    Philip_Anselmo
    Greetings From Osorno - Chile

Similar Threads

  1. building plugin for mysql?
    By triperzonak in forum Installation and Deployment
    Replies: 1
    Last Post: 25th June 2008, 09:57
  2. Building of MySQL plugin fails
    By janca in forum Installation and Deployment
    Replies: 2
    Last Post: 21st January 2006, 09:23

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.