-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild_test.sh
More file actions
executable file
·59 lines (47 loc) · 1.34 KB
/
build_test.sh
File metadata and controls
executable file
·59 lines (47 loc) · 1.34 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
#!/bin/sh
#
# Build and test cdat_lite
#
# This script assumes the presence of NetCDF3/4 and virtualenv
#
#!NOTE: This script won't work as expected if you have numpy installed
# in your system python
########################################################################
# Customisation section.
#
# Select your NetCDF installation and numpy version here. The script
# will attempt to install numpy and cdat_lite in a clean virtualenv.
#
NETCDF_HOME=/opt/netcdf-4.1.1-classic
#HDF5_HOME=/opt/hdf5
NUMPY_VERSION=1.5
CDAT_LITE_VERSION=6.0.alpha-2
DIST_DIR=$PWD/dist
VIRTUALENV=$PWD/test_venv
PIP_CACHE=$HOME/.pip/cache
TARBALL=${DIST_DIR}/cdat_lite-${CDAT_LITE_VERSION}.tar.gz
########################################################################
export NETCDF_HOME HDF5_HOME NUMPY_VERSION DIST_DIR VIRTUALENV PIP_CACHE TARBALL
(
virtualenv --no-site-packages $VIRTUALENV
cd $VIRTUALENV
./bin/pip install --download-cache=$PIP_CACHE nose
if [ $? != 0 ]
then
echo "nose install failed"
exit 1
fi
./bin/pip install --download-cache=$PIP_CACHE numpy==${NUMPY_VERSION}
if [ $? != 0 ]
then
echo "Numpy install failed"
exit 1
fi
./bin/pip install --no-index --download-cache=$PIP_CACHE ${TARBALL}
if [ $? != 0 ]
then
echo "cdat_lite install failed"
exit 1
fi
./bin/nosetests cdat_lite
)