Game Development Community

Need a little help compiling...

by Jack Stone · in Torque Game Engine Advanced · 06/17/2005 (2:59 pm) · 26 replies

Ok, I have this nearly figured out. Im using the instructions here:
http://www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=5957
to try to compile the engine.
I couldnt find the "Platform core SDK" I just kept getting directed to a page about windows server 2003 SDK, which im assuming is the wrong one.
Also, when I downloaded the directX SDK, (December 2004 version) It said it was an "invalid win32 program" when I tried to run it. I dont know if thats because its a corrupt download or if it needs to be set up somehow, but I cant get it to install.

So the stage im at now is:
I downloaded win CVS, and the latest HEAD release of TSE no problem.
I got the Visual C++ express edition 2005 and thats running fine.

I followed the instruction in that resource, but I couldnt include the SDK files because I couldnt find the platform SDK to download it.
I also couldnt find the Torque Demo complete that step.

It seems to work though, it compiled, and gave me this at the end of it:

Build log was saved at "file://c:\tse\engine\out.VC7.DEBUG\BuildLog.htm"
Torque Shader Engine - 35 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 4 up-to-date, 6 skipped ==========

This was my second or third time building it, so I guess its skipping the successful ones.
The TSE directory on my hard drive looks complete, its got all its folders and files, but I cant see any executables to run the demo, and the tools, (converters) are still c++ headers, they dont look compiled at all.

Im now downloading a new directX SDK, february 2005, so im hoping that will work.
Any ideas how to get the engine fully compiled? I know im nearly there...
Thanks
JS

Edit: Ok I downloaded and installed the Feb 2005 DirectX SDK, but im still getting the same errors in the compiler:

------ Build started: Project: Torque Shader Engine, Configuration: Debug Win32 ------
Compiling...
atlasTQTFileD3D.cpp
c:\tse\engine\atlas\atlastqtfiled3d.cpp(8) : fatal error C1083: Cannot open include file: 'd3d9.h': No such file or directory
winWindow.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winTime.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winThread.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winStrings.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winSemaphore.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winRedbook.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winProcessControl.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winOpenAL.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winNet.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winMutex.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winMemory.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winInput.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winFont.cpp
Page «Previous 1 2
#1
06/17/2005 (4:42 pm)
C:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winFileio.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winDirectInput.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winDInputDevice.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winCPUInfo.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
winConsole.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
win32WinMgr.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
Generating Code...
Compiling...
shaderOp.cpp
c:\tse\engine\platformwin32\platformwin32.h(9) : fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
screenshotD3D.cpp
c:\tse\engine\gfx\d3d\screenshotd3d.cpp(5) : fatal error C1083: Cannot open include file: 'd3d9.h': No such file or directory
gfxD3DVertexBuffer.cpp
c:\tse\engine\gfx\d3d\gfxd3dvertexbuffer.cpp(5) : fatal error C1083: Cannot open include file: 'd3d9.h': No such file or directory
gfxD3DTypes.cpp
c:\tse\engine\gfx\d3d\gfxd3dtypes.cpp(7) : fatal error C1083: Cannot open include file: 'd3d9.h': No such file or directory
gfxD3DTextureObject.cpp
c:\tse\engine\gfx\d3d\gfxd3dtextureobject.cpp(6) : fatal error C1083: Cannot open include file: 'd3d9.h': No such file or directory
gfxD3DTextureManager.cpp
c:\tse\engine\gfx\d3d\gfxd3dtexturemanager.cpp(10) : fatal error C1083: Cannot open include file: 'd3d9.h': No such file or directory
gfxD3DShaderMgr.cpp
c:\tse\engine\gfx\d3d\gfxd3dshadermgr.cpp(1) : fatal error C1083: Cannot open include file: 'd3dx9.h': No such file or directory
gfxD3DShader.cpp
c:\tse\engine\gfx\d3d\gfxd3dshader.cpp(1) : fatal error C1083: Cannot open include file: 'd3dx9.h': No such file or directory
gfxD3DDevice.regen-states.cpp
c:\tse\engine\gfx\d3d\gfxd3ddevice.regen-states.cpp(7) : fatal error C1083: Cannot open include file: 'd3d9.h': No such file or directory
gfxD3DDevice.cpp
c:\tse\engine\gfx\d3d\gfxd3ddevice.cpp(11) : fatal error C1083: Cannot open include file: 'd3d9.h': No such file or directory
gfxD3DCubemap.cpp
c:\tse\engine\gfx\d3d\gfxd3dcubemap.cpp(5) : fatal error C1083: Cannot open include file: 'd3dx9.h': No such file or directory
gfxD3DCardProfiler.cpp
c:\tse\engine\gfx\d3d\gfxd3dcardprofiler.cpp(6) : fatal error C1083: Cannot open include file: 'd3d9.h': No such file or directory
DXDiagNVUtil.cpp
c:\tse\engine\gfx\d3d\dxdiagnvutil.h(72) : fatal error C1083: Cannot open include file: 'dxdiag.h': No such file or directory
gfxInit.win32.cpp
c:\tse\engine\gfx\gfxinit.win32.cpp(7) : fatal error C1083: Cannot open include file: 'd3d9.h': No such file or directory
Generating Code...
Creating browse information file...
Microsoft Browse Information Maintenance Utility Version 8.00.50215
Copyright (C) Microsoft Corporation. All rights reserved.
BSCMAKE: error BK1506 : cannot open file '..\engine\out.VC7.DEBUG\gfxInit.win32.sbr': No such file or directory
Build log was saved at "file://c:\tse\engine\out.VC7.DEBUG\BuildLog.htm"
Torque Shader Engine - 35 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 4 up-to-date, 6 skipped ==========
#2
06/18/2005 (2:36 am)
If you are compiling with VC 7 or 7.1, you need to ensure that you have pointed VC at the correct DX directories. The way to do this is to go to the menu tools\options and select project. From here you have a combo box which will allow you to specify the GLOBAL include, lib and source directories.

Ensure that the include directory for the new version of DX is at the top of the include directories list and do the same for the libs directories on the libs list.

Re-compile and all should be well.

edit:bad spelling :o) and to point out that this applies to VC express edition 2005 as well.
#3
06/18/2005 (3:41 pm)
That my problem though, when I go into the tools>options> visual C++ directories, I get two dropdowns: Platform, with "Win32" being the only option, and then "Show directories for" where I get the following options:
Executable files, include files, reference files, Library files, source files, and exclude directories.
I understand that im supposed to include certain folders, but when I highlight that selection, nothing happens, the rest of the window stays blank. When I click ok, it just goes back to the main developer window.
The resource that ive been trying to use says this:

"Choose "Include files" from the "Show directories for:" drop down in the top right. Add these two entries (click on the folder looking button):"
Where is the "folder looking button"? I cant see one...
#4
06/20/2005 (3:58 pm)
I could still do with a hand on this, I havent been able to get it yet. I am pretty sure the problem is that I havent included the Direct X folders when im compiling, but as my above post states, I dont have an option to do so. I tried downloading and installing the compiler again, in case it had been corrupted somehow, but it didnt change anything.
In the documentation it said that the tools>options dropdown menus do the same thing as the Include environmen variable. How would I go about including the DX folders in code? I tried it already with one file, but it didnt seem to have any effect. If I knew what file to work with, then I could probably figure out the right include code myself.
#5
06/20/2005 (4:11 pm)
Setting the directories is broken in the latest beta of that toolkit. You have to edit the files by hand if you want to modify them. Look in the included beta notes as it mentions this.
#6
06/20/2005 (7:45 pm)
Ah, thank you. I found a thing online detailing issues with the beta release, but I didnt notice that information. Now I just need to figure out how to get it to include the files.
JS
#7
06/21/2005 (11:27 am)
Setting the directories works in the VC8 Beta 2, if you want to try that.
#8
06/21/2005 (2:31 pm)
Is there a way to get that for free? I can only see an "order" link on the MS website.
#9
06/22/2005 (2:00 am)
Visual C++ Express is missing windows.h as it doesnt allow to create a Win32 application in "new project".
you have to create a new "console application" and set it to Win32 during configuration o_O

if you do that and then try to write a simple "hello world" it shows it doesnt have a "windows.h"
you definetely need the platform SDK which has the correct header files

the "Windows Server 2003 SP1 SDK" is the correct one btw

msdn.microsoft.com/library/default.asp?url=/library/en-us/sdkintro/sdkintro/devd...

they just call it "Windows Server 2003 SP1 SDK" because Windows Server 2003 SP1 is the newest supported
Target.

a step by step instruction to get it working

lab.msdn.microsoft.com/express/visualc/usingpsdk/default.aspx
#10
06/22/2005 (10:54 am)
Thank you, that guide helped a lot. Im now down to this:

------ Build started: Project: Torque Shader Engine, Configuration: Debug Win32 ------
Performing Custom Build Step
Project : error PRJ0003 : Error spawning 'cmd.exe'.
Creating browse information file...
Microsoft Browse Information Maintenance Utility Version 8.00.50215
Copyright (C) Microsoft Corporation. All rights reserved.
BSCMAKE: error BK1506 : cannot open file '..\engine\out.VC7.DEBUG\audioBuffer.sbr': No such file or directory
Build log was saved at "file://c:\tse\engine\out.VC7.DEBUG\BuildLog.htm"
Torque Shader Engine - 2 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 4 up-to-date, 0 skipped ==========

Which is a HUGE improvment over all those other errors.
The test program that I created when I was following that guide thing is experiencing the same cmd.exe error.
Im assuming cmd.exe is the final step before the program actually create the exe files and lets me run the shader engine?
and that audiobuffer error doenst sound too serious...
Any ideas why it would be having trouble spawning cmd.exe?
Thanks for all your help so far.
#11
06/22/2005 (11:21 am)
I would try a Clean Rebuild.

It says that some source browser file wasnt compiled but is about to be linked.

If you do a Release Build instead of a Debug Build it should work as it doesnt add any Source Browse stuff to the executable
#12
06/22/2005 (4:47 pm)
Ok that seemed to fix the audiobuffer error, I now only get this:

Project : error PRJ0003 : Error spawning 'cmd.exe'.
Build log was saved at "file://c:\tse\engine\out.VC7.RELEASE\BuildLog.htm"
Torque Shader Engine - 1 error(s), 0 warning(s)

I wonder if I forgot to include some directory or other? Im guessing this is a reference to the cmd.exe file that is on all systems, (command prompt) and not a specific C++ program. Do I need to include the directory cmd.exe is in?
#13
06/22/2005 (7:59 pm)
Ok that seemed to fix the audiobuffer error, I now only get this:

Project : error PRJ0003 : Error spawning 'cmd.exe'.
Build log was saved at "file://c:\tse\engine\out.VC7.RELEASE\BuildLog.htm"
Torque Shader Engine - 1 error(s), 0 warning(s)

I wonder if I forgot to include some directory or other? Im guessing this is a reference to the cmd.exe file that is on all systems, (command prompt) and not a specific C++ program. Do I need to include the directory cmd.exe is in?
#14
06/23/2005 (12:20 am)
The directory the cmd.exe is in is normally set from OS-side.
this error is difficult to solve... i think the exe already compiled correctly... maybe the error is a simple copy error
i would search your TSE folders for *.exe files... if you have a TSE.EXE somewhere you are done.

Another way of finding the cause of this error is examining the BuildLog.htm file he saved. Its more detailed and should give a clue.
maybe you can post the error relevant data in it here?
#15
06/23/2005 (10:17 am)
Ive been looking in the TSE directory after each compile, just in case, and theres no exe files. The other files seem fine though, just like in TGE.
The build log is:

Build Log Build started: Project: Torque Shader Engine, Configuration: Release|Win32
Command Lines Creating temporary file "c:\tse\engine\out.VC7.RELEASE\BAT00000526642800.bat" with contents
[
@echo off

"c:\tse\vc7\..\bin\nasm\nasmw.exe" -f win32 "c:\tse\engine\platform\platformCPUInfo.asm" -o ".\../engine/out.VC7.RELEASE/platformCPUInfo.obj"



if errorlevel 1 goto VCReportError

goto VCEnd

:VCReportError

echo Project : error PRJ0019: A tool returned an error code from "Performing Custom Build Step"

exit 1

:VCEnd
]
Creating command line "c:\tse\engine\out.VC7.RELEASE\BAT00000526642800.bat"
Creating temporary file "c:\tse\engine\out.VC7.RELEASE\BAT00000626642800.bat" with contents
[
@echo off

"c:\tse\vc7\..\bin\nasm\nasmw.exe" -f win32 "c:\tse\engine\math\mMathSSE_ASM.asm" -o ".\../engine/out.VC7.RELEASE/mMathSSE_ASM.obj"



if errorlevel 1 goto VCReportError

goto VCEnd

:VCReportError

echo Project : error PRJ0019: A tool returned an error code from "Performing Custom Build Step"

exit 1

:VCEnd
]
Creating command line "c:\tse\engine\out.VC7.RELEASE\BAT00000626642800.bat"
Creating temporary file "c:\tse\engine\out.VC7.RELEASE\BAT00000726642800.bat" with contents
[
@echo off

"c:\tse\vc7\..\bin\nasm\nasmw.exe" -f win32 "c:\tse\engine\math\mMathAMD_ASM.asm" -o ".\../engine/out.VC7.RELEASE/mMathAMD_ASM.obj"



if errorlevel 1 goto VCReportError

goto VCEnd

:VCReportError

echo Project : error PRJ0019: A tool returned an error code from "Performing Custom Build Step"

exit 1

:VCEnd
]
Creating command line "c:\tse\engine\out.VC7.RELEASE\BAT00000726642800.bat"
Creating temporary file "c:\tse\engine\out.VC7.RELEASE\BAT00000826642800.bat" with contents
[
@echo off

"c:\tse\vc7\..\bin\nasm\nasmw.exe" -f win32 "c:\tse\engine\math\mMath_ASM.asm" -o ".\../engine/out.VC7.RELEASE/mMath_ASM.obj"



if errorlevel 1 goto VCReportError

goto VCEnd

:VCReportError

echo Project : error PRJ0019: A tool returned an error code from "Performing Custom Build Step"

exit 1

:VCEnd
]
Creating command line "c:\tse\engine\out.VC7.RELEASE\BAT00000826642800.bat"
Output Window Performing Custom Build Step
Project : error PRJ0003 : Error spawning 'cmd.exe'.
Results Build log was saved at "file://c:\tse\engine\out.VC7.RELEASE\BuildLog.htm"
Torque Shader Engine - 1 error(s), 0 warning(s)

Im not really sure where to go from here... Seems that it is trying to create a batch file, and is having a problem performing a custom build step?
#16
06/23/2005 (10:51 am)
You are using Windows NT, XP or 2003?
or Windows 95/98/ME?
#17
06/23/2005 (1:22 pm)
Oh im using Windows XP professional SP2, sorry I should have mentioned that earlier.
#18
06/24/2005 (8:18 pm)
Ok just an update. I was searching on the microsoft help articles for the compiler, and I found this:
http://forums.microsoft.com/msdn/ShowPost.aspx?PostID=22101

That solved the problem for the other test application, i was generating the same cmd.exe error. But for some reason it didnt affect torque. Im not sure why applying the same technique to two different things that are experiencing the same error only fixes one... Anyway ill keep trying tomorrow...
#19
06/29/2005 (6:01 pm)
I think that the error im having is something to do with the way I have included my files. I have added and removed different files and that rebuilt the engine, which resulted in me getting different errors.
I wonder could someone who has this working with Visual C express tell me if this is right:
from the file VCprojectengine.dll.express.config: (this is what I had to modify to include files, since the menu is broken in beta 2)

Include="C:\Program Files\Microsoft Platform SDK\include;$(VCInstallDir)include;$(VCInstallDir)PlatformSDK\include;$(FrameworkSDKDir)include;C:/Program files/Microsoft DirectX 9.0

SDK (February 2005)include;C:/Program Files/Microsoft Platform SDK/include include;c:\tse\engine\platformwin32\include;"
Library="C:\Program Files\Microsoft Platform SDK\lib;"
Path="C:\Program Files\Microsoft Platform SDK\Bin;$(VCInstallDir)bin;C:\Program Files\Microsoft Visual Studio 8\VC\bin"
Reference="$(FrameworkDir)$(FrameworkVersion)"
Source="$(VCInstallDir)crt\src"


I thin I might be including a file thats not needed, or the syntax is wrong, since I had no template to go on when I was trying to add files.
JS
#20
07/01/2005 (2:48 pm)
Jack

The cmd.exe error is caused by your not including the windows\system32 directory in your executables paths under the previously mentioned directories settings (under the executable files list). Without this VC++ express can't see cmd.exe.

hope that helps
Page «Previous 1 2