Home Iphone Objectivec Objective C on Mac



Objective C on Mac
Posted on: September 12, 2008 at 12:00 AM
I this section we will show you how to compile and run Objective C program on Mac machine.

Objective C on Mac

     

I this section we will show you how to compile and run Objective C program on Mac machine.

Compiling Objective C on Mac OS x

To Compile Objective-C Programs on Mac OS X

This is a simple process to compile and run the code. Follow the steps given below:
1. Set path to the directory where hello.m saved and compile with the following command

 

 



$ gcc -o hello hello.m \ -L /System/Library/Frameworks/Foundation.framework/Foundation

Here -L option is used to locate the library files used in the code.

2. To run the code use the command..

$ ./hello

3. Output will be.....

2008-01-26 23:10:32.983 hello[381:10b] hello world!

 

Related Tags for Objective C on Mac:
cmaccomobjectiocompilepilthisshowprogrammpitoramrunsheilsectionmachineinmjpihowobjobjectiveprosisllivandssthshochijeprndonomogro


More Tutorials from this section

Ask Questions?    Discuss: Objective C on Mac   View All Comments

Post your Comment


Your Name (*) :
Your Email :
Subject (*):
Your Comment (*):
  Reload Image
 
 

Ask Questions?

If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.

Ask your questions, our development team will try to give answers to your questions.