Reputation: 22926
I'm running MonoDevelop with MonoTouch and am trying to target a device (i.e. Debug|iPhone) when building the code. However when I do that the compiler throws a bunch of errors referring to missing assemblies.
If I build to target a simulator these errors don't show up, I know I have the assemblies included and even the IDE 'sees' the assemblies and autocompletes namespaces in these assemblies as I type them out.
Any ideas what could be causing it? I've already tried fresh rebuilds...
I updated from a trial version of MonoTouch if that makes any difference.
Here are some of the errors (they're all this sort of error):
/Users/ahmedhakeem/Documents/Projects/iOS/MyCode/Engine/Util/UI/MenuObj.cs(31,31): Error CS0234: The type or namespace name `Audio' does not exist in the namespace `Microsoft.Xna.Framework'. Are you missing an assembly reference? (CS0234) (Engine-MonoTouch)
/Users/ahmedhakeem/Documents/Projects/iOS/MyCode/Engine/Util/UI/MenuObj.cs(31,31): Error CS0234: The type or namespace name `Media' does not exist in the namespace `Microsoft.Xna.Framework'. Are you missing an assembly reference? (CS0234) (Engine-MonoTouch)
/Users/ahmedhakeem/Documents/Projects/iOS/MyCode/Engine/JabJect.cs(40,40): Error CS0246: The type or namespace name `ContentManager' could not be found. Are you missing a using directive or an assembly reference? (CS0246) (Engine-MonoTouch)
/Users/ahmedhakeem/Documents/Projects/iOS/MyCode/Engine/Media/Sprite.cs(31,31): Error CS0234: The type or namespace name `Audio' does not exist in the namespace `Microsoft.Xna.Framework'. Are you missing an assembly reference? (CS0234) (Engine-MonoTouch)
/Users/ahmedhakeem/Documents/Projects/iOS/MyCode/Engine/Scene/GameScene.cs(42,42): Error CS0246: The type or namespace name `ContentManager' could not be found. Are you missing a using directive or an assembly reference? (CS0246) (Engine-MonoTouch)
Upvotes: 0
Views: 674
Reputation: 43553
If you're using MT 4.x then there were some races when the assemblies were compiled into native code. However the errors from your description looks to be from compiling managed code (and that's not done in parallel so there should not be any race condition affecting that part of the build).
That would make it (sometimes) skip an assembly at link time, leading to (hard to reproduce) build errors. This will be fixed in the next release of MonoTouch.
This never happens on the simulator since there's no AOT (compile to native) occurring in that case (i.e. the JIT is used).
Upvotes: 1