SDPA 7.3.0 Install Manual [Copyright (C) 2009 SDPA Project] This text explains how to install SDPA. If you have questions on the installation, please contact us from http://sdpa.indsys.chuo-u.ac.jp/sdpa/contact.html --- index ------------------------------------ 1. Install the SDPA 2. compile callable-library example 3. compile SDPA-M (for Matlab) ---------------------------------------------- 1. Install the SDPA (1) Download the SDPA from the SDPA Homepage; http://homepage.mac.com/klabtitech/sdpa-homepage/download.html or http://sdpa.indsys.chuo-u.ac.jp/sdpa/download.html You can get the sdpa.7.3.0.src.(date).tar.gz (2) configure && make (2-1) SDPA linked against ATLAS library Download the ATLAS library from the following web site; http://math-atlas.sourceforge.net/ Donwload the LAPACK library from the following web site; http://www.netlib.org/lapack/ Assume that SDPA and ATLAS/LAPACK library are installed into $HOME/sdpa/sdpa.7.3.0 and $HOME/sdpa/lib respectively. # ATLAS $ tar xvzf atlas3.x.x.tar.gz $ cd ATLAS $ mkdir my_build_dir ; cd my_build_dir $ ./configure $ make $ cd lib $ mv liblapack.a libalapack.a $ cp *.a $HOME/sdpa/lib/ # LAPACK $ tar xvzf lapack.tgz $ cd lapack-3.2 $ cp ./INSTALL/make.inc.gfortran make.inc $ make lapacklib $ cp lapack_LINUX.a $HOME/sdpa/lib/liblapack.a # SDPA $ cd $HOME/sdpa $ tar xzf sdpa.7.3.0.src.(date).tar.gz $ export CC=gcc $ export CXX=g++ $ export F77=gfortran $ export CFLAGS="-funroll-all-loops -O2 -m64" $ export CXXFLAGS="-funroll-all-loops -O2 -m64" $ export FFLAGS="-funroll-all-loops -O2 -m64" $ ./configure --with-blas="-L${HOME}/sdpa/lib -lptf77blas -lptcblas -latlas -lgfortran" --with-lapack="-L${HOME}/sdpa/lib -llapack -lgfortran" $ make If you specify the number of threads with the SDPA, set OMP_NUM_THREADS environment variable(ex. export OMP_NUM_THREADS=4). If you have dual-core or quad-core CPU, we strongly recommend that set $export OMP_NUM_THREADS = 2 or $export OMP_NUM_THREADS = 4 (2-2) SDPA linked against GotoBLAS library Download the GotoBLAS library from the following web site; http://www.tacc.utexas.edu/resources/software/ Donwload the LAPACK library from the following web site; http://www.netlib.org/lapack/ Assume that SDPA and GotoBLAS/LAPACK library are installed into $HOME/sdpa/sdpa.7.3.0 and $HOME/sdpa/lib respectively. # GotoBLAS $ tar xvzf GotoBLAS-1.xx.tar.gz $ cd GotoBLAS $ emacs Makefile.rule Edit the file "Makefile.rule" as follows; # USE_SIMPLE_THREADED_LEVEL3 = 1 --> USE_SIMPLE_THREADED_LEVEL3 = 1 CCOMMON_OPT += -DTHREAD_TIMEOUT=26 --> CCOMMON_OPT += -DTHREAD_TIMEOUT=1 $ ./quickbuild.64bit or ./quickbuild.32bit $ cp libgoto.a $HOME/sdpa/lib/ # LAPACK $ tar xvzf lapack.tgz $ cd lapack-3.2 $ cp ./INSTALL/make.inc.gfortran make.inc $ make lapacklib $ cp lapack_LINUX.a $HOME/sdpa/lib/liblapack.a # SDPA $ cd $HOME/sdpa $ tar xzf sdpa.7.3.0.src.(date).tar.gz $ export CC=gcc $ export CXX=g++ $ export F77=gfortran $ export CFLAGS="-funroll-all-loops -O2 -m64" $ export CXXFLAGS="-funroll-all-loops -O2 -m64" $ export FFLAGS="-funroll-all-loops -O2 -m64" $ ./configure --with-blas="-L${HOME}/sdpa/lib -lgoto" --with-lapack="-L${HOME}/sdpa/lib -llapack -lgoto" $ make If you specify the number of threads with both of the SDPA and GotoBLAS, set OMP_NUM_THREADS environment variable(ex. export OMP_NUM_THREADS=4). If you have dual-core or quad-core CPU, we strongly recommend that set $export OMP_NUM_THREADS = 2 or $export OMP_NUM_THREADS = 4 (2-3) SDPA linked against LAPACK/BLAS library Donwload the LAPACK/BLAS library from the following web site; http://www.netlib.org/lapack/ Assume that SDPA and LAPACK/BLAS library are installed into $HOME/sdpa/sdpa.7.3.0 and $HOME/sdpa/lib respectively. # LAPACK/BLAS $ tar xvzf lapack.tgz $ cd lapack-3.2 $ cp ./INSTALL/make.inc.gfortran make.inc $ make blaslib lapacklib $ cp blas_LINUX.a $HOME/sdpa/lib/libblas.a $ cp lapack_LINUX.a $HOME/sdpa/lib/liblapack.a # SDPA $ cd $HOME/sdpa $ tar xzf sdpa.7.3.0.src.(date).tar.gz $ export CC=gcc $ export CXX=g++ $ export F77=gfortran $ export CFLAGS="-funroll-all-loops -O2 -m64" $ export CXXFLAGS="-funroll-all-loops -O2 -m64" $ export FFLAGS="-funroll-all-loops -O2 -m64" $ ./configure --with-blas="-L${HOME}/sdpa/lib -lblas" --with-lapack="-L${HOME}/sdpa/lib -llapack" $ make If you specify the number of threads with the SDPA, set OMP_NUM_THREADS environment variable(ex. export OMP_NUM_THREADS=4). If you have dual-core or quad-core CPU, we strongly recommend that set $export OMP_NUM_THREADS = 2 or $export OMP_NUM_THREADS = 4 The details of the configure script option for each OS can be found in sdpa user manual. (http://sdpa.indsys.chuo-u.ac.jp/sdpa/files/sdpa.7.1.1.manual.20080618.pdf) ---------------------------------------------- 2. compile callable-library example To compile callable-library example, use 'make' command in 'libexample' directory $ cd $HOME/sdpa/sdpa.7.3.0/libexample $ make The details of callable-library can be found in SDPA user manual in $HOME/sdpa/sdpa.7.3.0/doc/ ---------------------------------------------- 3. compile SDPA-M (optional) To compile SDPA-M, use 'make' command in 'mex' directory $ cd $HOME/sdpa/sdpa.7.3.0/mex $ make The make command automatically searches 'mex' command by invorking 'matlab' command. If the auto-search fails, you setup the full-path for 'mex' command in Makefile in the 'mex' directory and use make command again. Since the usage of this new SDPA-M as SDPA-M 6.2.0, SDPA-M 6.2.0 manual is very useful. (http://sdpa.indsys.chuo-u.ac.jp/sdpa/files/sdpa.6.2.0.manual.pdf) ----------------------------------------------