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

Thread: nmake problems while building mysql driver

  1. #1
    Join Date
    Jan 2006
    Location
    Ljubljana
    Posts
    687
    Thanks
    111
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Android

    Default nmake problems while building mysql driver

    Hi to all!

    Did someone meet with following pitfall: I am developing an mysql based application and I need mysql driver. So I tried to built it with:

    qmake -o Makefile "INCLUDEPATH+=c:\Program Files\MySQL\MySQL Server 5.0\include" "LIBS+=c:\Program Files\MySQL\MySQL Server 5.0\lib\opt\libmysql.lib" mysql.pro
    qmake does not report any error, however, on

    nmake
    i get:

    Microsoft (R) Program Maintenance Utility Version 8.00.50727.762
    Copyright (C) Microsoft Corporation. All rights reserved.

    NMAKE : fatal error U1065: invalid option '-'
    Stop.
    Last edited by jacek; 19th March 2007 at 23:04. Reason: changed [code] to [quote]
    Qt 5.3 Opensource & Creator 3.1.2

  2. #2
    Join Date
    Jan 2006
    Location
    Alingsås, Sweden
    Posts
    437
    Thanks
    3
    Thanked 39 Times in 39 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: nmake problems while building mysql driver

    Have you tried using this step-by-step guide?

    http://wiki.qtcentre.org/index.php?t...ws_using_MinGW

  3. #3
    Join Date
    Jan 2006
    Location
    Ljubljana
    Posts
    687
    Thanks
    111
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: nmake problems while building mysql driver

    Quote Originally Posted by e8johan View Post
    Have you tried using this step-by-step guide?

    http://wiki.qtcentre.org/index.php?t...ws_using_MinGW

    In my signature it states i use Visual Studio 2005 and not MinGW.
    Qt 5.3 Opensource & Creator 3.1.2

  4. #4
    Join Date
    Jan 2006
    Location
    Ljubljana
    Posts
    687
    Thanks
    111
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: nmake problems while building mysql driver

    I found out if I enter in command shell (qt command shell with all paths) I get:

    Qt Code:
    1. Setting up a Qt environment...
    2. -- QTDIR set to C:\Qt\4.2.1
    3. -- Added C:\Qt\4.2.1\bin to PATH
    4. -- QMAKESPEC set to win32-msvc2005
    5. Setting environment for using Microsoft Visual Studio 2005 x86 tools.
    6. C:\Qt\4.2.1>nmake
    7.  
    8. Microsoft (R) Program Maintenance Utility Version 8.00.50727.762
    9. Copyright (C) Microsoft Corporation. All rights reserved.
    10.  
    11. NMAKE : fatal error U1065: invalid option '-'
    12. Stop.
    13.  
    14. C:\Qt\4.2.1>
    To copy to clipboard, switch view to plain text mode 

    Does anyone have a clue if this is normal nmake operation or not? Is maybe nmake buggy? I've installed Service Pack 1 and that patch for compiling qt app.
    Qt 5.3 Opensource & Creator 3.1.2

  5. #5
    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: nmake problems while building mysql driver

    Did you configure Qt for your compiler?

  6. #6
    Join Date
    Jan 2006
    Location
    Ljubljana
    Posts
    687
    Thanks
    111
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: nmake problems while building mysql driver

    I've installed it and everything works fine, application compiles without problem!

    But if I run configure it also fails with same error, I really do not have any clue what the hell is going on!!
    Qt 5.3 Opensource & Creator 3.1.2

  7. #7
    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: nmake problems while building mysql driver

    Different things may be wrong. Qt can be configured for a different compiler, for example, so that Makefiles generated by qmake are for a different infrastructure - that's why I asked if have you configured Qt for your compiler.

  8. #8
    Join Date
    Jan 2006
    Location
    Ljubljana
    Posts
    687
    Thanks
    111
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: nmake problems while building mysql driver

    I've installed qt and if qt weren't configured for my compiler, my application simply would not have compile at all. The problem is, if I run nmake solo, without anything, I get same error as if I run configure or start build process of mysql driver.
    Qt 5.3 Opensource & Creator 3.1.2

  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: nmake problems while building mysql driver

    Quote Originally Posted by MarkoSan View Post
    I've installed qt and if qt weren't configured for my compiler, my application simply would not have compile at all.
    I'm talking about the sources, not the binaries.

    The problem is, if I run nmake solo, without anything, I get same error as if I run configure or start build process of mysql driver.
    So please tell me did you configure the sources for msvc 2005? As far as I remember the "-platform win32-msvc2005" (or something like that) switch may be required if Qt can't determine your configuration on its own. Also please try running "qmake" before running nmake, maybe it just needs to regenerate some Makefile. Did you by any chance modified any of the project files?

  10. #10
    Join Date
    Jan 2006
    Location
    Ljubljana
    Posts
    687
    Thanks
    111
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: nmake problems while building mysql driver

    Quote Originally Posted by wysota View Post
    I'm talking about the sources, not the binaries.



    So please tell me did you configure the sources for msvc 2005? As far as I remember the "-platform win32-msvc2005" (or something like that) switch may be required if Qt can't determine your configuration on its own. Also please try running "qmake" before running nmake, maybe it just needs to regenerate some Makefile. Did you by any chance modified any of the project files?
    Listen, if I run nmake in the directory where no makefiles are I still get same error. I cannot recompile sources because configure exists with same error!
    Qt 5.3 Opensource & Creator 3.1.2

  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: nmake problems while building mysql driver

    What happens if you create a Makefile with the following contents:
    all:
    <tabulator here>echo "blabla"
    <empty line here>
    and run nmake?

  12. #12
    Join Date
    Jan 2006
    Location
    Ljubljana
    Posts
    687
    Thanks
    111
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: nmake problems while building mysql driver

    I still get:

    Qt Code:
    1. Microsoft (R) Program Maintenance Utility Version 8.00.50727.762
    2. Copyright (C) Microsoft Corporation. All rights reserved.
    3.  
    4. NMAKE : fatal error U1065: invalid option '-'
    5. Stop.
    To copy to clipboard, switch view to plain text mode 

    I think nmake gets fucked up by applying that KB930859. Becuase there is a problem compiling qt apps with Visual Studio 2005 Service Pack 1. After I applied this KB930859 on Service Pack 1 my nmake got fucked up! I contaced MS but still no answer!!!!
    Qt 5.3 Opensource & Creator 3.1.2

  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: nmake problems while building mysql driver

    I doubt the patch did anything to your nmake. The problem concerned the compiler, not the make tool.

  14. #14
    Join Date
    Jan 2006
    Location
    Ljubljana
    Posts
    687
    Thanks
    111
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: nmake problems while building mysql driver

    But make is part of compiler, isn't it?
    Qt 5.3 Opensource & Creator 3.1.2

  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: nmake problems while building mysql driver

    No. It's shipped with it, but not part of it, so I doubt the patch even touched it

  16. #16
    Join Date
    Jan 2006
    Location
    Ljubljana
    Posts
    687
    Thanks
    111
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: nmake problems while building mysql driver

    Does anyone have any idea how to check the correctness of nmake?
    Qt 5.3 Opensource & Creator 3.1.2

  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: nmake problems while building mysql driver

    Run nmake in a directory that doesn't have a Makefile. It should complain about it.

  18. #18
    Join Date
    Jan 2006
    Location
    Ljubljana
    Posts
    687
    Thanks
    111
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: nmake problems while building mysql driver

    I did, same error reported!!
    Qt 5.3 Opensource & Creator 3.1.2

  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: nmake problems while building mysql driver

    nmake seems fine. The error you get is not unusual.

    http://www.cygwin.com/ml/cygwin/1999-10/msg00311.html

    What is unusual is that nmake manages to find a makefile when it's not there. Could you check if the nmake you call is really a nmake binary and not some script? Because it behaves like it was accessing the same faulty makefile all the time. You might need to adjust your %PATH% to make sure the proper nmake is used.

    Could you also verify that nmake /HELP returns a list of options and not the error you're battling with? Also please try running nmake with the "/R" option - if your tools.ini is broken, using this option should make nmake work by ignoring all configuration from tools.ini.

    See this for referece: http://msdn2.microsoft.com/en-us/lib...50(VS.80).aspx

  20. #20
    Join Date
    Jan 2006
    Location
    Ljubljana
    Posts
    687
    Thanks
    111
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: nmake problems while building mysql driver

    I ran:

    Qt Code:
    1. dir /s \nmake.*
    To copy to clipboard, switch view to plain text mode 
    to find all nmakes installed on my computer. I got this listing:

    Qt Code:
    1. Volume in drive C is Lokalni disk
    2. Volume Serial Number is 808B-2D12
    3.  
    4. Directory of C:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\Bin
    5.  
    6. 02.12.2006 07:17 82.696 nmake.exe
    7. 1 File(s) 82.696 bytes
    8.  
    9. Directory of C:\Program Files\Microsoft Visual Studio 8\VC\bin
    10.  
    11. 02.12.2006 07:17 82.696 nmake.exe
    12. 1 File(s) 82.696 bytes
    13.  
    14. Directory of C:\Program Files\Microsoft Visual Studio 8\VC\bin\amd64
    15.  
    16. 02.12.2006 07:20 100.616 nmake.exe
    17. 1 File(s) 100.616 bytes
    18.  
    19. Directory of C:\WINXP\Prefetch
    20.  
    21. 26.03.2007 00:56 7.490 NMAKE.EXE-08101E42.pf
    22. 1 File(s) 7.490 bytes
    23.  
    24. Total Files Listed:
    25. 4 File(s) 273.498 bytes
    26. 0 Dir(s) 3.870.904.320 bytes free
    To copy to clipboard, switch view to plain text mode 
    The path is set up as follows:

    C:\Program Files\Microsoft Visual Studio 8\Common7\IDE;C:\Program Files\Microsoft Visual Studio 8\VC\BIN;C:\Program Files\Microsoft Visual Studio 8\Common7\Tools;C:\Program Files\Microsoft Visual Studio 8\Common7\Tools\bin;C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\bin;C:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\bin;C:\WINXP\Microsoft.NET\Framework\v2 .0.50727;C:\Program Files\Microsoft Visual Studio 8\VC\VCPackages;C:\Qt\4.2.1\bin;;C:\WINXP\system32 ;C:\WINXP;C:\WINXP\System32\Wbem;C:\Program Files\Subversion\bin;C:\Program Files\Microsoft SQL Server\90\Tools\binn\;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\MySQL\MySQL Server 5.0\bin
    I tried to run both 32bit versions of nmake from dir that has makefile and from dir that does not have makefile and i still get same errors!

    If I try to pass to nmake some paramaters, I still get same error, which is very very weird!
    Last edited by jacek; 26th March 2007 at 14:13. Reason: changed [code] to [quote]
    Qt 5.3 Opensource & Creator 3.1.2

Similar Threads

  1. My Mysql 5 and Qt 4.2.2 Problem (Driver not loaded)
    By fengtian.we in forum Qt Programming
    Replies: 4
    Last Post: 9th February 2007, 09:11
  2. MySql plugin driver issues
    By stevey in forum Installation and Deployment
    Replies: 11
    Last Post: 20th September 2006, 14:45
  3. Problems building mysql plugin for Qt 4.1.2 on windows XP
    By Philip_Anselmo in forum Installation and Deployment
    Replies: 3
    Last Post: 17th May 2006, 16:38
  4. 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.