Difference between revisions of "Building on Ubuntu"
(→PETSc) |
|||
Line 13: | Line 13: | ||
sudo apt-get install libmetis-dev libparmetis-dev | sudo apt-get install libmetis-dev libparmetis-dev | ||
+ | The free GNU linear programming kit can be installed and used by GridPACK for optimization, if desired | ||
+ | |||
+ | sudo apt-get install glpk-utils libglpk-dev | ||
== PETSc == | == PETSc == | ||
Line 49: | Line 52: | ||
GridPACK was configured and built as follows: | GridPACK was configured and built as follows: | ||
− | + | prefix="/usr/local/gridpack" | |
− | + | cmake -Wno-dev --debug-try-compile \ | |
− | + | -D PETSC_DIR:STRING="/usr/lib/petscdir/3.6.2" \ | |
− | + | -D PETSC_ARCH:STRING="x86_64-linux-gnu-real" \ | |
− | + | -D GA_DIR:STRING="$prefix" \ | |
− | + | -D MPI_CXX_COMPILER:STRING="mpicxx" \ | |
− | + | -D MPI_C_COMPILER:STRING="mpicc" \ | |
− | + | -D MPIEXEC:STRING="mpiexec" \ | |
− | + | -D MPIEXEC_MAX_NUMPROCS:STRING="2" \ | |
− | + | -D GRIDPACK_TEST_TIMEOUT:STRING=20 \ | |
− | + | -D USE_GLPK:BOOL=OFF \ | |
− | + | -D CMAKE_INSTALL_PREFIX:PATH="$prefix" \ | |
− | + | .. | |
− | + | make | |
+ | make test |
Revision as of 21:21, 30 September 2016
This build was performed on a Virtual Box instance running a clean install of Ubuntu Linux 16.04 (LTS). Most of the prerequisite software was installed using Ubuntu packages. Any packages that needed to be built from source were installed in /usr/local/gridpack
Boost was installed like this
sudo apt-get install libboost-all-dev
This installed a C++ compiler and OpenMPI compiler wrappers, as well as all of Boost. Other available packages were installed using
sudo apt-get install openmpi-bin make cmake git gfortran liblapack-dev doxygen
The doxygen
package can be skipped, since it installs a large number of dependencies. A compatible ParMETIS package is available, so install that
sudo apt-get install libmetis-dev libparmetis-dev
The free GNU linear programming kit can be installed and used by GridPACK for optimization, if desired
sudo apt-get install glpk-utils libglpk-dev
PETSc
Ubuntu packages for PETSc 3.6 were available. These can be installed with
sudo apt-get petsc3.6-dev petsc-complex-3.6-dev
These are built with several optional packages, including Hypre, SuiteSparse, and MUMPS. SuperLU is also include, not SuperLU_DIST, which will limit direct linear solver methods in parallel. Alternatively, PETSc can be built from source.
Global Arrays
Global Arrays from SVN was configured, built, and installed as follows:
svn co https://svn.pnl.gov/svn/hpctools/trunk/ga ga-trunk cd ga-trunk prefix="/usr/local/gridpack" ./configure \ --enable-cxx \ --enable-i4 \ --disable-f77 \ --with-mpi \ --prefix="$prefix" \ --with-blas=no \ --with-lapack=no \ --enable-shared=no \ --enable-static=yes \ MPICC=mpicc MPICXX=mpicxx MPIF77=mpif90 \ MPIEXEC=mpiexec MPIRUN=mpirun make sudo make install
Building and Testing GridPACK
GridPACK was configured and built as follows:
prefix="/usr/local/gridpack" cmake -Wno-dev --debug-try-compile \
-D PETSC_DIR:STRING="/usr/lib/petscdir/3.6.2" \ -D PETSC_ARCH:STRING="x86_64-linux-gnu-real" \ -D GA_DIR:STRING="$prefix" \ -D MPI_CXX_COMPILER:STRING="mpicxx" \ -D MPI_C_COMPILER:STRING="mpicc" \ -D MPIEXEC:STRING="mpiexec" \
-D MPIEXEC_MAX_NUMPROCS:STRING="2" \ -D GRIDPACK_TEST_TIMEOUT:STRING=20 \ -D USE_GLPK:BOOL=OFF \ -D CMAKE_INSTALL_PREFIX:PATH="$prefix" \
..
make make test