Game Development Community

Help with the compilers

by Joshua Parker · in Torque 3D Professional · 05/30/2009 (12:39 pm) · 2 replies

What I need to know is, what is the correct way to configure my compiler (I tend to stick with VC++ 2008) to successfully do a complete rebuild of the engine so that I may take my work from TGEA 1.7.1 and impliment into the Torque 3D engine.

I have tried many times, with no success to open the source code for the "New project", "PhysX" and "FPS Genre Kit", and rebuild the code. This is a rebuild without making any changes to the source. I have tried with Visual C++ 2008 Express Edition with service pack 1, as well as Visual C++ 2005 with service pack 2. I have done this with both the Beta 1 and 2 or Torque 3D. I know that is said about making assumtions, but I would tend to believe that the errors I receive such as :
"1>c:\program files\microsoft platform sdk\include\winnt.h(2645) : error C2733: second C linkage of overloaded function '_interlockedbittestandset' not allowed"
or:
"2>c:\torque\torque 3d 2009 beta 1\my projects\my project\source\web\activex\stdafx.h(19) : fatal error C1083: Cannot open include file: 'atlbase.h': No such file or directory"

are not infact problems with the source code.(As I stated before, I have not made any changes before attempting a rebuild.) I imagine that problem is with how I have my compilers set up, but I have been unable to find the correct way to configure the compilers for Torque 3D. I have set up My VC++ directories to include C:\Program Files\Microsoft DirectX SDK (March 2009)\Lib\x86 for the executable as well as C:\Program Files\Microsoft DirectX SDK (March 2009)\Include and C:\Program Files\Microsoft DirectX SDK (March 2009)\Lib\x86 for my include and libraries. Basicly I followed the directions from the TGEA setup. I also updated all of my SDKs (direct X, windows platform, PhysX and such) but only reference the Direct X SDK in my VC++ directories. Adding any other seems to create bigger problems for me. I have uninstalled and reinstalled the compilers as well as all Torque 3D directories.


#1
05/30/2009 (10:11 pm)
Hi Parker,

I know your frustration when it seems like things should work out of the box. But lets see if I can help.

Lets start with the 2nd error that you listed. This is a known issue, and whether its a big deal or not depends on what you are looking to do. The Express edition of Visual Studio 2008 doesn't install the headers you need to be able to build the project, which is an ActiveX control to run your T3D app in Internet Explorer. If you would like to test in a web browser, I suggest you try Firefox, Chrome or Safari, all work with the alternative plugin. You can safely ignore the IE Plugin project errors otherwise. This will only be fixed if you get the full version of Visual Studio, which will install the needed headers.

Your first error unfortunately may come down to order of installation/microsoft service pack release craziness. MS release platform SDKs to coincide with major OS releases obviously, and potentially their service packs. They also release Visual Studio, and service packs for it to address bugs. Each of these have a possibility of conflicting header files. If I remember the issue that we ran into at work, Visual Studio is pointing to the wrong version of the Platform SDK, because between all the installs over time, you have multiple versions on your machine. There is a utility from MS that will tell you which version(s) you have installed, and to select the one you want the compiler to use. I believe the tool is toggling registry settings. I *don't* remember what its called, or if it comes with the Express version. Unfortunately you might need to do a bit of searching in Google to figure it out.
#2
05/30/2009 (10:44 pm)
Thanks for the reply. I did a little more reaserch into the problem, and found a clue I had missed before concerning VC++ express and whether or not it worked with Torque 3D, or if the full version of VC++ was needed. While the answer was that the express version of VC++ could work, it was clear that The full version was better suited. Having bought TGE, TGEA, and now Torque 3D, as well as numerous addons, modeling software and books, I felt the least I could do is spend the $199.00 for the standard version of Visual Studio 2008. Of course the engine compiled correctly the first time.
It doesnt solve the problem for anyone else who may facing the same situation with the express version, but I'm sure that most developers know that you can only expect so much for free. Fixing the problem would have been nice, but I feel I am better off with the piece of mind that comes from a better version of the compiler.