source: epd_deployment/add-ons.sh @ 614

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

documentation

  • 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-12 21:49:14 +0000 (Fri, 12 Aug 2011) $
5# $Author: jemian $
6# $Revision: 614 $
7# $URL: epd_deployment/add-ons.sh $
8# $Id: add-ons.sh 614 2011-08-12 21:49:14Z 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.1-2-rh5-x86_64"
25    echo "The Python executable is expected at /APSshare/epd/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${EASY_INSTALL} -U pyparsing
68
69###################################################################################
70#
71# installations using basic procedure:  python ./setup.py install
72
73# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
74#
75# PyEpics (manual install instead of easy_install above)
76#     local copy has "test #4" fix to find ${PYTHON_DIR}/lib/libca.so
77# if [ `uname -s` = "SunOS" ]; then
78#     echo "# PyEpics : skipping ... solaris support is not ready - problem in epics.ca.initialize_libca()"
79# else
80#     if [ -f ${START_DIR}/trees/pyepics ]; then
81#         cd ${START_DIR}/trees/pyepics
82#         ${PYTHON_EXECUTABLE} ./setup.py clean
83#         ${PYTHON_EXECUTABLE} ./setup.py install
84#     fi
85# fi
86
87# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
88#
89# igor.py
90#    reads IgorPro .pxp files
91#    from Paul Kienzle at NIST NCNR Reflectometer
92#    http://pypi.python.org/pypi/igor.py
93if [ -f ${START_DIR}/trees/igor.py-0.8 ]; then
94    cd ${START_DIR}/trees/igor.py-0.8/
95    ${PYTHON_EXECUTABLE} ./setup.py clean
96    ${PYTHON_EXECUTABLE} ./setup.py install
97fi
98
99# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
100#
101# PyFFTW3
102#    "Fastest FFT in the West"
103#    https://launchpad.net/pyfftw/
104if [ `uname -s` = "SunOS" ]; then
105    echo "# PyFFTW3 : skipping ... Cannot install  on solaris"
106else
107    if [ -f ${START_DIR}/trees/PyFFTW3-0.2.1 ]; then
108        cd ${START_DIR}/trees/PyFFTW3-0.2.1/
109        ${PYTHON_EXECUTABLE} ./setup.py clean
110        ${PYTHON_EXECUTABLE} ./setup.py install
111    fi
112fi
113
114# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
115#
116# pyFprime
117#    Robert B. Von Dreele (Argonne National Laboratory)
118#    Cromer-Liberman calculations of f'(E) and f''(E)
119#    https://launchpad.net/pyfftw/
120if [ -f ${START_DIR}/trees/pyFprime ]; then
121    cd ${START_DIR}/trees/pyFprime/
122    ${PYTHON_EXECUTABLE} ./setup.py clean
123    ${PYTHON_EXECUTABLE} ./setup.py install
124fi
125
126
127###################################################################################
128#
129#------------------
130# installations with added details
131#
132# PyQt           http://www.saltycrane.com/blog/2007/01/how-to-install-pyqt-41-python-25-and-qt_8340/
133# nxtree         part of nexpy, planned to become part of NAPI in a future release
134# nexpy          http://trac.mcs.anl.gov/projects/nexpy
135# NeXus          http://nexusformat.org
136# ca_utils       BCDA
137
138# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
139#
140# ca_utils
141#    backwards compatibility with BCDA's EPICS support before PyEpics
142#    Use this for existing or legacy applications
143
144# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
145#
146# nexpy
147#    NeXus file GUI browser
148#    http://trac.mcs.anl.gov/projects/nexpy
149
150# + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
151#
152# RRDtool
153#    Round-Robin database
154#    http://oss.oetiker.ch/rrdtool/prog/rrdpython.en.html
155if [ -f ${START_DIR}/trees/rrdtool-1.4.5/ ]; then
156    cd ${START_DIR}/trees/rrdtool-1.4.5/
157fi
158
159# and now this one is a bit more involved
160
161###################################################################################
162#
163# other stuff
164#
Note: See TracBrowser for help on using the repository browser.