Next: Usage of Header Files
Up: Technical Information
Previous: Libraries and Packages
  Contents
  Index
Subsections
Compiling the Source Code Package
The LEDA main directory of the source code package should contain the
following files and subdirectories:
| README |
information about LEDA |
| CHANGES (please read !) |
most recent changes |
| FIXES |
bug fixes since last release |
| Install/ |
documentation for installation and usage |
| Manual/ |
sources for user manual |
| MANUAL.ps |
postscript version of user manual |
| MANUAL.pdf |
PDF version of user manual |
| man_html/ |
HTML version of user manual |
| license.txt |
license text |
| lconfig |
configuration command for unix |
| lconfig.bat |
configuration command for windows |
| Makefile |
make script |
| confdir/ |
configuration directory |
| incl/ |
include directory |
| src/ |
source files |
| test/ |
example and test programs |
| demo/ |
demo programs |
| demo_cout/ |
command line demo programs |
- Go to the LEDA main directory.
- Type: lconfig <cc> [static | shared]
where <cc> is the name (or command) of your C++ compiler
and the optional second parameter defines the kind of libraries
to be generated. Note that in the current release shared
libraries can be made only under SunOS 5.x (Solaris), Linux, and
IRIX.
Examples: lconfig CC, lconfig g++, lconfig
sunpro shared
lconfig without arguments prints a list of known compilers.
If your compiler is not in the list you might have to
edit the <LEDA/sys/unix.h> header file.
Type make for building the object code libraries
| libL.a (libL.so) |
main library |
| libG.a (libG.so) |
graph library |
| libP.a (libP.so) |
d2-geo library |
| libD3.a (libP.so) |
d3-geo library |
| libW.a (libW.so) |
window library |
| libGeoW.a (libGeoW.so) |
GeoWin library |
(*.so if shared libraries are used)
Now follow the instructions given in Section UnixObjectCodePackage.
- Set the Environment Variables for Visual C++:
The compiler CL.EXE and the linker LINK.EXE require that the environment
variables PATH, INCLUDE, and LIB have been set properly.
PATH must point to the
\bin subdirectory of your Visual
C++
installation, LIB must point to
\lib, and INCLUDE to
\include.
When you installed Visual C++, setup created a batch file,
VCVARS32.BAT,
containing the commands to modify the PATH, LIB, and INCLUDE environment
variables. Run VCVARS32.BAT before you compile at the command prompt.
To run VCVARS32.BAT:
- At the command prompt, change to the
\bin subdirectory of
your Visual C++ installation
(for instance c:
\programs
\microsoft developer
studio
\vc98
\bin ).
- Run VCVARS32.BAT by typing VCVARS32.
- Go to the LEDA main directory.
- Type: lconfig msc [dll] [ ml | mld | md | mdd | mt | mtd ]
Remark: When building an application with LEDA and MS Visual
C++, the LEDA library you use depends on which Microsoft C runtime library
you intend to link with.
Your application code and LEDA both must be linked to the same
Microsoft C runtime library; otherwise serious linker or runtime
errors may occur.
The Microsoft C runtime libraries are related to the compiler
options as follows
| C Runtime Library |
Option |
| LIBC.LIB |
-ML |
| LIBCD.LIB |
-MLd |
| LIBCMT.LIB |
-MT |
| LIBCMTD.LIB |
-MTd |
| MSVCRT.LIB |
-MD |
| MSVCRTD.LIB |
-MDd |
In order to get the suitable Libs or DLL please choose the
corresponding option in the call of lconfig.
lconfig without arguments prints a list of known compilers.
Type make_lib for building the object code libraries
| static: |
libL.lib |
basic library |
| |
libG.lib |
graph library |
| |
libP.lib |
d2-geo library |
| |
libD3.lib |
d3-geo library |
| |
libGeoW.lib |
GeoWin library |
| |
libW.lib |
window library |
| |
|
|
| dynamic: |
leda.dll |
|
| |
leda.lib |
|
Now follow the instructions given in Section WinObjectCodePackage.
Next: Usage of Header Files
Up: Technical Information
Previous: Libraries and Packages
  Contents
  Index
© Copyright 1998-2001, Algorithmic Solutions Software GmbH. All rights reserved.
2001-02-21