16

This maybe a beginner question but could not find proper answer on the internet. I am curious can I use some other compiler (which I like) in Visual Studio 10?

sashoalm
  • 75,001
  • 122
  • 434
  • 781
pseudonym_127
  • 357
  • 7
  • 16
  • 6
    The easiest way is to use a Makefile project with VC instead of an MSBuild project, that way you can specify the exact compiler in your makefile. – Dai May 14 '13 at 08:56
  • read this : http://msdn.microsoft.com/en-us/library/ms171452.aspx – Lrrr May 14 '13 at 08:57
  • You can take a look to the answers of this question : http://stackoverflow.com/questions/216025/gcc-with-visual-studio – Akayh May 14 '13 at 09:11
  • 3
    Kinda pointless to spend that kind of money on a text editor. – Hans Passant May 14 '13 at 10:12
  • @Dai: Could you please elaborate? – pseudonym_127 May 14 '13 at 10:45
  • @Hans: he may already have VS. Also, the free Express version's editor is still pretty nice (though it can't be enhanced with add-ons). – Michael Burr May 15 '13 at 06:15
  • @pseudonym_127: The menu item "File/New/Project.../Makefile Project" lets you have a project with all the files in it for editing and code navigation. You get to specify commands to build the project (the commands can use `make` with a makefile or any other build tool you want). The minor drawback is that VS doesn't maintain the build files - you do. The major drawback is that you don't get to use the VS debugger. I sometimes do this with an embedded toolchain, where VS editing and navigation are much better than the embedded toolchain's IDE - I just have to switch to the other IDE to debug. – Michael Burr May 15 '13 at 06:22
  • @Michael Blurr: from what I have heard/understood so far it is possible to achieve above with VS + Makefiles right? – pseudonym_127 May 15 '13 at 08:11
  • @pseudonym_127 I deleted the unrelated parts of your question, I hope it's not a problem. Asking several questions in a single post should be avoided. If you want to, you can still post them as separate questions, though. – sashoalm May 15 '13 at 09:45
  • I would be inclined to rewind a bit and ask the question "What are you really trying to achieve?". The effort of trying to get a different compiler integrated into VS is unlikley to be worth the hassle unless there's a *really* compelling reason for it. – the_mandrill May 21 '13 at 08:09

3 Answers3

1

As of Visual Studio 2010, it is conceptually possible to integrate another compiler. In the book ‘Inside the Microsoft Build Engine, Using MSBuild and Team Foundation Buid’ 2nd edition, on page 338, the chapter ‘Adding a New Platform and Platform Toolset’ the process of adding gcc to visual studio is explained.

However, while it is possible, it has always remained as a concept. To my awareness, nobody has actually been up to the task and publicly disclosed the results. But even with this support, you'd still be lacking debugging facilities. Which would require your compiler of choice to generate .pdb files and/or extend visual studio with a new local debugger

In summary it's quite a venture

Lawrence Kok
  • 1,568
  • 11
  • 29
0

You can use other compiler Intel c++ in VS. I don't think any other compiler supports VS.The main reason behind it is lack of plug-ins in VS. But you can use cmake scripts to compile your code in different compilers. With eclipse you can use most of the compilers (VS,gcc). Code blocks also allows you to choose the compilers.

Community
  • 1
  • 1
Sanoob
  • 2,466
  • 4
  • 30
  • 38
0

Yes,you can use Intel C++,and even MATLAB 7.1 or later for sure..here is a reference to use MATLABIt gives a step by step procedure to use MATLAB with VS

You can also write Java programs and include javac compiler for it...you can refer this if needed..Including javac with VS

I kno this is surely possible from VS 2010 but not sure for the b4 editions..hope it helps..