source: trunk/environments/g4py/00README

Last change on this file was 1337, checked in by garnier, 14 years ago

tag geant4.9.4 beta 1 + modifs locales

File size: 4.8 KB
Line 
1$Id: 00README,v 1.12 2009/11/20 03:36:51 kmura Exp $
2==========================================================================
3Geant4Py
4
5  Geant4Py is a set of python modules for using Geant4.
6
7==========================================================================
8
9URL
10---
11http://www-geant4.kek.jp/projects/Geant4Py/
12
13
14System Requirements:
15-------------------
16Python
17  - only 2.x is tested.
18
19Geant4
20  - 8.0 or later
21  - should be built in "GLOBAL" and "SHARED" libraries.
22  - All header files should be collected into $(G4INSTALL)/include
23    by "make includes"
24
25CLHEP
26  - 1.9.1.1 or later
27  - should be built in shared library.
28  - Building shared objects is supported since version 1.9.
29
30(Optional)
31ROOT
32
33Before Starting:
34----------------
35In dafault situation, Geant4 creates and uses "granular static libraries".
36But, the Python interface requires "GLOBAL SHARED library".
37If you donot build your Geant4 libraries in global shared mode,
38you have to recreate your instance additionally.
39
40In "tools" directory, you can find some ways to handle both "glanular static"
41and "global shared" environments. Please take a look.
42
43
44How to Install:
45---------------
46There is a configuraton script for building the package.
47
48# ./configure --help
49`configure' configures Geant4Py to adapt to many kinds of systems.
50
51Usage:  ./configure SYSTEM [OPTION]... [VAR=VALUE]...
52
53SYSTEM: System type (see Supported Arhitectures)
54
55Options:
56  -h, --help                Display this help and exit
57
58Installation directories:
59  --prefix=PREFIX           Installation prefix  [./]
60  --libdir=DIR              Python modules dir [PREFIX/lib]
61
62Fine tuning of the library path:
63  --with-g4-incdir=DIR      Geant4 header dir [$G4INCLUDE]
64  --with-g4-libdir=DIR      Geant4 library dir [$G4LIB/$G4SYSTEM]
65  --with-clhep-incdir=DIR   CLHEP header dir [$CLHEP_INCLUDE_DIR]
66  --with-clhep-libdir=DIR   CLHEP library dir [$CLHEP_LIB_DIR]
67  --with-clhep-lib=LIB      library name of libCLHEP.so [CLHEP|$CLHEP_LIB]
68
69  --with-python-incdir=DIR  Python header dir [/usr/include/python(2.#)],
70                            (location of pyconfig.h)
71  --with-python-libdir=DIR  Python library dir [/usr/lib(64)]
72
73  --with-boost-incdir=DIR   BOOST-C++ header dir [/usr/include],
74                            (location of boost/)
75  --with-boost-libdir=DIR   BOOST-C++ library dir [/usr/lib]
76  --with-boost-python-lib=LIB library name of libboost_python.so [boost_python]
77
78  --with-package-dir=DIR    Geant4 Package dir
79
80  --with-extra-dir=DIR      Install path for extra packages [/usr/local]
81
82  --with-xercesc-incdir=DIR Xerces-C header dir [/usr/include]
83  --with-xercesc-libdir=DIR Xerces-C library dir [/usr/lib(64)]
84
85Enable/disable options: prefix with either --enable- or --disable-
86  openglx      OpenGLX support    [auto]
87  openglxm     OpenGLXm support   [disable, $G4VIS_USE_OPENGLXM]
88  raytracerx   RayTracerX support [disable, $G4VIS_USE_RAYTRACERX]
89
90Supported Architectures:
91  linux           for Linux gcc 3.x and 4.x (32bit)
92  linux64         for Linux gcc 3.x and 4.x (64bit, alias to linuxx8664gcc)
93  linuxx8664gcc   for AMD Opteron and Intel EM64T Linux gcc 3.x and 4.x
94  macosx          for MacOSX with gcc (Tiger/Leopard and Xcode)
95
96You can specify all parameters adopting your environment.
97
98For example,
99# ./configure linux64  (miserable)
100  --with-g4-incdir=/opt/heplib/Geant4/geant4.8.1/include
101  --with-g4-libdir=/opt/heplib/Geant4/geant4.8.1/slib/Linux-g++
102  --with-clhep-incdir=/opt/heplib/CLHEP/2.0.2.2/include
103  --with-clhep-libdir=/opt/heplib/CLHEP/2.0.2.2/lib
104  --with-clhep-lib=CLHEP-2.0.2.2
105
106# ./configure linux64  (smart)
107  --with-package-dir=/opt/heplib/Geant4/packages/9.1.2
108
109# ./confugre linux64 (intelligent or haphazard ?)
110
111The configuration script will create config/config.gmk, which describes
112your envrionment.
113
114After executing the configure script, then
115
116# make
117# make install
118
119That's all!
120
121How to Use:
122-----------
123Some environment variables are required at run time.
124
125* PYTHONPATH
126Python module search directories, given by a colon-separated list
127of directories.
128Practically, $(INSTALL_PATH)/lib is ok.
129
130* LD_LIBRARY_PATH
131Additional shared library path to be searched.
132
133Some libraries paths are already specified via "-rpath" linker option,
134so these paths do not have to be added to "LD_LIBRARY_PATH".
135 * Geant4
136 * CLHEP
137 * boost-python library
138 * $(INSTALL_PATH)/lib
139 * $(G4PY_EXLIB_LIBDIR) specified in a module makefile.
140
141
142You can import Geant4Py modules in Python just like
143
144>>> import Geant4
145
146Notes:
147-----
1481) >> IMPORTANT <<
149All users' libraries should be build in SHARED libaries.
150
1512) Development Environment:
152OS:             SuSE Linux 11.1 (x86-64)
153g++ :           4.3.2
154Python:         2.6
155CLHEP:          2.0.4.4
156ROOT:           5.20/00
157
1583) Tested environment:
159  Linux 32/64-bit
160  SuSE 11.2 11.1
161  SL4.5 SL5.4
162  Ubuntu 8.0.4
163  MacOSX 10.5 (Leopard) 10.6 (Snow Leopard)
164
165Have A Fun!!
166
167Koichi Murakami <Koichi.Murakami@kek.jp>
Note: See TracBrowser for help on using the repository browser.