|
Last change
on this file since 10937 was 6081, checked in by Eric.Larour, 15 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
|
|---|
| 4 | NUMCPUS=$1;
|
|---|
| 5 |
|
|---|
| 6 | #version of netcdf
|
|---|
| 7 | version=`echo *.tar.gz | sed 's/\.tar\.gz//g' | sed 's/netcdf-//g'`
|
|---|
| 8 |
|
|---|
| 9 | #Some cleanup
|
|---|
| 10 | rm -rf install netcdf-$version
|
|---|
| 11 |
|
|---|
| 12 | #Create install directories
|
|---|
| 13 | mkdir install
|
|---|
| 14 |
|
|---|
| 15 | #Untar
|
|---|
| 16 | tar -zxvf netcdf-$version.tar.gz
|
|---|
| 17 |
|
|---|
| 18 | #Move netcdf to install directory
|
|---|
| 19 | rm -rf install/*
|
|---|
| 20 | mv netcdf-$version/* install/
|
|---|
| 21 | rm -rf netcdf-$version
|
|---|
| 22 |
|
|---|
| 23 | #Configure netcdf
|
|---|
| 24 | cd install
|
|---|
| 25 | ./configure --prefix="$ISSM_TIER/externalpackages/netcdf/install"
|
|---|
| 26 |
|
|---|
| 27 | #Compile and install netcdf
|
|---|
| 28 | if [ -z $NUMCPUS ];
|
|---|
| 29 | then
|
|---|
| 30 | make
|
|---|
| 31 | make install
|
|---|
| 32 | else
|
|---|
| 33 | make -j $NUMCPUS
|
|---|
| 34 | make -j $NUMCPUS install
|
|---|
| 35 | fi
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.