Next: , Previous: , Up: Additional Installation   [Contents]


4.1 Environment Setup

You need to make sure your environment is properly setup in order to compile and run GNUstep software. The steps to setup your environment differ slightly depending on your filesystem layout.

There is a way of setting up your environment that always works: sourcing the GNUstep.sh shell script before using GNUstep. The shell script GNUstep.sh is located in the Makefile package; you may want to add it to your shell startup file (such as .profile). For instance, if you installed GNUstep with the default filesystem layout in /usr/local, then adding

. /usr/local/share/GNUstep/Makefiles/GNUstep.sh

in your .profile file will work. Note the period at the beginning of the line, and the space between the period and the following path. If you installed GNUstep somewhere else, you need to replace /usr/local/share/GNUstep/Makefiles/GNUstep.sh with the path to your GNUstep.sh script. Another typical location is /usr/GNUstep/System/Library/Makefiles, which is the default location of your GNUstep.sh script when gnustep-make is configured with the GNUstep layout. The script defines environment variables that are needed to find GNUstep files and executables.

Users of csh need to use the GNUstep.csh script. Read the make package README for more info. Some systems, like GNU/Linux have an /etc/profile.d directory where scripts can be executed automatically. If you want to set up GNUstep for every user on your system, you can try copying/linking the GNUstep.sh there. For csh or tcsh, try

source /usr/local/share/GNUstep/Makefiles/GNUstep.csh

Finally, in most filesystem configuration it’s also possible to manually set up your environment by setting PATH, the linker library paths and the GNUSTEP_MAKEFILES variable (instead of using GNUstep.sh). For example, on GNU/Linux (with a default GNUstep installation), instead of sourcing GNUstep.sh you could manually add the Tools directories to your PATH:

PATH="/usr/local/bin:$PATH"

manually add /usr/local/lib to your /etc/ld.so.conf file (don’t forget to run ldconfig every time you install a library), and set the environment variable GNUSTEP_MAKEFILES when you want to compile something:

GNUSTEP_MAKEFILES=/usr/local/share/GNUstep/Makefiles

Next: , Previous: , Up: Additional Installation   [Contents]