Project

General

Profile

Install Appion Packages » History » Version 17

Neil Voss, 05/12/2010 10:23 AM

1 1 Amber Herold
h1. Install Appion Packages
2
3
h3. Install the package in _each folder_ with commands like these
4
5
*TODO: move these into a single installer, ask Jim*
6
7
<pre>
8 9 Neil Voss
cd /your_download_area/
9
10
cd myami/leginon
11 4 Neil Voss
sudo python setup.py install
12 1 Amber Herold
13
cd ../pyami
14 4 Neil Voss
sudo python setup.py install
15 8 Neil Voss
16 5 Neil Voss
cd ../pyscope
17 4 Neil Voss
sudo python setup.py install
18 8 Neil Voss
19 1 Amber Herold
cd ../sinedon
20 4 Neil Voss
sudo python setup.py install
21 8 Neil Voss
22
cd ../imageviewer
23
sudo python setup.py install
24
25
cd ../appion
26 10 Neil Voss
sudo python setup.py install --install-scripts=/usr/local/bin
27 8 Neil Voss
28
#binary packages
29
30 4 Neil Voss
cd ../numextension
31 1 Amber Herold
python setup.py build
32 6 Neil Voss
sudo python setup.py install
33 8 Neil Voss
34 4 Neil Voss
cd ../libcv
35 1 Amber Herold
python setup.py build
36
sudo python setup.py install
37 8 Neil Voss
38 7 Neil Voss
cd ../appion/radermacher
39 6 Neil Voss
python setup.py build
40 4 Neil Voss
sudo python setup.py install
41 1 Amber Herold
</pre>
42
43
h3. python-site-package-path: where the installed python packages went:
44
45
Python installer put the packages you installed to its site-packages directory. This enable all users on the same computer to access them. The easiest way to find where your installed package is called by python is to load a module from the package using interactive python command lines like this:
46
47 16 Neil Voss
Start python command line from shell
48 11 Neil Voss
 <pre>python</pre>
49 1 Amber Herold
50 16 Neil Voss
Import a module from the package. Let's try sinedon here. All packages installed through the above setup.py script should go to the same place.
51 11 Neil Voss
 <pre>python> import sinedon</pre>
52 1 Amber Herold
53
54 16 Neil Voss
If the module is loaded successfully, call the module attribute __path__ (two underscrolls before "path" and two underscrolls after) will return the location of the module it is loaded from
55 1 Amber Herold
<pre>
56 13 Neil Voss
python> sinedon.__path__
57 1 Amber Herold
['/usr/lib/python2.4/site-packages/sinedon']
58
</pre>
59 14 Neil Voss
60 16 Neil Voss
In this case, /usr/lib/python2.4/site-packages/ is your python-site-package-path. If you go to that directory, you will find all the packages you just installed.
61
62
Save this value for use later, for bash:
63 15 Neil Voss
<pre>
64 17 Neil Voss
export PYTHONSITEPKG='/usr/lib/python2.4/site-packages'
65 15 Neil Voss
</pre>
66
or C shell
67
<pre>
68 17 Neil Voss
setenv PYTHONSITEPKG '/usr/lib/python2.4/site-packages'
69 14 Neil Voss
</pre>
70 2 Amber Herold
71
______
72
73
[[Perform system check|< Perform system check]] | [[Configure leginon.cfg|Configure leginon.cfg >]]
74 3 Amber Herold
75
______