==================================================== CHAPLIN - Complex Harmonic Polylogarithms in Fortran ==================================================== Installation with root privileges (global installation: ======================================================= 1) Once you have downloaded the chaplin.tgz file, unpack it with tar xf chaplin.tgz 2) In the chaplin directory, type ./configure and then sudo make install (can take a couple of minutes) 3) To teach the linker that you've installed a new library, finally type sudo ldconfig 4) You're done! Local Installation : ==================== 1) Once you have downloaded the chaplin.tgz file, unpack it with tar xf chaplin.tgz 2) In the chaplin directory, type ./configure --prefix=/"where you want the CHAPLIN library to go" (e.g. ./configure --prefix=/home/peter/) and then make install (Can take a couple of minutes) 3) You're done! The CHAPLIN library will have been produced in the directory /"where you want the CHAPLIN library to go"/lib . Linking CHAPLIN with your code: =============================== In your FORTRAN code, simply declare and use the functions double complex HPL1(n1,x) double complex HPL2(n1,n2,x) double complex HPL3(n1,n2,n3,x) double complex HPL4(n1,n2,n3,n4,x) with integer n1,n2,n3,n4 double complex x and generate the object file with e.g. gfortran -c myfile.f -o myfile.o For the linking of the object files to generate the executable, there are two ways: ------------------------------------------------------------------------- 1) Dynamic linking: If CHAPLIN is globally installed: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ just include -lchaplin in your linking command, e.g. gcc -lchaplin myfile.o -o myprogram If CHAPLIN is locally installed: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ First, you'll need to tell the linker (once) where to find the shared library by typing export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/"path to chaplin lib"/ (LINUX) export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:/"path to chaplin lib"/ (MAC) By writing the above line into your .bashrc (LINUX) or .bash_profile (MAC) file, you won't have to type it in whenever you open a new shell. The linking then needs the command -L/"path to chaplin lib"/ -lchaplin e.g. (also including the once necessary linker path command) LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/peter/lib/ gcc myfile.o -L/home/peter/lib/ -lchaplin -o myprogram ------------------------------------------------------------------------- 2) Static Linking: (Warning! Generates large executables! Not recommended) Include in your linking the commands -static -L/"path to chaplin lib"/ -lchaplin e.g. (following the above expample) gcc myfile.o -static -L/home/peter/lib/ -lchaplin -o myprogram (If CHAPLIN is globally installed, you can omit the -L/"path to chaplin lib"/ part)