Page 1 of 2 12 LastLast
Results 1 to 20 of 21

Thread: Qt4 and mysql(driver problem)

  1. #1
    Join Date
    Dec 2007
    Posts
    11
    Qt products
    Qt4

    Default Qt4 and mysql(driver problem)

    Hi All.
    I have a problem with building mysql driver for Qt4.
    i whant to bind mysql and qt.
    I do follow steps.

    qmake -o Makefile "INCLUDEPATH+=C:\MySQL\include" "LIBS+=C:\MySQL\lib\opt\libmysql.lib" mysql.pro
    nmake
    but when i call nmake i get such error

    NMAKE:fatal errorU1077: "c:\...Microsoft Visual Studio 8\VC\bin\cl.exe":return code 0x0000135
    stop.
    NMAKE:fatal error U1077"c:\...Microsoft Visual Studio 8\VC\bin\nmake.exe" return code 0x2
    What's the matter? unriddle pls.

    p.s os winXP,Qt4 and mysql5.
    Last edited by jpn; 24th December 2007 at 13:58.

  2. #2
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: Qt4 and mysql(driver problem)

    What's the first error?
    J-P Nurmi

  3. #3
    Join Date
    Dec 2007
    Posts
    11
    Qt products
    Qt4

    Default Re: Qt4 and mysql(driver problem)

    Quote Originally Posted by jpn View Post
    What's the first error?
    when i call nmake a get such errors
    first error.
    nmake :fatal error u1077:"c:\Program Files\...VC\ bin\cl.exe" return code 0xc0000135.
    stop.
    nmake :fatal error U1077 "c:\...\VC\bin\nmake.exe": return code 0x2
    stop.

  4. #4
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: Qt4 and mysql(driver problem)

    J-P Nurmi

  5. #5
    Join Date
    Dec 2007
    Posts
    11
    Qt products
    Qt4

    Default Re: Qt4 and mysql(driver problem)

    i dont understand nothing.
    if i run cmd line start->programs->Microsoft Visual Studio2005->VS Tools->VS 2005 command promt and run
    qmake -o Makefile "INCLUDEPATH+=C:\MySQL\include" "LIBS+=C:\MySQL\lib\opt\libmysql.lib" mysql.pro
    and then nmake a get shuch error .
    LINK :fatal error LNK1181:cannot open input file 'Files\Microsoft.obj
    NMAKE :fatal erroe U1077:"C:\...\link.exe":return code0x49d

  6. #6
    Join Date
    Jan 2006
    Location
    Munich, Germany
    Posts
    4,714
    Thanks
    21
    Thanked 418 Times in 411 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: Qt4 and mysql(driver problem)

    f i run cmd line start->programs->Microsoft Visual Studio2005->VS Tools->VS 2005 command prompt and run
    I don't understand why are you running this on MSVC prompt and not on the Qt prompt?
    ==========================signature=============== ==================
    S.O.L.I.D principles (use them!):
    https://en.wikipedia.org/wiki/SOLID_...iented_design)

    Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.

  7. #7
    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: Qt4 and mysql(driver problem)

    Quote Originally Posted by knut View Post
    cannot open input file 'Files\Microsoft.obj
    Obviously one of the tools doesn't like the space in the directory name.

  8. #8
    Join Date
    Dec 2007
    Posts
    11
    Qt products
    Qt4

    Default Re: Qt4 and mysql(driver problem)

    now when i use mingw32 -make instead of nmake i get such error.
    what i do

    C:\Qt\4.2.3-msvc2005\src\plugins\sqldrivers\mysql>
    qmake -o Makefile "INCLUDEPATH+=/usr/local/include" "LIBS+=-L/usr/local/lib -lmysqlclient_r" mysql.pro
    and then

    C:\Qt\4.2.3-msvc2005\src\plugins\sqldrivers\mysql>mingw32-make
    but again get error.

    mingw32-make -f Makefile.Debug all
    Makefile.Debug:59: *** missing separator. Stop.
    mingw32-make[1]: Entering directory `C:/Qt/4.3.0/src/plugins/sqldrivers/mysql'
    mingw32-make[1]: Leaving directory `C:/Qt/4.3.0/src/plugins/sqldrivers/mysql'
    mingw32-make: *** [debug-all] Error 2

    whats a metter?

  9. #9
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Qt4 and mysql(driver problem)

    If you are using MSVC, then use nmake and not mingw-make. If you have a problem with spaces in file paths, simply move your installation to a path that does not contain spaces.

  10. #10
    Join Date
    Dec 2007
    Posts
    11
    Qt products
    Qt4

    Default Re: Qt4 and mysql(driver problem)

    i have installed qt-win-opensource-src-4.3.0.zip,.I do it as explain here.
    http://qtnode.net/wiki?title=Qt4_with_Visual_Studio and everything was good before i decided build mysql plugin for Qt4.
    unriddle pls is there any chance(for my situation) build driver?
    or i must delete all(Qt) ,install Qt with this instruction http://qtnode.net/wiki?title=Qt4_on_Windows then download qt-vsintegration and integrate Qt with my VS2005?
    thanks

  11. #11
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Qt4 and mysql(driver problem)

    Are you a commercial or an open source developer?

    You can build the plugin while building Qt itself, just take a look at the options configure.exe provides. But make sure you have no spaces in the path where the build directory resides.

  12. #12
    Join Date
    Dec 2007
    Posts
    11
    Qt products
    Qt4

    Default Re: Qt4 and mysql(driver problem)

    open source developer.
    sorry but i dont understant what u mean?
    But make sure you have no spaces in the path where the build directory resides.

  13. #13
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Qt4 and mysql(driver problem)

    Quote Originally Posted by knut View Post
    open source developer.
    So how do you want to install the qt-vsintegration?

    sorry but i dont understant what u mean?
    But make sure you have no spaces in the path where the build directory resides.
    Unpack your Qt sources to "C:\Qt" and not "C:\Program Files\Qt" (or similar). The same probably goes for other tools (VS?), although your problem seems strange as it works fine for me under WinXP.
    Last edited by wysota; 26th December 2007 at 13:46.

  14. #14
    Join Date
    Dec 2007
    Posts
    11
    Qt products
    Qt4

    Default Re: Qt4 and mysql(driver problem)

    wysota
    i unpack my sources in path C:\Qt\4.2.3-msvc2005.
    after i make
    cd %QTDIR%\src\plugins\sqldrivers\mysql
    qmake -o Makefile "INCLUDEPATH+=C:\MySQL\include" "LIBS+=C:\MySQL\lib\opt\libmysql.lib" mysql.pro
    nmake
    now i get shuch error
    LINK : fatal error LNK1181: cannot open input file 'Files\Microsoft.obj'
    NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 8\VC\BIN\l
    ink.EXE"' : return code '0x49d'
    Stop.
    NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 8\VC\BIN\n
    Last edited by jpn; 27th December 2007 at 09:47. Reason: changed [qtclass] to [quote] tags

  15. #15
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Qt4 and mysql(driver problem)

    "C:\Program Files\Microsoft Visual Studio 8\VC\BIN\link.EXE"
    See the spaces in the path above? They are the ones causing you problems. Or more probably nmake or the terminal.

  16. #16
    Join Date
    Dec 2007
    Posts
    11
    Qt products
    Qt4

    Default Re: Qt4 and mysql(driver problem)

    i add this path C:\Program Files\Microsoft Visual Studio 8\VC\BIN\link.EXE" in my system env.variable but it dosnot resolve my problem.errors dont disappear.

  17. #17
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Qt4 and mysql(driver problem)

    It's not a problem with environment variables but with some tool not understanding spaces in your paths. Take a look at the first error - it shows only a fragment of the path - a fragment beginning after the last whitespace character in the file path.

  18. #18
    Join Date
    Dec 2007
    Posts
    11
    Qt products
    Qt4

    Default Re: Qt4 and mysql(driver problem)

    sorry but how solve this problem ? i have no idea
    thanks

  19. #19
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Qt4 and mysql(driver problem)

    First identify which tool causes the problem and then try to replace it.

  20. #20
    Join Date
    Dec 2007
    Posts
    11
    Qt products
    Qt4

    Default Re: Qt4 and mysql(driver problem)

    sorry for dumb question but to determin determine wich tool causes the problem? for solve this problem?

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.