pygame / symbian / how_to_build.txt

illume e4bef2f 

zeroth 195b49e 

illume e4bef2f 

zeroth 195b49e 
illume e4bef2f 

gamedude fdf70a7 

illume e4bef2f 

gamedude fdf70a7 

illume e4bef2f 

gamedude fdf70a7 
illume e4bef2f 

gamedude fdf70a7 
illume e4bef2f 

== Instructions to build pygame for PyS60. ==

Basic requirements:
- S60 3rd or 5th ed. SDK 
- SVN client
- Python 2.5.x

=== Getting necessary libraries ===

Run ' --no-code-docs'
- This regenerates pygame module documentation without documentation in code.

Create symbian/deps directory

Get PyS60 SDK from Maemo Garage
-- Unzip the stuff to your Symbian epocroot

Get PyS60 packaging tool
- Use the installer or get the tar.gz package.
-- Copy the PythonForS60 folder to 'deps'

Checkout ogg to symbian/deps/ogg
- IMPORTANT: Revision 7524
- SVN: 

Checkout vorbis to symbian/deps/vorbis
- IMPORTANT: Revision 7543
- SVN:
- Changes for OpenC
-- os.h:
	#if defined(__SYMBIAN32__) && defined(__WINS__)
	#include <sys/types.h> // <-- Add this
	void* _alloca(size_t size);
	#  define alloca _alloca

Get SDL for Series60
- Available at:
- Follow the instructions and copy the patched SDL S60 folder to symbian/deps/SDL

Get SDL_mixer to symbian/deps/SDL_mixer

Get SDL_ttf to symbian/deps/SDL_ttf

Get Symbian FreeType2 port to symbian/deps/sft2
- SVN:
- Changes for OpenC
-- libsft2.cpp:
  #include <sys/reent.h> // <-- Remove
  CloseSTDLIB(); in ~CSymbianFreeType() // <-- Remove

Get SDL_image to symbian/deps/SDL_image

Checkout jpeg library to symbian/deps/jpeg

Checkout PNG library to symbian/deps/libpng

- The build scripts use SCons for Symbian. 
-- Follow the installation instructions

=== Building ===

==== Basic configuration ====

1. Get certificates for the installer.
2. Go to pygame/symbian directory
3. Run
-- python cert=<path to .cer> privkey=<path to .key> passphrase=<password>
-- Now you don't need to give this information each time you build.

==== Optional configurations ====

The pygame can be built against the official(or any) pys60 version. 

- Initialize the release script by giving it information about the python dll to be linked with
- Optionally the sis file to be embedded.( UID is read directly from the sis package ) pythondll=python25 pys60_sis=Python_1.9.0_3rdEd.sis

!!! DEPRECATED. PyS60 CE based on Python 2.2 and not supported anymore. Maybe in the future.

- Use script to build the 'pygame_python' with PyS60 Community Edition,
  the depended libraries and the pygame itself. All in one.
- Give the path to the PyS60 CE's 'src' directory as a parameter for the script 
- The CE version is used to do some customizations for the Python installation. 
- The above parameters are handled automatically in that case.
- Of course, you can build the PyS60 CE manually and configure the build script as above.

# Build everything, including PyS60 CE pys60_ce_src=\projects\pys60ce\trunk\src

# Use existing python sis. Need to configure the python dll for linker. build_python=False pys60_sis=official_python.sisx pythondll=python222.dll

==== Do the build ====

- Run: 

- Run: compiler=gcce release=urel

=== Misc info ===

pygame library
- The pygame is implemented as static library to be statically linked to pygame application.