********************************************************************* * * * LEDA 6.5 * * * * SOURCE CODE INSTALLATION * * * ********************************************************************* 0. Contents of File ------------------- I. Directory Overview II. Configuration on Unix III. LEDA Compilation on Unix IV. Configuration for MS Visual C++ V. LEDA Compilation with MS Visual C++ I. DIRECTORY OVERVIEW: ---------------------- The LEDA main directory should contain the following files and subdirectories: Readme.txt overview of LEDA documentation CHANGES (please read !) most recent changes of LEDA FIXES bug fixes since last release of LEDA Install/ installation and usage of LEDA license.txt license text lconfig configuration command for unix lconfig.bat configuration command on MS Windows Makefile make script confdir/ configuration directory incl/ include directory src/ source files compiled into the free edition src1/ remaining source files demo/ demo programs test/ test programs II. CONFIGURATION FOR UNIX -------------------------- 1. Dependencies 32 bit Linux operating systems on x86 archtitectures need the netwide assembler nasm in order to correctly compile the LEDA sources. Please download nasm from http://sourceforge.net/projects/nasm 64 bit Linux operating system on x86_64 architectures need yasm in order to correctly compile the LEDA sources. Please download nasm from http://www.tortall.net/projects/yasm/ 2. Go to the LEDA main directory 3. Type: lconfig [static | shared] where 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 for SunOS 5.x (Solaris), and some Linux distributions. 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 header file. If you're installing on a windows machine, please read the following sections. III. LEDA Compilation on UNIX ----------------------------- Type make for building the object code library libleda.a (libleda.so) main library (libleda.so if the shared library is used) Now follow the instructions given in File Install/unix.txt. IV. Configuration for MS Visual C++ ------------------------------------ 1. Dependencies LEDA can be compiled with the following Visual Studio compilers: Visual Studio 2003 .NET and Visual Studio 2005 (32 bit) Additionally, you need the netwide assembler nasm ( see http://sourceforge.net/projects/nasm ) 2. Setting 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. When Visual C++ was installed, setup created a batch file, VCVARS32.BAT for MS Visual Studio 6 and VSVARS32.BAT for MS Visual C++ .NET, containing the commands to modify PATH, LIB, and INCLUDE. Run VCVARS32.BAT (VSVARS32.BAT) before you compile LEDA as follows. (a) At the command prompt, change to the \bin subdirectory of your Visual C++ installation ( ,e.g., c:\programs\microsoft visual studio\vc98\bin). (b) Type VCVARS32 (VSVARS32). 3. Add the netwide assembler "nasm" to the PATH variable 4. Go to the LEDA main directory (at the command prompt used above). 5. Type: lconfig msc [dll] [ ml | mld | md | mdd | mt | mtd ] Remark: When building an application with LEDA and MS Visual C++ .NET, the LEDA library you use depends on the 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. V. LEDA Compilation with MS Visual C++ --------------------------------------- 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 , libgeow.lib Remarks: GeoWin is currently not available as a DLL. Now follow the instructions given in Install/win32_msc71*.txt.