Qt World Summit: Submit your Presentation

Qt502 compiler not working msv2011

  • Dear All,cannot compile an example from qt.
    programme returns message:
    :-1: error: Qt Creator needs a compiler set up to build. Configure a compiler in the kit options.
    i am using:
    Qt Creator 2.7.0
    Based on Qt 5.0.2 (32 bit)
    Built on Apr 9 2013 at 09:32:03
    From revision b6257ef735
    Copyright 2008-2013 Digia Plc. All rights reserved.

    I have:
    Microsoft Visual Studio Express 2012 for Windows Desktop
    Version 11.0.60315.01 Update 2
    Microsoft .NET Framework
    Version 4.5.50709
    Installed Version: Desktop Express
    Team Explorer for Visual Studio 2012 05695-004-0022003-02260
    Microsoft Team Explorer for Visual Studio 2012
    Visual Basic 2012 05695-004-0022003-02260
    Microsoft Visual Basic 2012
    Visual C# 2012 05695-004-0022003-02260
    Microsoft Visual C# 2012
    Visual C++ 2012 05695-004-0022003-02260
    Microsoft Visual C++ 2012
    NuGet Package Manager 2.0.30717.9005
    NuGet Package Manager in Visual Studio. For more information about NuGet, visit http://docs.nuget.org/.
    SQL Server Data Tools 11.1.20828.01
    Microsoft SQL Server Data Tools

    I can go to tools>options>build and run>compilers
    and see auto detect has seen:
    Microsoft Visual C++ compiler 11.0(x86) msvc

    but am unable to apply the compiler to QT Creater
    What am i doing wrong and what do i need to do?

  • welcome to devnet

    I have updated your post with code tags for better reading. "Please check out the forum help":http://qt-project.org/wiki/ForumHelp#e3f82045ad0f480d3fb9e0ac2d58fb01

    How and where do you try to assign the toolchain?
    What do you see under Build&Run > Kits ?

  • My guess is that your kit has no compiler set since the Qt version you downloaded is not compatible with MSVC 2012.

    You will need a Qt 5.0.2 build with MSVC 2012 for that. IIRC we do not provided binaries of that for download. You will have to either downgrade to MSVC 2010 or build Qt with MSVC 2012 yourself.

  • Dear Koahnig.
    Question 1, "toolchain" - sorry, do not understand.
    Q2, under Kits:
    auto detected
    (red stop/danger sign) desktop Qt 5.0.2 msvc2010 32bit
    (yellow triangle) unnamed M/soft Visual C++ Compiler 11.0 (default)

  • As Tobias is suggesting you need to check for proper version of the download you are using.

    MSVC of different versions are not compatible. Possibly you have downloaded pre-build for msvc2012 64 bit. AFAIK you can use only for compiling for 64 bit, which you should have.

  • dear Tobias Hunger & koahnig,
    thankyou i shall see if i can d/load 2010

  • Dear All,
    i have d/loaded:
    Microsoft Visual Studio 2010
    Version 10.0.30319.1 RTMRel
    Microsoft .NET Framework
    Version 4.5.50709 RTMRel
    Installed Version: VC Express
    Microsoft Visual C++ 2010 01013-532-2002287-70919
    Microsoft Visual C++ 2010

    when i go again to:
    tools>options>build and run>compilers
    the compiler is auto detected but when i click on it and try to click apply and click OK nothing happens to indicate it can use the compiler.
    when i run a QT example a message comes up:
    :-1: error: LNK1123: failure during conversion to COFF: file invalid or corrupt.
    so i am none he wiser, what else can i try. is there an open source compiler that you can recommend and where to go?

Log in to reply