2011-05-05 87 views
0

我是這款iPhone的新手。所以我安裝了GNUstep編譯器,並導入了一個小程序。現在我想這個編譯並執行代碼...我使用的代碼這樣做:如何使用GNUstep編譯窗口中的目標c

gcc -o hello hello.m -I/c/GNUstep/GNUstep/System/Library/Headers \ 
-L /c/GNUstep/GNUstep/System/Library/Libraries -lobjc -lgnustep-base \ 
-fconstant-string-class=NSConstantString 

,但它給錯誤的

1./GNUstep/GNUstep/system/library/libraries:permission denied 
2.ld.exe : cannot find -lobjc 
3.ld.exe : cannot find -lgnustep-base-fconstant-string-class=NSConstantString 
collect2:id returned 1 exit status 

請幫助我的人..我有爲此添加任何新的庫?

+0

在Windows上使用GNUStep進行iOS開發?祝你好運,我希望你。 :) – 2011-05-05 12:51:12

+0

它可以在Windows上使用或不使用GNUstep?從谷歌我得到,我們可以運行使用GNUstep ...... – prathibha 2011-05-06 05:29:21

+0

是的,但GNUStep是真的不是你可以開發iPhone應用程序的東西。先購買Mac,安裝Xcode Developer Tools,然後開始開發iPhone應用程序。您需要首先能夠爲ARM編譯。 – 2011-05-06 05:32:20

回答

0

嘗試使用這個命令:

$ gcc `gnustep-config --objc-flags` -o hello hello.m -L C:/GNUstep/GNUstep/Syst 
em/Library/Libraries -lobjc -lgnustep-base 
0

我使用GNUstep的GORM做一個Objective-C的項目。 GORM將自動創建一個GNUmakefile。如果您想命令行式編譯項目,請打開Shell(您可以關閉GORM),使用cd命令切換到項目目錄,然後鍵入make。 GNUstep將編譯項目(跟隨GNUmakefile)。 Yen-Ju Chen在http://www.nongnu.org/gstutorial/en/ch10.html有一個簡單的項目。

相關問題