source: trunk/install_osx.sh@ 2659

Last change on this file since 2659 was 2656, checked in by Malte Marquarding, 12 years ago

create temporary 'sudo' MPLCFGDIR

  • Property svn:executable set to *
File size: 986 bytes
Line 
1#!/bin/sh
2
3FTPURL="ftp://ftp.atnf.csiro.au/pub/software/asap"
4
5if [ `id -u` -ne 0 ]; then
6 echo "install_asap.sh: Must be executed by root (sudo)"
7 exit 1
8fi
9ASAPVERS=4.1
10OSXVERS=$(sw_vers | grep -o '10\.[7-8]')
11echo $OSXVERS
12if [ -z ${OSXVERS} ]; then echo "Only OS X >= 10.7 supported"; exit 1; fi
13ASAPEGG="${FTPURL}/${ASAPVERS}/asap-4.1.0-py2.7-macosx-${OSXVERS}-intel.egg"
14MPLEGG="${FTPURL}/matplotlib/matplotlib-1.1.1-py2.7-macosx-${OSXVERS}-intel.egg"
15MPL=$(/usr/bin/python -c 'import matplotlib' >/dev/null 2>&1)
16# install matplotlib if not already there
17if [ -n $? ]
18then
19 echo "Matplotlib not installed. Installing from CASS ftp server..."
20 /usr/bin/easy_install-2.7 -U ${MPLEGG}
21fi
22
23# This should pull in IPython if required
24/usr/bin/easy_install-2.7 -U ${ASAPEGG}
25
26# make sure readline is installed
27/usr/bin/easy_install-2.7 readline
28
29# update measures data
30MPLTMP=/tmp/mpltmp
31mkdir ${MPLTMP}
32MPLCONFIGDIR="${MPLTMP}" /usr/local/bin/asap_update_data
33rm -rf ${MPLTMP}
Note: See TracBrowser for help on using the repository browser.