48 lines
3.6 KiB
Text
48 lines
3.6 KiB
Text
Tux Paint Xcode 2.4 Project
|
|
notes by Martin Fuhrer <mfuhrer@alumni.ucalgary.ca>
|
|
|
|
This Tux Paint project file is located in a folder titled "macosx", which should in turn be placed in the root folder of the Tux Paint source code distribution. The project will then be able to access all the source code files. You will require Mac OS X 10.4 and XCode 2.4 or later to build this project.
|
|
|
|
This XCode project has been configured under the assumption that you have certain libraries and files installed in particular locations under Mac OS X. This file indicates what you must install, and where these items go. Some of the libraries are installed via the Fink package manager, which can be downloaded from <fink.sourceforge.net>
|
|
|
|
|
|
-- SDL --
|
|
|
|
You must have the following frameworks installed in /Library/Frameworks:
|
|
|
|
SDL.framework
|
|
SDL_image.framework
|
|
SDL_mixer.framework
|
|
SDL_ttf.framework
|
|
|
|
You can obtain the frameworks from the SDL website <www.libsdl.org> These frameworks contain both header files and libraries, and are copied into the Frameworks directory of the Tux Paint application bundle.
|
|
|
|
|
|
-- PNG, Internationalization, and Character Set Conversion Libraries --
|
|
|
|
Install the PNG (libpng.a), GNU internationalization (libintl.a), and character set conversion (libiconv.dylib) libraries via Fink. By default, Fink will place the libraries in /sw/lib. These libraries will be statically linked into the Tux Paint binary.
|
|
|
|
|
|
-- Universal and Cross Development --
|
|
|
|
Tux Paint can be built for PowerPC, Intel, or both (as a universal binary). Since Tux Paint depends on a number of libraries, these libraries must also be built for the same platform(s) for which you wish to build Tux Paint. The latest versions of the SDL frameworks are universal binary and work fine regardless what platform(s) you want to build for. On the other hand, when Fink installs the PNG, internationalization, and character set conversion libraries, they are built only for the platform you are currently using. If you want to build a universal binary of Tux Paint, you will need to manually compile these libraries as universal binaries (see http://developer.apple.com/documentation/Porting/Conceptual/PortingUnix/compiling/chapter_4_section_3.html for further information) and update the library paths (click on a library in Archives and choose File > Get Info).
|
|
|
|
To set the target platform for your build:
|
|
1) Choose Project > Edit Active Target 'Tux Paint'
|
|
2) Click the Build tab.
|
|
3) Set Configuration to "All Configurations" and Collection to "Customized Settings"
|
|
4) Select the "Architectures" setting and click the Edit button.
|
|
5) Select PowerPC, Intel, or both.
|
|
|
|
In order to allow the Tux Paint application to run on older versions of Mac OS X, it is necessary to compile and link against an older version of the Mac OS X SDK (eg. Mac OS X 10.2.8) using an older version of gcc (eg. gcc 3.3). Various versions of the Mac OS X SDKs and gcc can be installed from the XCode Installation DVD or disk image. Note that any libraries Tux Paint links against (eg. libraries installed by Fink) should also be compiled and linked against the same SDK, using the same version of gcc. Universal binary and Intel applications must be compiled using gcc 4.0 and the Mac OS X 10.4u SDK.
|
|
|
|
To set the desired Mac OS X SDK:
|
|
1) Choose Project > Edit Project Settings
|
|
2) Click on the General tab.
|
|
2) Choose the desired SDK from the "Cross-Develop Using Target SDK" menu.
|
|
|
|
To set the desired compiler version:
|
|
1) Choose Project > Edit Active Target 'Tux Paint'
|
|
2) Click on the Rules tab.
|
|
3) Set the desired associations between file types (eg. C++ source files) and the compiler version (eg. GCC 3.3).
|
|
|