Documentation
25 April 2006
Installing
Downloading
Requirements
Installation
Building Applications
Downloading
Download the Keystone Application Framework from the
download page.
Download the following packages as required:
- keystone-x.x-src.tar.gz
- main framework source
- keystone-x.x-doc.tar.gz
- API documentation
All target platforms (Win32, Linux, etc) are packaged in the same single
distribution.
Requirements
Win32
- The Keystone Framework and Applications are built with the Microsoft Visual C++
compiler (6.0). This must be installed on the target machine before installing
the framework.
- GNU Make is required to build, rather than nmake distributed and
commonly used with MS Visual C++. GNU Make (binary) for Win32 is redistributed
with the framework
- The framework and applications built with it will function on all Win32
platforms (95, 98, 2000, XP, etc).
Linux
- The Keystone Framework and Applications are built GNU C Compiler. GCC 3.0
or later must be installed on the target machine before installing the framework.
- The framework will install and function on any Linux distribution, however
this installation note relates to Redhat and Debian
Installation
Win32
Installing Files
Extract the framework packages to a suitable directory (eg c:\keystone).
At minimum, keystone-x.x-src.tar.gz must be installed.
Environment
Keystone needs the following environment variables set to build applications:
- KEYSTONE_DIR - base directory of keystone installation
- KEYSTONE_TARGET - target platform (win32)
- KEYSTONE_WIN32_GDIP - set to 'TRUE' to build with GDI+ support
- SUFFIX_OBJ - object file suffix (.obj)
- SUFFIX_LIB - library file suffix (.lib)
- PATH - must contain 'keystone\bin\win32'
For convenience, the batch file 'keystone\bin\win32\keyenv.bat' will set the
needed environment variables for an installation in 'c:\keystone'
Building the framework
Once the environment is set up, change directory to where you have installed
in the framework eg c:\keystone), and run 'make'. This will build and install
the framework, and build the example programs
If this does not work follow these more detailed instructions:
- Change directory to where you have installed in the framework
eg c:\keystone)
- Change to the 'src' directory under this (eg cd 'src')
- Run 'make tools_build'
- Run 'make tools_install'
- Run 'make' with no arguments
- Run 'make install'
This will build the framework libraries which need to be linked with
applications.
Note that it is also possible to build the framework on Win32 with GTK, rather than
native Win32 GDI. To do so,
- make sure GTK for Windows is installed
http://gladewin32.sourceforge.net
- set the environment variable KEYSTONE_WIN32_GTK 'set KEYSTONE_WIN32_GTK=TRUE'
- build the framework
- edit makefiles to run 'keylink' with the option '--gtk'
Linux
Installing Files
Extract the framework packages to a suitable directory. For example:
- /usr/local/keystone
- /home/user/keystone
At minimum, keystone-x.x-src.tar.gz must be installed.
Environment
Keystone needs the following environment variables set to build applications:
- KEYSTONE_DIR - base directory of keystone installation
- KEYSTONE_TARGET - target platform (linux)
- KEYSTONE_GTK_CAIRO - set to 'TRUE' to build with Cairographics support
- SUFFIX_OBJ - object file suffix (.o)
- SUFFIX_LIB - library file suffix (.a)
- PATH - must contain 'keystone\bin\linux'
For convenience, a section of script to set these is in
'keystone\bin\linux\setvars'. Copy the contents of this file into
'/home/user/.bashrc' to set the environment for the Bash shell
Building the framework
Once the environment is set up, change directory to where you have installed
in the framework eg /usr/local/keystone), and run 'make'. This will build and install
the framework, and build the example programs
If this does not work follow these more detailed instructions:
- Change directory to where you have installed in the framework
eg /usr/local/keystone)
- Change to the 'src' directory under this (eg cd 'src')
- Run 'make tools_build'
- Run 'make tools_install'
- Run 'make' with no arguments
- Run 'make install'
This will build the framework libraries which need to be linked with
applications.
Building Applications
The installation is now complete.
To build the example programs:
Change directory to where you have installed in the framework
eg c:keystone)
Change to the 'examples' directory under this (eg cd 'examples')
Run 'make'