source: issm/trunk-jpl/externalpackages/boost/install-1.72-mac.sh@ 24663

Last change on this file since 24663 was 24663, checked in by jdquinn, 5 years ago

BUG: Attempting to fix seg fault on launch of MATLAB during testing (not happening locally, only on Pine Island)

  • Property svn:executable set to *
File size: 1.0 KB
Line 
1#!/bin/bash
2#set -eu # Do not `run set -eu` because it causes some targets to fail
3
4
5## Constants
6#
7VER="1_72_0"
8
9## Environment
10#
11export BOOST_ROOT="${ISSM_DIR}/externalpackages/boost"
12
13# Download source
14$ISSM_DIR/scripts/DownloadExternalPackage.sh "https://issm.ess.uci.edu/files/externalpackages/boost_${VER}.tar.gz" "boost_${VER}.tar.gz"
15
16# Unpack source
17tar -zxvf boost_${VER}.tar.gz
18
19# Cleanup
20rm -rf install src
21mkdir install src
22
23# Move source into 'src' directory
24mv boost_${VER}/* src/
25rm -rf boost_${VER}
26
27# Configure
28cd src
29./bootstrap.sh \
30 --prefix=${BOOST_ROOT}/install \
31 --with-python=python2.7
32
33# Modify project config to enable MPI
34printf "\n# Enable MPI\nusing mpi ;\n" >> project-config.jam
35
36# Compile and install
37./b2 toolset=darwin install
38
39# Copy binary to install directory
40mkdir ${BOOST_ROOT}/install/bin
41cp bjam ${BOOST_ROOT}/install/bin
42
43# Set install_name for all shared libraries
44cd ${BOOST_ROOT}/install/lib
45for name in *.dylib; do
46 install_name_tool -id ${BOOST_ROOT}/install/lib/${name} ${name}
47done
Note: See TracBrowser for help on using the repository browser.