2011-04-29 23 views
0

我使用MonoTouch運行MonoDevelop,並試圖在構建代碼時瞄準設備(即Debug | iPhone)。但是,當我這樣做時,編譯器會拋出一堆引用缺失程序集的錯誤。MonoTouch/MonoDevelop:將項目設置爲目標iPhone設備程序集時最終會丟失嗎?

如果我構建目標模擬器,這些錯誤不會顯示出來,我知道我已經包含了這些程序集,甚至IDE在這些程序集中鍵入它們時都會「查看」程序集和自動完成名稱空間。

任何想法可能是什麼造成的呢?我已經嘗試過的新鮮重建......

我從MonoTouch的試用版的更新,如果有什麼差別。

下面是一些錯誤的(它們都是這種錯誤的):

/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) 
+0

請將pastebin錯誤。 – 2011-04-29 20:13:08

+0

編輯和添加,我真的沒有看到它將如何幫助,但所有缺少的程序集都是在構建目標模擬器時找到並編譯的。 – tweetypi 2011-04-30 17:42:55

回答

1

如果您使用MT 4.x版則有一些比賽,當組件被編譯爲本地代碼。但是,描述中的錯誤看起來來自編譯託管代碼(並且這不是並行處理,因此不應該有任何競爭條件影響構建的那部分)。

這將使(有時)跳過鏈接時組裝,導致(硬複製)生成錯誤。這將在下一個版本的MonoTouch中得到解決。

這從未發生在模擬器上,因爲沒有AOT(編譯爲本地)在這種情況下存在的(即,JIT被使用)。

相關問題