Game Development Community

New user--can't compile

by Laralyn McWilliams · in iTorque 2D · 08/02/2010 (6:15 am) · 5 replies

I'm new to iT2D, although I've been learning TGB for a little while. I'm trying to compile a really simple project and I'm getting a lot of errors. Here's what I did:

Follow the instructions in the resource about the Base SDK Missing error, including uninstalling old XCode and installing the latest version.

Created a iT2D project that is simply an image on the screen. I made sure the image is in the level datablocks. It runs in iT2D and compiles in XCode fine for TGB.

I opened the XCode project file for the iPhone (the one automatically created with the project) and set up the target, etc. according to the instructions in the resource.

When I compile, I get 21 errors (sorry for the lack of code tag--it gives me a site error when I use it):

Build iTorque2DGame_sim of project iTorque2D with configuration Debug

Check dependencies

[WARN]warning: no rule to process file '$(PROJECT_DIR)/../../projectFiles/Default.png' of type image.png for architecture i386
[WARN]warning: no rule to process file '$(PROJECT_DIR)/../../projectFiles/main.cs' of type text for architecture i386

ProcessPCH++ /var/folders/Ky/KyqJxxjOH345-NmdaY8iS++++TI/-Caches-/com.apple.Xcode.501/SharedPrecompiledHeaders/iTorque2D_Prefix-fmjtzvnklyanwwbmdpmfcgghexvr/iTorque2D_Prefix.pch.gch iTorque2D_Prefix.pch normal i386 objective-c++ com.apple.compilers.gcc.4_0
cd /Applications/iTorque2D_1_4/MyProjects/MyiPadTest/buildFiles/XCode_iPhone
setenv LANG en_US.US-ASCII
setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc-4.0 -x objective-c++-header -arch i386 -fmessage-length=0 -pipe -Wno-trigraphs -fpascal-strings -fasm-blocks -O0 -Wreturn-type -Wunused-variable -DTORQUE_ALLOW_MUSICPLAYER -D__IPHONE__ -DTORQUE_PLAYER -DTORQUE_DEBUG -DTORQUE_DISABLE_MEMORY_MANAGER -DPUAP_SCRIPT_CHANGE -DPUAP_OPTIMIZE -DUSE_COMPONENTS -D__IPHONE_OS_VERSION_MIN_REQUIRED=30200 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk -fvisibility=hidden -fvisibility-inlines-hidden -fobjc-call-cxx-cdtors -mmacosx-version-min=10.6 -gdwarf-2 -iquote /Applications/iTorque2D_1_4/MyProjects/MyiPadTest/buildFiles/XCode_iPhone/build/iTorque2D.build/Debug-iphonesimulator/iTorque2DGame_sim.build/iTorque2DGame-generated-files.hmap -I/Applications/iTorque2D_1_4/MyProjects/MyiPadTest/buildFiles/XCode_iPhone/build/iTorque2D.build/Debug-iphonesimulator/iTorque2DGame_sim.build/iTorque2DGame-own-target-headers.hmap -I/Applications/iTorque2D_1_4/MyProjects/MyiPadTest/buildFiles/XCode_iPhone/build/iTorque2D.build/Debug-iphonesimulator/iTorque2DGame_sim.build/iTorque2DGame-all-target-headers.hmap -iquote /Applications/iTorque2D_1_4/MyProjects/MyiPadTest/buildFiles/XCode_iPhone/build/iTorque2D.build/Debug-iphonesimulator/iTorque2DGame_sim.build/iTorque2DGame-project-headers.hmap -F/Applications/iTorque2D_1_4/MyProjects/MyiPadTest/buildFiles/XCode_iPhone/build/Debug-iphonesimulator -F"/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/ApplicationServices.framework/Frameworks" -F"/Applications/iTorque2D_1_4/MyProjects/MyiPadTest/buildFiles/XCode_iPhone/../../../../engine/lib/xiph/iPhone" -I/Applications/iTorque2D_1_4/MyProjects/MyiPadTest/buildFiles/XCode_iPhone/build/Debug-iphonesimulator/include -I../../../../engine/source -I../../../../engine/lib -I../../../../engine/lib/vorbis/include -I../../../../engine/lib/lpng -I../../../../engine/lib/ljpeg -I../../../../engine/lib/lungif -I/Classes -I../../../../engine/lib/openal/macosx/eax -I/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/CoreServices.framework/Versions/Current/Frameworks/CarbonCore.framework/Headers -I/System/Library/Frameworks/CoreServices.framework/Versions/Current/Frameworks/OT.framework/Headers -I/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/ApplicationServices.framework/Versions/Current/Frameworks/QD.framework/Headers -I/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/Carbon.framework/Versions/Current/Frameworks/HIToolbox.framework/Headers -I/System/Library/Frameworks/OpenGL.framework/Headers -I/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/Carbon.framework/Headers -I/System/Library/Frameworks/AGL.framework/Headers -I/Developer/Headers/FlatCarbon -I/Applications/iTorque2D_1_4/MyProjects/MyiPadTest/buildFiles/XCode_iPhone/build/iTorque2D.build/Debug-iphonesimulator/iTorque2DGame_sim.build/DerivedSources/i386 -I/Applications/iTorque2D_1_4/MyProjects/MyiPadTest/buildFiles/XCode_iPhone/build/iTorque2D.build/Debug-iphonesimulator/iTorque2DGame_sim.build/DerivedSources -c /Applications/iTorque2D_1_4/MyProjects/MyiPadTest/buildFiles/XCode_iPhone/iTorque2D_Prefix.pch -o /var/folders/Ky/KyqJxxjOH345-NmdaY8iS++++TI/-Caches-/com.apple.Xcode.501/SharedPrecompiledHeaders/iTorque2D_Prefix-fmjtzvnklyanwwbmdpmfcgghexvr/iTorque2D_Prefix.pch.gch

/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:250: error: expected `)' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:250: error: expected identifier before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:250: error: expected `;' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:252: error: expected `)' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:252: error: expected identifier before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:252: error: expected `;' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:254: error: expected `)' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:254: error: expected identifier before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:254: error: expected `;' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:256: error: expected `)' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:256: error: expected identifier before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:256: error: expected `;' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:258: error: expected `)' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:258: error: expected identifier before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:258: error: expected `;' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:190: error: expected `)' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:190: error: expected identifier before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:190: error: expected `;' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:193: error: expected `)' before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:193: error: expected identifier before '(' token
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:193: error: expected `;' before '(' token

Can anyone help me get this running?

Thanks! :-)

#1
08/02/2010 (6:29 am)
You need to set GCC 4.2 in the c/c++ compiler version.

for more info check
www.torquepowered.com/community/resources/view/19979
#2
08/02/2010 (2:58 pm)
It's already set to GCC 4.2 C/C++ Compiler version. Thanks! :-)
#3
08/02/2010 (3:01 pm)
Ah ha! Turns out it was set to GCC 4.0 in the target (I just checked the project settings at first). Thanks!
#4
08/02/2010 (6:49 pm)
yeah the target settings vs project settings is a common root of trouble, you can be assured that you will soon check both like in a reflex
#5
08/02/2010 (10:17 pm)
And in Xcode 4.x it will hopefully be somewhat sane by default :)