source: epd_deployment/add-ons.sh @ 587

Last change on this file since 587 was 587, checked in by jemian, 12 years ago

tweaks

  • Property svn:eol-style set to native
  • Property svn:executable set to *
  • Property svn:keywords set to Date Revision Author HeadURL Id
File size: 4.8 KB
Line 
1#!/bin/bash
2
3########### SVN repository information ###################
4# $Date: 2011-08-02 19:23:11 +0000 (Tue, 02 Aug 2011) $
5# $Author: jemian $
6# $Revision: 587 $
7# $URL: epd_deployment/add-ons.sh $
8# $Id: add-ons.sh 587 2011-08-02 19:23:11Z jemian $
9########### SVN repository information ###################
10
11# install additional packages to a python distribution
12
13###################################################################################
14#
15# parse the command line
16#
17
18_cmd_usage() {
19    echo ""
20    echo "usage: $0 "
21    echo "  PYTHON_DIR is the path to the root of a Python distribution"
22    echo ""
23    echo "for example:"
24    echo $0 /APSshare/epd/epd-7.0-2-rh5-x86_64"
25    echo "The Python executable is expected at /APSshare/epd/epd-7.0-2-rh5-x86_64/bin/python"
26    echo ""
27    exit 1
28}
29
30[ $# -ne 1 ] && _cmd_usage
31
32
33###################################################################################
34#
35# establish basic definitions
36#
37
38TOOL=$0
39PYTHON_DIR=$1
40
41START_DIR=`/bin/pwd`
42PYTHON_EXECUTABLE=${PYTHON_DIR}/bin/python
43EASY_INSTALL=${PYTHON_DIR}/bin/easy_install
44if [ ! -f ${PYTHON_EXECUTABLE} ]; then
45  echo "Cannot find Python executable: ${PYTHON_EXECUTABLE}"
46  exit 1
47fi
48if [ ! -f ${EASY_INSTALL} ]; then
49  echo "Cannot find Python easy_install: ${EASY_INSTALL}"
50  exit 1
51fi
52
53###################################################################################
54#
55# install packages via easy_install
56#
57
58# Ubuntu hint for mysql-python: sudo apt-get install libmysqlclient15-dev
59${EASY_INSTALL} -U mysql-python
60${EASY_INSTALL} -U periodictable
61# 2011-06-30,PRJ: manual install of PyEpics until my test #4 case becomes
62#     part of standard distribution through easy_install
63${EASY_INSTALL} -U pyepics
64${EASY_INSTALL} -U pytables
65${EASY_INSTALL} -U suds
66${EASY_INSTALL} -U dblatex
67
68###################################################################################
69#
70# installations using basic procedure:  python ./setup.py install
71
72# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
73#
74# PyEpics (manual install instead of easy_install above)
75#     local copy has "test #4" fix to find ${PYTHON_DIR}/lib/libca.so
76# if [ `uname -s` = "SunOS" ]; then
77#     echo "# PyEpics : skipping ... solaris support is not ready - problem in epics.ca.initialize_libca()"
78# else
79#     if [ -f ${START_DIR}/trees/pyepics ]; then
80#         cd ${START_DIR}/trees/pyepics
81#         ${PYTHON_EXECUTABLE} ./setup.py clean
82#         ${PYTHON_EXECUTABLE} ./setup.py install
83#     fi
84# fi
85
86# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
87#
88# igor.py
89#    reads IgorPro .pxp files
90#    from Paul Kienzle at NIST NCNR Reflectometer
91#    http://pypi.python.org/pypi/igor.py
92if [ -f ${START_DIR}/trees/igor.py-0.8 ]; then
93    cd ${START_DIR}/trees/igor.py-0.8/
94    ${PYTHON_EXECUTABLE} ./setup.py clean
95    ${PYTHON_EXECUTABLE} ./setup.py install
96fi
97
98# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
99#
100# PyFFTW3
101#    "Fastest FFT in the West"
102#    https://launchpad.net/pyfftw/
103if [ `uname -s` = "SunOS" ]; then
104    echo "# PyFFTW3 : skipping ... Cannot install  on solaris"
105else
106    if [ -f ${START_DIR}/trees/PyFFTW3-0.2.1 ]; then
107        cd ${START_DIR}/trees/PyFFTW3-0.2.1/
108        ${PYTHON_EXECUTABLE} ./setup.py clean
109        ${PYTHON_EXECUTABLE} ./setup.py install
110    fi
111fi
112
113# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
114#
115# pyFprime
116#    Robert B. Von Dreele (Argonne National Laboratory)
117#    Cromer-Liberman calculations of f'(E) and f''(E)
118#    https://launchpad.net/pyfftw/
119if [ -f ${START_DIR}/trees/pyFprime ]; then
120    cd ${START_DIR}/trees/pyFprime/
121    ${PYTHON_EXECUTABLE} ./setup.py clean
122    ${PYTHON_EXECUTABLE} ./setup.py install
123fi
124
125
126###################################################################################
127#
128#------------------
129# installations with added details
130#
131# PyQt           http://www.saltycrane.com/blog/2007/01/how-to-install-pyqt-41-python-25-and-qt_8340/
132# nxtree         part of nexpy, planned to become part of NAPI in a future release
133# nexpy          http://trac.mcs.anl.gov/projects/nexpy
134# NeXus          http://nexusformat.org
135# ca_utils       BCDA
136
137# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
138#
139# ca_utils
140#    backwards compatibility with BCDA's EPICS support before PyEpics
141#    Use this for existing or legacy applications
142
143# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
144#
145# nexpy
146#    NeXus file GUI browser
147#    http://trac.mcs.anl.gov/projects/nexpy
148
149# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
150#
151# RRDtool
152#    Round-Robin database
153#    http://oss.oetiker.ch/rrdtool/prog/rrdpython.en.html
154if [ -f ${START_DIR}/trees/rrdtool-1.4.5/ ]; then
155    cd ${START_DIR}/trees/rrdtool-1.4.5/
156fi
157
158# and now this one is a bit more involved
159
160###################################################################################
161#
162# other stuff
163#
Note: See TracBrowser for help on using the repository browser.