Template:Other Interfaces

This is an old revision of Template:Other Interfaces, edited by Mattias2 at . The current revision is 50009.

/* Using the Gtk1 interface under Mac OS X */

Other Interfaces

Platform specific Tips

Interfaces Development Articles

Using the Gtk1 interface under Mac OS X

If you want to build gtk1 applications on Mac OS X you need X11 and GTK 1.2 too:

Apple X11: On a new system: choose "Customize" in the install dialog, check "X11".

On an already installed system:

MacOSX 10.3: download at:

http://www.apple.com/downloads/macosx/apple/x11formacosx.html

MacOSX 10.4: install X11 from the DVD.

GTK 1.2: Downloading the GTK packages and installing them properly can be a time consuming task. Therefore there are various package managers. One of them is fink:

Download fink from http://fink.sourceforge.net/download/index.php?phpLang=en; follow the install instructions.

In the Terminal, run

       sudo /sw/bin/apt-get install gdk-pixbuf gtk+ gtk+-data gtk+-shlibs gtk-doc gtk-engines

The X11 application is in /Applications/Utilities/X11. You can drag and drop it on the dock so you can start it with one click. X11 on Mac OS X 10.5 (Leopard) is different and starting X11.app is not recommended.

Tip: Most X11 programs, including Lazarus, expect to receive focus when the user clicks on a window. Under Mac OS X this is deactivated. You can activate it for all X11 applications by typing in the terminal:

       defaults write com.apple.x11 wm_click_through -bool true

When compiling GTK-related software, you need to add two lines to the fpc.cfg file, to enable use of libraries:

-Fl/sw/lib
-Fl/usr/X11R6/lib