The building of OBJECT-C integrated development environment based on Windows platform

Source: Internet
Author: User

This time began to learn iOS development, for some basic environment settings, access to information after the work out.

Data Link: http://wenku.baidu.com/view/9ffed817f18583d0496459ca.html

There are three options to build an environment for developing iOS:

One, buy an Apple computer, developed with Xcode.

Second, build a OBJECT-C development environment based on Windows.

Three, install an Apple virtual machine, in the virtual machine with Xcode development.

The first and third scenario here is not going to be said, say a second plan.

First, we need to download four files on the http://www.gnustep.org/windows/installer.html.

650) this.width=650; "src="/e/u261/themes/default/images/spacer.gif "style=" Background:url ("/e/u261/lang/zh-cn/ Images/localimage.png ") no-repeat center;border:1px solid #ddd;" alt= "Spacer.gif"/>650 "this.width=650;" src= "http ://s3.51cto.com/wyfs02/m02/6c/71/wkiol1vjs-szu81raalgr7qepve257.jpg "title=" qq picture 20150506141917.png "alt=" Wkiol1vjs-szu81raalgr7qepve257.jpg "/>


After downloading these four files, install the files in order from top to bottom, note that they must be in order from top to bottom, otherwise there may be problems. Installation location does not matter, personal advice to pay attention to which disk's free space is relatively large to put where it.


After installation, you also need to go to Http://www.codeblocks.org/downloads/26 to download codeblocks, the integrated development Kit,

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/6C/71/wKioL1VJtj3QPVYaAALmy2CLZAE437.jpg "title=" QQ picture 20150506142859.png "alt=" Wkiol1vjtj3qpvyaaalmy2clzae437.jpg "/>


After the download is ready, install it and be sure to install the four programs above GNUstep before installing this file . Install the open codeblocks will appear as:

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/6C/71/wKioL1VJt7_zQoEPAAPiwHhBcYQ057.jpg "title=" QQ picture 20150506143531.jpg "alt=" Wkiol1vjt7_zqoepaapiwhhbcyq057.jpg "/>


The first time to open Codeblocks interface is not like this, but do not care, click on the default settings (if asked whether to open all C code with Codeblocks, personal recommendation Select No)

Then see the interface as above and start setting up codeblocks.


The first step: Editor Configuration

Click Settings->compiler ..., see, select Copy, rename to "GNUstep MinGW Compiler",

Then click OK to save.

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M02/6C/71/wKioL1VJu-KgYsi5AARnNhOEtfU343.jpg "style=" float: none; "title=" QQ picture 20150506144932.png "alt=" Wkiol1vju-kgysi5aarnnhoetfu343.jpg "/>

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M00/6C/71/wKioL1VJvGKjHTOkAACHBO6jf84290.jpg "style=" float: none; "Title=" Modified before "alt=" Wkiol1vjvgkjhtokaachbo6jf84290.jpg "/>

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M00/6C/76/wKiom1VJuvGy_FrMAACYrcmAoq4306.jpg "style=" float: none; "title=" Modified "alt=" Wkiom1vjuvgy_frmaacyrcmaoq4306.jpg "/>

After that, click the other Options option, enter "-fconstant-string-class=nsconstantstring-std=c99",

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/6C/76/wKiom1VJu7qziKHlAAE_osUKS6E199.jpg "title=" Please note that the Red section "alt=" Wkiom1vju7qzikhlaae_osuks6e199.jpg "/>

Please note the Red section.


Step Two: Connector settings

With linker settings selected, click the Add button at link libraries to add two files,

LIBGNUSTEP-BASE.DLL.A, LIBOBJC.DLL.A, can see that I have added.

File directory for your installation GNUstep location, mine is in the F:\IOS\ directory,

namely F:\IOS\GNUSTEP\GNUSTEP\SYSTEM\LIBRARY\LIBRARIES\LIBGNUSTEP-BASE.DLL.A

F:\IOS\GNUstep\GNUstep\System\Library\Libraries\libobjc.dll.a

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/6C/76/wKiom1VJvZLSEsUHAAHAO4sosjU393.jpg "title=" QQ picture 20150506150222.png "alt=" Wkiom1vjvzlsesuhaahao4sosju393.jpg "/>

(Please note the red part)


Step Three: Specify the search directory Search Directories

Compiler Settings directory, click Add, Add Headers directory

F:\IOS\GNUstep\GNUstep\System\Library\Headers ( This is my installation directory, please modify according to the personal installation directory )

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/6C/76/wKiom1VJvyLRpqH9AAGJzvD_Aro761.jpg "title=" QQ picture 20150506151314.png "alt=" Wkiom1vjvylrpqh9aagjzvd_aro761.jpg "/>

Connector Settings Directory

F:\IOS\GNUstep\GNUstep\System\Library\Libraries

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/6C/76/wKiom1VJv77QhNiYAAGk3BzQiaY393.jpg "title=" QQ picture 20150506151621.png "alt=" Wkiom1vjv77qhniyaagk3bzqiay393.jpg "/>

Then click OK to save the exit.



Fourth step: Add object-c Supported file types

Select Settings->environment ..., select files extension handling, click the New button to add *.m,

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/6C/72/wKioL1VJw3vCTgIrAAHACM_Q6A4286.jpg "title=" QQ picture 20150506152606.jpg "alt=" Wkiol1vjw3vctgiraahacm_q6a4286.jpg "/>

Then click OK to save the exit.

Then click Project->project tree->edit File Types & categories ..., select sources, add *.m;

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/6C/76/wKiom1VJwwTigFirAAFTBs0AmNQ992.jpg "title=" QQ picture 20150506153021.png "alt=" Wkiom1vjwwtigfiraaftbs0amnq992.jpg "/>

Then enter Settings->editor ..., find syntax highlighting, click Filemasks ..., then in the popup box

Enter "*.M,",

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M02/6C/76/wKiom1VJxE6A7xD3AAIXdvEz0cU602.jpg "style=" float: none; "title=" QQ picture 20150506153326.jpg "alt=" Wkiom1vjxe6a7xd3aaixdvez0cu602.jpg "/>

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M00/6C/72/wKioL1VJxcCyN0yVAAHnSRE0KlQ658.jpg "style=" float: none; "title=" QQ picture 20150506153539.png "alt=" Wkiol1vjxccyn0yvaahnsre0klq658.jpg "/>

Then click Keywords ... (Filemasks ... The Next button), and then at the end of the popup box, add

Imaginary _complex _imaginary _bool _pragma @interface @implementation @end @class @selector @protocol, @public @protected @private ID BOOL YES NO SEL nil NULL Self

Please compare your pop-up box content, if some parts exist, you can not add,

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/6C/72/wKioL1VJx2vxZARSAAJPCHXnIkY923.jpg "title=" QQ picture 20150506154300.png "alt=" Wkiol1vjx2vxzarsaajpchxniky923.jpg "/>

Click OK to save, OK, the basic settings are almost complete. Start writing the code and verify it.


First new project, File->new->project ..., select Console Application

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/6C/77/wKiom1VJzQiRX5HWAAJcNoIQgmE914.jpg "title=" QQ picture 20150506161302.png "alt=" Wkiom1vjzqirx5hwaajcnoiqgme914.jpg "/>

Next, select C

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/6C/77/wKiom1VJzWnDnNXBAAET_QOZ_e8053.jpg "title=" QQ picture 20150506161434.png "alt=" Wkiom1vjzwndnnxbaaet_qoz_e8053.jpg "/>

Then next, fill in the project name, and then choose a favorite folder to change the project, I wrote the test

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/6C/77/wKiom1VJzfCy04p_AAGIdWtRViA826.jpg "title=" QQ picture 20150506161700.png "alt=" Wkiom1vjzfcy04p_aagidwtrvia826.jpg "/>

Then just take the next step and finish the job.

You can then see, however, that we need to change the main.c file suffix to. m, check main.c, right-click Rename,

Add the code again,

#include <stdio.h>
#include <stdlib.h>
#import <Foundation/Foundation.h>
int main (int argc, const char *argv[])
{
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];

NSLog (@ "%@", @ "Hello World");

[Pool drain];

return 0;
}

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M00/6C/78/wKiom1VJ0CPiDUASAAFf8VZtCg4790.jpg "style=" float: none; "title=" QQ picture 20150506162126.png "alt=" Wkiom1vj0cpiduasaaff8vztcg4790.jpg "/>

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M01/6C/73/wKioL1VJ0ZWwFfPEAAD9esHG6fQ548.jpg "style=" float: none; "title=" QQ picture 20150506162212.png "alt=" Wkiol1vj0zwwffpeaad9eshg6fq548.jpg "/>

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M01/6C/78/wKiom1VJ0CSQRmXCAAGFViUrrKM329.jpg "style=" float: none; "title=" QQ picture 20150506162624.png "alt=" Wkiom1vj0csqrmxcaagfviurrkm329.jpg "/>

Then click Build->build, or CTRL+F9, see if the Build log has no error, if not, you can start the run.

(This step is somewhat similar to the C language development of VC6 or vs.)

If it appears, it is successful.

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/6C/74/wKioL1VJ06mCD8RXAAL23T2r_dE284.jpg "title=" QQ picture 20150506163355.png "alt=" Wkiol1vj06mcd8rxaal23t2r_de284.jpg "/>

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/6C/78/wKiom1VJ0lXQ-48AAADIHwJ8cyI429.jpg "title=" QQ picture 20150506163451.png "alt=" Wkiom1vj0lxq-48aaadihwj8cyi429.jpg "/>


Well, that's the way the general environment is built. For the development of a Mac system on a virtual machine, see the following link:


VM11 Installing the MAC System && development environment configuration

Http://jingyan.baidu.com/article/ff411625b9011212e48237b4.html


Http://www.cnblogs.com/gabo/p/4279779.html


http://blog.csdn.net/lizhenmingdirk/article/details/31784441011212e48237b4.html%EF%BC%89














This article is from the "Happy is good" blog, please be sure to keep this source http://11611854.blog.51cto.com/5414664/1643490

The building of OBJECT-C integrated development environment based on Windows platform

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.