Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Using MSVC compiler in Qt Creator
Forum Updated to NodeBB v4.3 + New Features

Using MSVC compiler in Qt Creator

Scheduled Pinned Locked Moved Qt Creator and other tools
14 Posts 7 Posters 40.1k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    HuXiKa
    wrote on last edited by
    #2

    Have you tried looking into "QLibrary":http://doc.trolltech.com/latest/qlibrary.html ?

    If you can find faults of spelling in the text above, you can keep them.

    1 Reply Last reply
    0
    • W Offline
      W Offline
      WarPhalange
      wrote on last edited by
      #3

      Ahh, I see what you are saying. The issue I'm having right now is that the source files I need to use are the ones giving out errors. I can edit them, yes, but I have a feeling that is going to be a lot more work than simply getting the right compiler.

      Basically, I am using a company's SDK for their hardware. The source code and libraries are an API for that hardware. I'd really rather not mess with their source code if I can help it, since right now I can treat it as a black box and just do my project instead of trying to figure out what is going on and then trying to fix it, before I can go back and work on my project.

      1 Reply Last reply
      0
      • T Offline
        T Offline
        tobias.hunger
        wrote on last edited by
        #4

        You can not mix mingw and MSVC compiled libraries, so you will need to get a Qt that was build using MSVC. Qt Creator should pick up MSVC automatically (check in Tools->Options->Tool Chains in Qt Creator 2.2 or later, older versions do not explicitly output which tool chains they had detected, even though it works there, too).

        Select a MSVC compiled Qt and you can select the MSVC compilers and off you go. IIRC the windows SDK is sufficient for Qt Creator. The debugging support is of course a big help, too. Visual Studio Express should not be necessary.

        1 Reply Last reply
        0
        • W Offline
          W Offline
          WarPhalange
          wrote on last edited by
          #5

          I downloaded and installed the precompiled framework for VS 2008 and then installed the IDE separately, but nothing happened. It didn't have any compiler in the Projects tab. So I'm kind of stuck. What I'm trying to do right now is this:

          http://stackoverflow.com/questions/5601950/how-to-build-qt-for-visual-studio-2010

          So I know I didn't want to use Qt in VS, but I don't know what else to do at this point.

          1 Reply Last reply
          0
          • G Offline
            G Offline
            goetz
            wrote on last edited by
            #6

            You cannot mix binaries for various VS versions (2005, 2005+SP1, 2008, 2008+SP1, 2010), they are not binary compatible.

            You'll have to compile manually for VS 2010.

            Visual Studio is an IDE (GUI) and the tool chain (actual compiler, linker, libraries, etc.). You can use the tool chain with other IDEs too, eg. Qt Creator.

            http://www.catb.org/~esr/faqs/smart-questions.html

            1 Reply Last reply
            0
            • W Offline
              W Offline
              WarPhalange
              wrote on last edited by
              #7

              Okay, then how do I compile Qt manually so I can use the VS 2010 toolchain?

              1 Reply Last reply
              0
              • G Offline
                G Offline
                goetz
                wrote on last edited by
                #8

                I found "this guide":http://www.holoborodko.com/pavel/2011/02/01/how-to-compile-qt-4-7-with-visual-studio-2010/ in "this thread":http://developer.qt.nokia.com/forums/viewthread/5180 and "another forum thread":http://developer.qt.nokia.com/forums/viewthread/5090 dealing with this topic. Hope that helps.

                http://www.catb.org/~esr/faqs/smart-questions.html

                1 Reply Last reply
                0
                • W Offline
                  W Offline
                  WarPhalange
                  wrote on last edited by
                  #9

                  Aha! Somehow I managed to get it to work. I started up Qt Creator and it found the MSVC compiler. Unfortunately now the compiler is complaining about the Qt code (that my predecessor wrote), so I'll have to jump into that and fix it. Looks like he tried to declare character variable arrays without a predefined size, so I'll just have to play around with turning them into pointers. Oh well.

                  Anyway, thank you all for your help!

                  1 Reply Last reply
                  0
                  • G Offline
                    G Offline
                    goetz
                    wrote on last edited by
                    #10

                    Yeah. Microsoft Compilers are sometimes more picky about certain things than GCC (and the other way round too). It bites me now and then between Win and Mac development :)

                    http://www.catb.org/~esr/faqs/smart-questions.html

                    1 Reply Last reply
                    0
                    • B Offline
                      B Offline
                      bycross
                      wrote on last edited by
                      #11

                      Hola alguien me podría decir como lograr lo que hizo "WarPhalange "

                      Compilar con MSVC en el IDE Qt Creator

                      Gracias

                      1 Reply Last reply
                      0
                      • B Offline
                        B Offline
                        bycross
                        wrote on last edited by
                        #12

                        "http://blog.jesteban.es/compilar-qt/":http://blog.jesteban.es/compilar-qt/

                        Una solucion :)

                        1 Reply Last reply
                        0
                        • EddyE Offline
                          EddyE Offline
                          Eddy
                          wrote on last edited by
                          #13

                          Hi Bycross,

                          This part of the forum is english. Could you translate your posts please? So others can understand what you're saying.

                          Thanks

                          Qt Certified Specialist
                          www.edalsolutions.be

                          1 Reply Last reply
                          1
                          • F Offline
                            F Offline
                            Friedemann.Kleint
                            wrote on last edited by
                            #14

                            Take a look at the "README":http://qt.gitorious.org/qt-creator/qt-creator/blobs/master/README provided for building Qt Creator from scratch. Most of the issues mentioned there apply to building Qt as well.

                            1 Reply Last reply
                            0

                            • Login

                            • Login or register to search.
                            • First post
                              Last post
                            0
                            • Categories
                            • Recent
                            • Tags
                            • Popular
                            • Users
                            • Groups
                            • Search
                            • Get Qt Extensions
                            • Unsolved