7

I am compiling a program with Visual C++ 2010 but I don't want everyone to have to download the redistributable package to run my programs. Most people that will be using my program already have the VC++ 2008 redistributable package though, so is there a way I can compile it with compatibility with VC 2008? Or is there a place I can download VC 2008 express?

pnuts
  • 58,317
  • 11
  • 87
  • 139
tfkl
  • 71
  • 1
  • 2
  • You are aware that there are *three* versions of the VS2008 redist? It won't work if your clients don't have the latest. – Hans Passant Aug 08 '10 at 17:41

2 Answers2

6

Visual Studio 2010 has an option to compile with Visual Studio 2008 toolset. You can find it under your project settings. I think the option is just labeled 'Platform Toolset' in the general properties page.

Collin Dauphinee
  • 13,664
  • 1
  • 40
  • 71
  • 1
    When I set it to vc90, I get "MSB8010: Specified platform toolset (v90) requires Visual Studio 2008. Please make sure that Visual Studio 2008 is installed on the machine." – tfkl Aug 08 '10 at 17:09
  • And you have vs2008 installed ? – nos Aug 08 '10 at 17:17
  • 1
    No, if I did I would just compile it with VS2008. The problem is that I don't have it and I can't find anywhere to download it. – tfkl Aug 08 '10 at 17:19
  • 3
    Try here http://www.microsoft.com/express/downloads/#2008-Visual-CPP in 'Visual Studio 2008 Express" tab. You can also download Microsoft SDK 7.0 - it contains VC 2008 compiler (in SDK 7.1 VC was replaced with 2010 version). – Zuljin Aug 08 '10 at 17:23
  • Wow, downvoting microsoft for obscure links. Thanks Zuljin, that's the download. If you want to put that in a separate answer I'll mark it as such. – tfkl Aug 08 '10 at 17:26
0

If you set the 'Platform Toolset' to "inherit from parent or project defaults" it will work in most of the cases.

arman_aegit
  • 435
  • 1
  • 9
  • 20
  • 1
    That won't work if you don't have the correct runtime installed on your machine -- the issue the questioner is having. If the platform toolset is set to the wrong version, it doesn't matter if it's in the parent or the current project, and if you don't have it on your system at all it doesn't matter even more! – adamfisk Jul 25 '12 at 22:44