   System Configuration

   First  note that the configuration file is described here for no other
   purpose  than  description ;-) The installer program should be used to
   set and modify the file. See [1]the install command for more details.

   System  customisation  is  performed  thanks to the configuration file
   (sometimes  still  called  the  system.se file, in memory of old times
   when the name was compulsory).

   This  file  may be found in usual places such as /etc or $HOME on Unix
   or  Linux,  or  %USERPROFILE% on Windows. In any case, the SmartEiffel
   variable may be used to set the path name of the configuration file.

   The configuration file is normally created by the installer (or reused
   if  it already exists). For more information on the installer, see the
   [2]install command.

   Among  other  things,  the  configuration  file  tells SmartEiffel the
   system  type  it  is installed upon. When the system name is correctly
   set,  SmartEiffel performs some automatic customisations. For example,
   if  the  system  is  set  to DOS, SmartEiffel uses the suffix .BAT for
   script files and the suffix .EXE for executables files.

   The  configuration  file  also  contains  various  values to customize
   SmartEiffel  with  the  system,  the C compiler and the linker used as
   well as the default load path used to look for Eiffel source code.

   The SmartEiffel Environment Variable

   The environment variable SmartEiffel may be set with the absolute path
   of the configuration file, which is traditionally in the sub-directory
   sys of the installation directory.
   Under  a  UNIX-like  system,  the value of the SmartEiffel environment
   variable may be for example: /usr/lib/SmartEiffel/sys/system.se

   If  the  SmartEiffel  variable  is  not set, the configuration file is
   sought  in  standard  places,  which  depend on the system SmartEiffel
   guesses  it  is running upon (which may not be as accurate as what you
   set in the configuration file itself).
     * On  Unix  or  Linux,  the  standard  places  are  (in  that order)
       $HOME/.serc and /etc/serc
     * On   Windows,   the   standard   places   are   (in   that  order)
       %USERPROFILE%\SE.CFG and C:\SE.CFG
     * On other systems, no one contributed standard locations, therefore
       the SmartEiffel variable is still mandatory.

   The configuration file

   The  configuration file is divided into sections, each section being a
   set of key-value pairs.

   There  are two kinds of sections: special ones (with special meaning),
   and  any  other  section  describing  a  C  mode  (more about C modes:
   [3]here).

   The special sections are:

   [General] The main section of the configuration file. It describes a
   few paths (location of binaries, the sys directory, and the short
   directory), the operating system type (see [4]below), and a version
   tag (the latter gives a compatibility level of the configuration
   file).
   [Environment]   This  section  contains  keys  that  can  be  used  as
   pseudo-environment  variables,  in other sections of the configuration
   file  (typically  [Loadpath], see below) or an ACE file. The installer
   at  least  defines  three  variables:  path_tutorial,  path_tools, and
   path_lib,  which  define  resp.  the path to the tutorial classes, the
   classes  of  the SmartEiffel tools, and the classes of the SmartEiffel
   standard library.
   [Loadpath]  This  section  contains  the  default  load  paths used by
   SmartEiffel.  The  key is a description, and that's its only purpopse.
   The value of each key is a path either to a directory of, more likely,
   to a loadpath.se file.
   Note  that  those paths may use variables from the program environment
   (os-dependant),  or  variables  described in the [Environment] section
   (see above).
   Also  note  that  the  paths  are  searched  in  the  given order. The
   installer defines at least three paths: lib, tools, and tutorial which
   have  similar  meanings  than  their  [Environment]  counterparts (see
   above).

   The    standard    C   mode   sections   are:   [boost],   [no_check],
   [require_check],   [ensure_check],   [loop_check],   and  [all_check].
   Usually,  an  extra  C  mode, [release] is also defined. Note that the
   first ones are associated to each check level of the compiler, but one
   may change the C mode using the -c_mode flag.
   Each C mode may define the following keys:

   c_compiler_type Gives the compiler type the actual C compiler conforms
   to. See [5]below to know which compiler types are known. This compiler
   type is used when extra options have to be automatically added by
   SmartEiffel. Their format will respect the one of the given cuompiler
   type. This key is mandatory.
   c_compiler_path  Gives  the actual path of the C compiler. If not set,
   the name of the compiler type will be used.
   c_compiler_options  Gives  the  options  to  be given to the compiler,
   whatever else is added by SmartEiffel.
   c_linker_path Gives the path to the C linker. If not set, the compiler
   path will be used (itself perhaps being the compiler type if not set).
   c_linker_options Gives the options to be given to the linker, whatever
   else is added by SmartEiffel.
   cpp_compiler_type  Gives  the  compiler  type  the actual C++ compiler
   conforms to. See [6]below to know which compiler types are known. This
   compiler  type  is  used  when  extra options have to be automatically
   added  by  SmartEiffel. Their format will respect the one of the given
   cuompiler  type.  If  not  set,  SmartEiffel  won't be able to compile
   programs using external "C++" code.
   c++_compiler_path  Gives  the  actual path of the C++ compiler. If not
   set, the name of the compiler type will be used.
   cp_compiler_options  Gives  the  options  to be given to the compiler,
   whatever else is added by SmartEiffel.
   cpp_linker_path  Gives  the  path  to  the C++ linker. If not set, the
   compiler  path will be used (itself perhaps being the compiler type if
   not set).
   cpp_linker_options  Gives  the  options  to  be  given  to the linker,
   whatever else is added by SmartEiffel.
   smarteiffel_options Gives extra options to give to SmartEiffel. Only a
   subset   of  the  known  options  are  supported:  -no_gc,  -no_strip,
   -no_split, -sedb and -profile.

   The  os key of the [General] section of the configuration file is used
   by  SmartEiffel  to  know  which  operating  system  is  running.  The
   currently supported values are:

   UNIX      for all UNIX-like systems, GNU/Linux, HP-UX, Solaris, SunOS,
             Irix, XENIX, etc.
   Windows   for Windows 95 and Windows NT systems (using long filenames).
   DOS       for MS-DOS systems or Windows 3.x (using short filenames, with 8.3
             scheme).
   Macintosh for Macintosh systems (68K and PPC)
   BeOS      for the BeOS system
   Amiga     for the Amiga system
   OS2       for IBM OS/2 systems
   VMS       for the VMS systems

   The known C compilers

   The  c_compiler_type  of each C-mode section is used to describe which
   compiler type is to be used. The exact path to both the C compiler and
   the linker may then be set.
   For example:
[boost]
c_compiler_type: gcc
c_compiler_path: /usr/bin/gcc-3.4

   At the current time, the supported compiler types are:

   gcc The free and open-source GNU C Compiler and its variants (egcs,
   mingw32, etc.) on several platforms (Linux and other UNIXes, Windows).
   cc The standard cc compiler, as provided by vendors of most UNIX and
   VMS systems.
   lcc-win32 The free port of lcc for Windows platforms.
   bcc32 The Borland (now Inprise) C/C++ compiler on Windows platforms.
   bcc32i A variant of the previous one.
   wcl386 The Watcom C/C++ compiler for Windows platforms.
   cl The MicroSoft C/C++ compiler for Windows platforms.
   sas_c The SAS C compiler, sc on Amiga platforms.
   dice The dice C compiler.
   vbcc The vbcc C compiler.
   ccc The Compaq C compiler for AlphaLinux.
   sc ??
   vpcc ??
   OpenVMS_CC ??
   tcc The Tiny C Compiler. Fast and small (Windows or Linux)

   Some  other  compilers  may  be  supported  by the compiler, but their
   "type" is near enough to a kneown one not to need a special value. For
   example, icc is also supported by the SmartEiffel installer.

   SmartEiffel  will  automatically  generate  the correct system call to
   this C compiler, with the appropriate linker and adequate object files
   suffix.
   In case an unknown compiler name is supplied, SmartEiffel generates an
   error  message  listing  the  supported  compiler  names.  In case the
   compiler  specified  is  a correct one but can't be found, SmartEiffel
   won't  be  able  to detect it, but there will be an error message from
   the  system. In -verbose mode, the systems calls to the C compiler are
   displayed, thus making it easy to find such errors.

   Changing the Default Loading Path

   All  the  commands  use the same algorithm to search for Eiffel source
   files.  The  default  global  loading  path  is  set in the [Loadpath]
   section of the configuration file (see above).

   To  change  this  default loading path, you need to add a special file
   which  name  is  loadpath.se  in  the  directory  in  which you type a
   [7]command  of  SmartEiffel  (compile,  finder,  pretty, compile_to_c,
   compile_to_jvm, short, clean).

   Each  line  of the file loadpath.se must be an existing directory path
   or   the   absolute  path  of  another  loadpath.se  file  to  include
   recursively. Environment variable may be used in these lines, with the
   syntax ${MY_VAR} (also, environment variables set in the configuration
   file  are  supported).  But  those  paths  are  best relative to their
   current  directory. In that case, they are written in the Unix way and
   are independant from the operating system.

   Moreover,  a  loadpath.se  may contain references to other loadpath.se
   files  thus  alowping  the  construction  of  complex  load paths from
   several libraries. Note that the nesting is limitted to 5 levels deep.

   All  directories  of the local loadpath.se file are added ahead of the
   default  loading  path.  All  directories are searched in the order in
   which they appear. The current directory is not included in the search
   path unless it is explicitly specified in one of the loadpath.se. Also
   note  that  an  empty  line  in a loadpath.se file may add the current
   working directory in a place you don't want.

   To  check  that  your loading path is correctly set, just type command
   finder using an unknown class name as argument.

   Sample loadpath.se file under UNIX
   /users/myself/one_dir/
   ../../another_dir/
   ${MY_LIB}/goodies/
   /users/${MY_BUDDY}/common/loadpath.se
   ./
   The first line is an absolute path to some directory.
   The second one is a relative path to some directory.
   The  third  line  shows the use of an environment variable to point to
   some directory.
   The fourth line also features an environment variable, but points to a
   second  loadpath  file,  that  will  be  included  before  the general
   loadpath.UNIX file.
   The fifth line adds the current directory to the loadpath.

   Sample loadpath.se file under Windows
   C:\myself\one_dir\
   ..\..\another_dir\
   ${MY_LIB}\goodies\
   \users\${MY_BUDDY}\common\loadpath.se
   .\
   Same  explanations  as  above,  except  of  course  that  this file is
   prepended in front of the loadpath.Windows file.

                                   [Line]
             Copyright  Dominique COLNET and Suzanne COLLIN -
                         [8]<SmartEiffel@loria.fr>
                Last modified: Sun Nov 28 06:50:34 CET 2004

References

   1. file://localhost/home/colnet/SmartEiffel/man/install.html
   2. file://localhost/home/colnet/SmartEiffel/man/install.html
   3. file://localhost/home/colnet/SmartEiffel/man/install.html#CMODES
   4. file://localhost/home/colnet/SmartEiffel/man/system.html#SYSTEM
   5. file://localhost/home/colnet/SmartEiffel/man/system.html#COMPILER
   6. file://localhost/home/colnet/SmartEiffel/man/system.html#COMPILER
   7. file://localhost/home/colnet/SmartEiffel/man/commands.html
   8. mailto:SmartEiffel@loria.fr
