Skip to content

Commit

Permalink
CHG: Updated install scripts and configuration for Pleiades
Browse files Browse the repository at this point in the history
  • Loading branch information
TidbitSoftware committed Jan 10, 2025
1 parent 194feac commit 898ea8f
Show file tree
Hide file tree
Showing 20 changed files with 662 additions and 526 deletions.
640 changes: 335 additions & 305 deletions etc/environment.sh

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions externalpackages/dakota/install-6.2-pleiades.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@ PREFIX="${ISSM_DIR}/externalpackages/dakota/install" # Set to location where ext

## Environment
#
export BLAS_LIBS="-L/nasa/intel/Compiler/2018.3.222/compilers_and_libraries_2018.3.222/linux/mkl/lib/intel64/ -lmkl_intel_lp64 -lmkl_sequential -lmkl_core" # Need to export BLAS_LIBS *and* pass it as an option to CMake to ensure that external packages also find it; should upate to /nasa/intel/Compiler/2021.4.0/mkl/2021.4.0/lib/intel64
export CXXFLAGS='-std=c++11'
export BLAS_LIBS="-L${COMP_INTEL_ROOT}/mkl/lib/intel64 -lmkl_intel_lp64 -lmkl_sequential -lmkl_core" # Need to export BLAS_LIBS *and* pass it as an option to CMake to ensure that external packages also find it
export CXXFLAGS='-std=c++98'
export DAK_BUILD=${ISSM_DIR}/externalpackages/dakota/build # DO NOT CHANGE THIS
export DAK_INSTALL=${PREFIX} # DO NOT CHANGE THIS
export DAK_SRC=${ISSM_DIR}/externalpackages/dakota/src # DO NOT CHANGE THIS
export LAPACK_LIBS="-L/nasa/intel/Compiler/2018.3.222/compilers_and_libraries_2018.3.222/linux/mkl/lib/intel64/lib/intel64/ -lmkl_intel_lp64 -lmkl_sequential -lmkl_core" # Need to export LAPACK_LIBS *and* pass it as an option to CMake to ensure that external packages also find it; should upate to /nasa/intel/Compiler/2021.4.0/mkl/2021.4.0/lib/intel64
export LAPACK_LIBS="-L${COMP_INTEL_ROOT}/mkl/lib/intel64/lib/intel64 -lmkl_intel_lp64 -lmkl_sequential -lmkl_core" # Need to export LAPACK_LIBS *and* pass it as an option to CMake to ensure that external packages also find it

# Cleanup
rm -rf ${DAK_BUILD} ${DAK_INSTALL} ${DAK_SRC}
Expand Down Expand Up @@ -58,7 +58,7 @@ cmake \
-DCMAKE_C_COMPILER=mpicc \
-DCMAKE_C_FLAGS="-Wno-error=implicit-function-declaration" \
-DCMAKE_CXX_COMPILER=mpicxx \
-DCMAKE_Fortran_COMPILER=/usr/bin/gfortran \
-DCMAKE_Fortran_COMPILER=gfortran \
-DBoost_NO_BOOST_CMAKE=TRUE \
-DHAVE_ACRO=OFF \
-DHAVE_JEGA=OFF \
Expand Down
84 changes: 0 additions & 84 deletions externalpackages/dakota/install-6.2-pleiades_toss4.sh

This file was deleted.

2 changes: 1 addition & 1 deletion externalpackages/gdal/install-3-ghub-workspace_10.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ set -eu

## Constants
#
VER="3.5.3"
VER="3.10.0"

## Environment
#
Expand Down
2 changes: 1 addition & 1 deletion externalpackages/gdal/install-3-linux-python.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ set -e

## Constants
#
VER="3.8.4"
VER="3.10.0"

PREFIX="${ISSM_DIR}/externalpackages/gdal/install"

Expand Down
2 changes: 1 addition & 1 deletion externalpackages/gdal/install-3-linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ set -e

## Constants
#
VER="3.8.4"
VER="3.10.0"

PREFIX="${ISSM_DIR}/externalpackages/gdal/install"

Expand Down
2 changes: 1 addition & 1 deletion externalpackages/gdal/install-3-mac-python.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ set -e

## Constants
#
VER="3.8.4"
VER="3.10.0"

PREFIX="${ISSM_DIR}/externalpackages/gdal/install"

Expand Down
2 changes: 1 addition & 1 deletion externalpackages/gdal/install-3-mac.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ set -e

## Constants
#
VER="3.8.4"
VER="3.10.0"

PREFIX="${ISSM_DIR}/externalpackages/gdal/install"

Expand Down
2 changes: 1 addition & 1 deletion externalpackages/gdal/install-3-python-static.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ set -e

## Constants
#
VER="3.8.4"
VER="3.10.0"

PREFIX="${ISSM_DIR}/externalpackages/gdal/install"

Expand Down
2 changes: 1 addition & 1 deletion externalpackages/gdal/install-3-static.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ set -e

## Constants
#
VER="3.8.4"
VER="3.10.0"

PREFIX="${ISSM_DIR}/externalpackages/gdal/install"

Expand Down
84 changes: 84 additions & 0 deletions externalpackages/gmsh/install-4-pleiades.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
#!/bin/bash
set -e


# TODO:
# - Add support for,
# - MUMPS
# - PETSc
#
# See Also:
# - configs/4/static/CMakeLists.txt
# - http://gmsh.info/doc/texinfo/gmsh.html#Compiling-the-source-code
#

## Constants
#
VER="4.12.2"

PREFIX="${ISSM_DIR}/externalpackages/gmsh/install" # Set to location where external package should be installed

BLASLAPACK_LIBFLAGS="-L${COMP_INTEL_ROOT}/mkl/lib/intel64 -lmkl_intel_lp64 -lmkl_sequential -lmkl_core"
LIBGFORTRAN_LIBFLAGS="-L${COMP_INTEL_ROOT}/compiler/lib/intel64_lin -lifcore -lifport -lgfortran"

# Environment
#
export CXXFLAGS="${CXXFLAGS} -w"

# Cleanup
rm -rf ${PREFIX} src
mkdir -p ${PREFIX} src

# Download source
$ISSM_DIR/scripts/DownloadExternalPackage.sh "https://gmsh.info/src/gmsh-${VER}-source.tgz" "gmsh-${VER}-source.tgz"

# Unpack source
tar -xvzf gmsh-${VER}-source.tgz

# Move source to 'src' directory
mv gmsh-${VER}-source/* src
rm -rf gmsh-${VER}-source

# Configure
#
# NOTE:
# - Option -DENABLE_FLTK=0 is used because we do not need GUI.
# - Option -DENABLE_MPEG_ENCODE=0 is used because we do not need to record MPEG
# movies.
# - Option -DENABLE_OCC=0 is used because we do not need CAD kernel and are not
# importing STEP/IGES files.
# - Option -DENABLE_TOUCHBAR=0 is used because we do not have GUI, therefore we
# do not need to support Apple Touch bar (does not affect compilation on
# Linux).
#
cd src
cmake \
-DCMAKE_INSTALL_PREFIX="${PREFIX}" \
-DCMAKE_INSTALL_RPATH="${PREFIX}/lib" \
-DCMAKE_BUILD_TYPE=Release \
-DENABLE_BUILD_DYNAMIC=1 \
-DENABLE_BUILD_SHARED=1 \
-DBLAS_LAPACK_LIBRARIES="${BLASLAPACK_LIBFLAGS} ${LIBGFORTRAN_LIBFLAGS}" \
-DENABLE_BLAS_LAPACK=1 \
-DENABLE_EIGEN=0 \
-DENABLE_FLTK=0 \
-DENABLE_MPEG_ENCODE=0 \
-DENABLE_MPI=1 \
-DENABLE_OCC=0 \
-DENABLE_TOUCHBAR=0 \
-DMETIS_ROOT="${PETSC_DIR}/lib"

# Compile and install
if [ $# -eq 0 ]; then
make
make install
else
make -j $1
make -j $1 install
fi

# Make necessary link on RHEL
if [[ -d ${PREFIX}/lib64 && ! -d ${PREFIX}/lib ]]; then
cd ${PREFIX}
ln -s ./lib64 ./lib
fi
72 changes: 72 additions & 0 deletions externalpackages/gmt/install-6-pleiades.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
#!/bin/bash
set -e


## Constants
#
VER="6.5.0"

PREFIX="${ISSM_DIR}/externalpackages/gmt/install"

BLASLAPACK_LIBFLAGS="-L${COMP_INTEL_ROOT}/mkl/lib/intel64;-lmkl_intel_lp64;-lmkl_sequential;-lmkl_core"
LIBGFORTRAN_LIBFLAGS="-L${COMP_INTEL_ROOT}/compiler/lib/intel64_lin;-lifcore;-lifport;-lgfortran"

# Environment
#
export CC=mpicc
export CFLAGS="${CFLAGS} -w"

# Download source
$ISSM_DIR/scripts/DownloadExternalPackage.sh "https://github.com/GenericMappingTools/gmt/archive/refs/tags/${VER}.tar.gz" "gmt-${VER}.tar.gz"

# Unpack source
tar -zxvf gmt-${VER}.tar.gz

# Cleanup
rm -rf ${PREFIX} src
mkdir -p ${PREFIX} src

# Move source to 'src' directory
mv gmt-${VER}/* src
rm -rf gmt-${VER}

# Copy custom configuration files to source
cp ./src/cmake/ConfigUserAdvancedTemplate.cmake ./src/cmake/ConfigUser.cmake

# Patch source
patch ./src/cmake/ConfigUser.cmake < ./configs/${VER%.*}/cmake/ConfigUserAdvancedTemplate.cmake.patch

# Configure
cd src
mkdir build
cd build

# NOTE:
# - There is a CMake variable named CURL_ROOT in src/cmake/ConfigUser.cmake
# that, ostensibly, allows for supplying the path to curl when it is in a
# non-standard location. That said, newer versions of CMake will ignore said
# variable and instead try to find curl itself. Passing in the two options
# below overrides this behavior.
#
cmake \
-DCMAKE_INSTALL_PREFIX="${PREFIX}" \
-DBLAS_LIBRARIES="${BLASLAPACK_LIBFLAGS};${LIBGFORTRAN_LIBFLAGS}" \
-DCURL_INCLUDE_DIR="${CURL_ROOT}/include" \
-DCURL_LIBRARY="-L${CURL_ROOT}/lib;-lcurl" \
-DLAPACK_LIBRARIES="${BLASLAPACK_LIBFLAGS};${LIBGFORTRAN_LIBFLAGS}" \
..

# Compile and install
if [ $# -eq 0 ]; then
make
make install
else
make -j $1
make -j $1 install
fi

# Make necessary link on RHEL
if [[ -d ${PREFIX}/lib64 && ! -d ${PREFIX}/lib ]]; then
cd ${PREFIX}
ln -s ./lib64 ./lib
fi
8 changes: 0 additions & 8 deletions externalpackages/packagemaker/install.sh

This file was deleted.

2 changes: 1 addition & 1 deletion externalpackages/proj/install-6-static.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -eu

# Constants
#
VER="6.2.1"
VER="6.3.2"

PREFIX="${ISSM_DIR}/externalpackages/proj/install" # Set to location where external package should be installed

Expand Down
2 changes: 1 addition & 1 deletion externalpackages/proj/install-6.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -eu

# Constants
#
VER="6.2.1"
VER="6.3.2"

PREFIX="${ISSM_DIR}/externalpackages/proj/install" # Set to location where external package should be installed

Expand Down
15 changes: 12 additions & 3 deletions externalpackages/semic/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,25 @@ set -eu

## Constants
#
VER="1.2"

PREFIX="${ISSM_DIR}/externalpackages/semic/install" # Set to location where external package should be installed

# Cleanup
rm -rf ${PREFIX} src
mkdir -p ${PREFIX}/lib
mkdir -p ${PREFIX} ${PREFIX}/lib src

# Download source
git clone https://github.com/mkrapp/semic.git src
$ISSM_DIR/scripts/DownloadExternalPackage.sh "https://github.com/mkrapp/semic/archive/refs/tags/v${VER}.tar.gz" "semic-${VER}.tar.gz"

# Unpack source
tar -xvzf semic-${VER}.tar.gz

# Move source to 'src' directory
mv semic-${VER}/* src
rm -rf semic-${VER}

# Compile and install semic module utils.f90
if which ifort >/dev/null; then
FC="ifort"
FFLAGS="-traceback -check all" # -O2 is default
Expand All @@ -25,7 +35,6 @@ else
fi
fi

# Compile and install semic module utils.f90
cd src/
(
cat << EOF
Expand Down
Loading

0 comments on commit 898ea8f

Please sign in to comment.