Results 1 to 3 of 3

Thread: Installing Qt using gcc, g++ 4.5.0 and Msys-1.0.14 fails!

  1. #1
    Join Date
    Jun 2010
    Posts
    4
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Installing Qt using gcc, g++ 4.5.0 and Msys-1.0.14 fails!

    Hi,

    I have tried to install Qt on MingW platform, but with no luck.

    The reason why I need to use MinGW is that I've developed a graphical backend to GNU Octave (http://www.octave.org) which is compiled on Windows with MinGW/MSYS GCC/G++ 4.5.0.

    To make it work I need to compile Qt in the same environment as I compiled Octave in.
    I've tried to compile both Qt-4.5.3 and Qt-4.6.3 in Mingw, but without any luck.


    First I've tried to compile Qt-4.5.3. If I had encounter the same error on Linux, I would know that I am missing a libc6-dev package. I think the error from Qt-4.6.3 is strange....It seems like it favour Windows over MinGW, since the error message here is :
    project.cpp:3102:51: error: cannot convert 'wchar_t*' to 'CHAR*' for argument '1' to 'BOOL GetComputerNameA(CHAR*, DWORD*)'


    See the error messages at the end.

    What should I do?

    Best regards,

    Ole J.




    Qt-4.5.3: configure -opensource -platform win32-g++ gives the following output:

    g++ -c -o qfile.o -DQMAKE_OPENSOURCE_EDITION -I. -Igenerators -Igenerators/unix -Igenerators/win32 -Igenerators/mac -I/i/Qt/qt-4.5.3/include -I/i/Qt/qt-4.5.3/include/QtCore -I/i/Qt/qt-4.5.3/src/corelib/global -I/i/Qt/qt-4.5.3/src/script -DQT_NO_PCRE -DQT_BUILD_QMAKE -DQT_BOOTSTRAPPED -DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_COMPONENT -DQT_NO_STL -DQT_NO_COMPRESS -I/i/Qt/qt-4.5.3/mkspecs/win32-g++ -DHAVE_QCONFIG_CPP -DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT /i/Qt/qt-4.5.3/src/corelib/io/qfile.cpp
    g++ -c -o qfsfileengine_unix.o -DQMAKE_OPENSOURCE_EDITION -I. -Igenerators -Igenerators/unix -Igenerators/win32 -Igenerators/mac -I/i/Qt/qt-4.5.3/include -I/i/Qt/qt-4.5.3/include/QtCore -I/i/Qt/qt-4.5.3/src/corelib/global -I/i/Qt/qt-4.5.3/src/script -DQT_NO_PCRE -DQT_BUILD_QMAKE -DQT_BOOTSTRAPPED -DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_COMPONENT -DQT_NO_STL -DQT_NO_COMPRESS -I/i/Qt/qt-4.5.3/mkspecs/win32-g++ -DHAVE_QCONFIG_CPP -DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT /i/Qt/qt-4.5.3/src/corelib/io/qfsfileengine_unix.cpp
    i:/Qt/qt-4.5.3/src/corelib/io/qfsfileengine_unix.cpp:57:22: fatal error: sys/mman.h: No such file or directory
    compilation terminated.
    make.exe: *** [qfsfileengine_unix.o] Error 1

    ---------------------------------------------------------------------------

    Output: Qt-4.6.3:

    configure -opensource -platform win32-g++ gives the following output:

    Do you accept the terms of either license? yes

    Creating qmake. Please wait...

    g++ -c -o project.o -DQMAKE_OPENSOURCE_EDITION -I. -Igenerators -Igenerators/unix -Igenerators/win32 -Igenerators/mac -Igenerators/symbian -I/i/Qt/qt-4.6.3/include -I/i/Qt/qt-4.6.3/include/QtCore -I/i/Qt/qt-4.6.3/src/corelib/global -I/i/Qt/qt-4.6.3/src/corelib/xml -I/i/Qt/qt-4.6.3/tools/shared -DQT_NO_PCRE -DQT_BUILD_QMAKE -DQT_BOOTSTRAPPED -DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_COMPONENT -DQT_NO_STL -DQT_NO_COMPRESS -I/i/Qt/qt-4.6.3/mkspecs/win32-g++ -DHAVE_QCONFIG_CPP -DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT project.cpp
    project.cpp: In member function 'QStringList& QMakeProject::values(const QString&, QMap<QString, QStringList>&)':
    project.cpp:3102:51: error: cannot convert 'wchar_t*' to 'CHAR*' for argument '1' to 'BOOL GetComputerNameA(CHAR*, DWORD*)'
    make.exe: *** [project.o] Error 1

  2. #2
    Join Date
    Jun 2010
    Posts
    4
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Installing Qt using gcc, g++ 4.5.0 and Msys-1.0.14 fails!

    Hi,

    How does the trolltech guys modify the MinGW to make Qt compile on Windows?
    I can use gcc-4.5.0 from Mingw, but qmake.exe gives a segfault when I run it.

    I get a message box: The application failed to initialize properly (0xc0000005). Click on OK to terminate the application....

    How can I solve this?

    Ole

  3. #3
    Join Date
    Jun 2010
    Posts
    4
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Installing Qt using gcc, g++ 4.5.0 and Msys-1.0.14 fails!

    Removed duplicate posting.
    Last edited by olejh; 14th June 2010 at 06:38.

Similar Threads

  1. compiling Qt 4.6 in msys
    By manekineko in forum Qt Programming
    Replies: 4
    Last Post: 24th July 2010, 19:37
  2. Problem with mingw (from msys)
    By lorebett in forum Newbie
    Replies: 2
    Last Post: 13th February 2009, 12:48
  3. qmake and msys [win]
    By jh in forum Qt Programming
    Replies: 8
    Last Post: 12th February 2009, 21:55
  4. Qt 4.3.1 & MinGW 5.1.3 & MSYS 1.0 qmake problem
    By mdecandia in forum Installation and Deployment
    Replies: 2
    Last Post: 2nd October 2008, 16:52
  5. Compiling QSA 1.2.0 fails
    By detheang in forum Installation and Deployment
    Replies: 11
    Last Post: 4th February 2006, 20:09

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.