Thursday, July 03, 2008

Using Mac OS X frameworks with eclipse IDE

If you are a Mac OS X programmer, you must be aware of frameworks.

If you are like me, who like to use Eclipse than XCode, You can link your programs to the proper frameworks by following steps..

Skill Level: Intermediate

step 01: Open your Eclipse project.
step 02: Right click on your project, select the "properties".
step 03: Now go to "C/C++ Build"->"Setting".
step 04: Go to the "Tool Settings" tab.
step 05: Select the "Miscellaneous" settings, under "Mac OS X C++ Linker".
step 06: You will see a text box with title "Linker Flags"

Check the following screenshot..

Step 07: Enter your framework names here.. Precede your framework name with -framework flag.

Eg: If you want to link with Carbon framework, then enter it as -framework carbon

If you want to link with more than one framework add them in the same line using space to separate them..
Eg: -framework carbon -framework opengl
Step 08: Click on Apply to apply the new build settings..

If you like this post, please leave a comment.. :-)

Technorati Tags: , , , ,


Quedepi said...

hey, thanks a ton for this post!
I've looked years for this!! :)

but I still cant use the SDL framework -.-

do you know how to do that?

Anonymous said...


Phil H said...

Thanks a bunch. This was the information I needed to link to the QT Frameworks.

Niklas H said...

Thank you! Got my SDL to work now!

-framework SDL according to above.
combined with adding the following path to the Includes for the GCC compiler:


Anonymous said...

Muchas Gracias!!

Otro ejemplo:

Para linkear con los frameworks de SFML:

-framework sfml-graphics -framework sfml-system -framework sfml-window -framework SFML

(todo en 1 linea)

Jose Flores.