source: issm/trunk-jpl/externalpackages/netcdf/install.sh@ 10937

Last change on this file since 10937 was 6081, checked in by Eric.Larour, 14 years ago

New ISSM_TIER points to current tier being used, could be a branch, or the trunk

File size: 616 bytes
Line 
1#!/bin/bash
2
3#Get number of cpus on current platform
4NUMCPUS=$1;
5
6#version of netcdf
7version=`echo *.tar.gz | sed 's/\.tar\.gz//g' | sed 's/netcdf-//g'`
8
9#Some cleanup
10rm -rf install netcdf-$version
11
12#Create install directories
13mkdir install
14
15#Untar
16tar -zxvf netcdf-$version.tar.gz
17
18#Move netcdf to install directory
19rm -rf install/*
20mv netcdf-$version/* install/
21rm -rf netcdf-$version
22
23#Configure netcdf
24cd install
25./configure --prefix="$ISSM_TIER/externalpackages/netcdf/install"
26
27#Compile and install netcdf
28if [ -z $NUMCPUS ];
29then
30 make
31 make install
32else
33 make -j $NUMCPUS
34 make -j $NUMCPUS install
35fi
Note: See TracBrowser for help on using the repository browser.