source: trunk/bin/install.sh@ 245

Last change on this file since 245 was 217, checked in by mar637, 20 years ago

A script to install the asap module into a specified path.

  • Property svn:eol-style set to native
  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
File size: 1.2 KB
RevLine 
[217]1#!/bin/sh
2
3########################################
4# #
5# Install the asap python module #
6# #
7########################################
8
9ASAPDIR='/usr/local/lib/python2.3/site-packages/asap'
10SRCDIR='/u/mar637/brage/singledish/asap'
11
12# where the source python files are
13pydir='python'
14# where the library modules is
15libdir='lib'
16# the python files to install
17srcfiles="__init__.py asaprc.py asapmath.py scantable.py asapreader.py asaplot.py asapfitter.py asapplotter.py"
18# the libraries to install
19libfiles='_asap.so'
20
21#if [ -d ${SHAREDIR} ] ; then
22# echo "ASAP share dir already exists."
23#else
24# mkdir ${SHAREDIR}
25#fi
26
27# go to src dir
28if [ -d ${SRCDIR} ] ; then
29 cd ${SRCDIR}
30else
31 echo "No source directory found."
32 exit 0
33fi
34
35# check if the site-packes directory exists and create if necessary
36if [ -d ${ASAPDIR} ] ; then
37 echo "Using existing asap module dir."
38else
39 mkdir ${ASAPDIR}
40fi
41
42# install asap files
43for f in ${srcfiles}
44do
45 cp -f ${SRCDIR}/${pydir}/${f} ${ASAPDIR}/
46done
47
48for f in ${libfiles}
49do
50 cp -f ${SRCDIR}/${libdir}/${f} ${ASAPDIR}/
51done
52echo "Successfully installed the asap module into ${ASAPDIR}"
53
54
Note: See TracBrowser for help on using the repository browser.