Using Visual Studio 2010 C++ compiler and linker without Visual Studio 2010 having been installed - c++

At my company we really like for our development tools to be able to be used from perforce, without having been installed. For a lot of tools (perforce, gcc compiler, snc compiler, even maya) this works after some tweaking, but for Visual Studio 2005 we could not get it to work. As far as we could see, the problem was caused by mspdbsrv.exe. When VS2005 was not installed, the linker would regularly exit with an error about a corrupt pdb. When VS2005 is installed, we almost never see this error.
Does anybody know if this is possible with Visual Studio 2010?

See here. This will install compilers, headers, and win32 development tools if you select them. Exactly what you need: toolchain without IDE.

Yeah, mspdbsrv.exe would be a hangup. It is a service required to arbitrate access to the program database to allow concurrent compilation. Can't get a service going without getting the registry entries right.
This did not improve in VS2010. It has an entirely new build system, based off MSBuild. There's a ton of stuff that needs to be set just right in the registry. Pretty unlikely to get that right and trouble-free without using the installer. Takes half an hour or so, not worth your time.

Related

Visual Studio 2017 wont show c++ template/extansion

I am trying to use Microsoft visual studio IDE to run my c++ code, however, when I go to create a project, I do not see the option for a c++ project. I tried reinstalling the program to see if I could somehow install the package/extension however it just won't seem to come up.
The only templates that appear are in c# or f#.
If someone could please lead me into the right direction so that I can fix this, it would be great. Thank you.
I don't see any mention of C++ in the release notes.
According to this post on MSDN, there is no C++ support in the Mac version of Visual Studio. It contains links to instructions for using Visual Studio Code, as well as the option to install a VM running Windows.
Apparently Visual Studio Code supports C++ projects, since it can execute external tools. The Microsoft Visual C++ build tools are free for Windows, but I don't think there is a version for the Mac, so some other external compiler is necessary.

Missing MSVCP120D.dll but don't have Visual Studios anymore

I dug up an old project of mine from college when we exclusively used Visual Studios, and I'm looking to run it again. I don't have the exe anymore, just the debug version. When I run the debug version, I get the missing MSVCP120D.dll error. I have no way to recompile this into the release version. Is there a way for me to download the missing dlls, without downloading Visual Studios?
Incase you didn't know, MSVCP120D.dll is a dynamic link library for the IDE "Microsoft Visual C++ 12.0", which I believe is from Visual Studio 2013.
If you know the version of Visual Studio that you used (You specified 2010 and 2012 in the tags), you can use the following link to download the toolchain, Visual C++: https://support.microsoft.com/en-gb/kb/2977003
Another option is reverse-engineering, but this will be an incredibly difficult process and cannot give you the source that you originally used to create the debug version. Your best bet is to find the version you're after, if not re-writing it.
This installation, should you have the administrator privileges to perform it, should cause the error to cease, as your system will be able to find it in Sys32/Syswow64.
Edit: I would be vary wary to download a .dll from any other site other than Microsoft's official site, malicious DLLs are readily available from dodgy sites.

Deploy a c++ game to other windows machines

I have created a c++ game with the following libraries : SDL2 and SDL2_MIXER. I want to give the game to some friends who have no programming experience to play with. Now I don't really know how to do that.
What I have tried is to use installshield limited edition with visual studio. After giving the installation program to some friends they all had a common problem-error that a dll MVCsomething was missing.
What is the simplest way to give my friends the app? Since c++ is translated to assembly do I have to compile the source again each time I change a machine?
Given the way that you've tagged your question, it is unclear if you are using Visual Studio or CodeBlocks to compile the code.
I guessing that you're compiling it in Visual Studio, and therefore they're getting an error that they don't have the appropriate MSVCRT DLLs—in other words, the C runtime library that your code depends upon, having been compiled with Microsoft's compiler. Point them to download the version of the Visual C++ Redistributable matching the version of Visual Studio that you're using on your development computer. For example, if you have VS 2015, they'll need to install Visual C++ Redistributable for Visual Studio 2015.
Alternatively, you can bundle the required redistributable into your installer to make sure that it gets installed automatically, if it isn't already. In InstallShield, I believe that's done by marking the VC++ Redistributable as a "requirement". Make sure that it's set as a prerequisite. Although, judging from the answer to this question, it may be that InstallShield LE doesn't support this. If that's the case, my advice would be to ditch InstallShield altogether and use something like Inno Setup to build an installer. There is a moderate learning curve, but it is useful knowledge. That being said, I can't believe Microsoft would ship a mechanism for creating a setup program with Visual Studio that didn't support automated installation of the CRT. I have not kept up with what Visual Studio supports nowadays with respect to setup wizards.
Since c++ is translated to assembly do I have to compile the source again each time I change a machine?
No, no. Assuming that your friends are all running Windows (and not, say, Linux) and have x86-based machines (which they do if they're running Windows), your code will work fine. The only hitch would be if you are compiling 64-bit code that runs on your machine, but they only have 32-bit machines. Then you'll need to have a 32-bit and 64-bit version. (Or a single 32-bit version, which will run on both.)

Build Visual Studio 6 project without Visual Studio

I have inherited a Visual Studio 6 C++ project. The project builds fine in Visual Studio 6 but I failed to compile certain files in the project with a gcc compiler. These issues relate to forward declarations and probably other issues. For the mean-time, I'm not interested in fixing these problems since the code is horrible. The code is also windows dependant since it uses win32 to communicate with com ports.
So, I wish to compile with an ms compiler (and build and link...) but I don't have access anymore to Visual Studio due to company policy...
What options are open to me?
THanks for your help,
Barry.
You can try downloading the free (as in beer) windows SDK. It's been a while, but I believe that these low level tools, such cl, link and make are available though these.
http://msdn.microsoft.com/en-us/windows/bb980924
But you probably will need to massage the code a little, so you might need to deal with the win api a little bit too.
Just to clarify, this is free and not associated with VS, so unless your company has some rather restrictive policies, you should be able to download and use the Windows SDK fine. Furthermore, the compiler tools should be somewhat friendly to VS6.

msvcp80d.dll not found while using TBB

I am using Intel TBB C++ for multithreading an application on visual studio 2008. When I run the executable I get a dialog saying "MSVCP80D.dll" was not found. There is so much on the net about this that it confuses me.
Please help.
EDIT: Based on answers, finally I was able to fix the "dll missing" problem. I had given a path to TBB lib of vc8 leading to dependency on vc8 dlls, which are used with visual studio 2005, not with 2008. (Using depends (http://www.dependencywalker.com/ ) it is easy to determine the run-time dependencies of an executable.) I changed by project to depend on vc9 dlls, not vc8 and then it worked fine.
Another thing to note is use of manifest files on windows. Manifest files describe dependencies. The manifest files must be generated while writing an application as it is necessary.
You can find them online at various places. Just scan it for a virus and put it in your program's path and everything should work fine. You may need more than one of the debug dlls, you can use depends32.exe to see what you are missing.
MSVC80D is VS 2005. As part of VS2008 you would have MSVC90D instead.
Your app is compiled with debug version. Debug version of VC runtime is not in path.
Try to generate release version.
Are you running the program on your development machine? If you are not, you might get this error. The "D" at the end of the filename means that the DLL is a debug DLL, and often not on computers without Visual Studio installed. You're not supposed to redistribute it (copy it around), either. You should compile a "release" version of your application and run that. If you really can't do that for some reason, and it's only one or two computers, then try installing the express version of visual studio on that computer.
If you are having this problem on your development machine, it can apparently be caused by a compiler/linker problem. Try doing a clean build ("clean", then "build" in Visual Studio).
Ok, after a lot of search, and by chance, I landed on this forum http://www.codeguru.com/forum/showthread.php?t=446789 which says something I interpret as "the version of TBB I am using does not support VS 2008".
But this still uncertain.