]> SALOME platform Git repositories - modules/kernel.git/blob - doc/docutils/archives/INSTALL.txt
Salome HOME
CMake:
[modules/kernel.git] / doc / docutils / archives / INSTALL.txt
1 =================================================================
2 Installation instructions, up to date for 3.0 version
3 =================================================================
4
5 *html version of this document is produced with docutils*::
6
7   rst2html < doc.txt > doc.html
8
9 *This document corresponds to SALOME2 2.2.9.*
10 *IT IS NOT UP TO DATE with 3.2.0*
11
12 .. contents::
13 .. sectnum::
14
15 +-------------------------------------------+
16 | **WORK in PROGRESS, INCOMPLETE DOCUMENT** |
17 +-------------------------------------------+
18
19 -------------------------------------------------------------------------------
20
21 You'll find here generic instructions for installing the SALOME2 platform.
22
23 Summary
24 -------
25
26 `1. Quick Overview`_
27
28 `2. System configuration`_
29
30 `3. Third-party dependencies`_
31
32 `4. Preparing the shell environment`_
33
34 `5. Installing the KERNEL component`_
35
36 `6. Installing the SALOME components`_
37
38 `7. Runtime`_
39
40 `8. Suggestions and advices`_
41
42
43 1. Quick Overview
44 -----------------
45
46 First of all, you have to check (or install if needed) the dependant
47 software programs on your system. These programs are:
48
49 - common development tools as gcc, CMake tool.
50 - third party softwares used in SALOME building or runtime process
51   (python, OCC, VTK, ...)
52
53 Further details can be found in sections [2] and [3].
54
55 If the dependencies are installed on your system, then you have to set
56 your shell environment to get access to the software components
57 (cf. [4]. "Preparing the shell environment").
58
59 The next step is to install the KERNEL (cf. [5] "Installing KERNEL"):
60
61 ::
62
63 $ mkdir <kernel_build>
64 $ mkdir <kernel_install>
65 $ cd <kernel_build>
66 $ cmake -DCMAKE_BUILD_TYPE=<Mode> -DCMAKE_INSTALL_PREFIX=<kernel_install> ../<kernel_src>
67 $ make
68 $ make install
69
70 Where <Mode> is build mode(Release or Debug), <kernel_install> 
71 is a destination folder to install KERNEL module of SALOME.
72
73 Then, the SALOME components GEOM, MED, VISU, ... can be installed
74 with a similar procedure (cf. [6]).
75
76 Eventually, the platform can be run by executing the shell script
77 runSalome (cf. [7]). Here, somme additionnal variables have to be set
78 to describe the SALOME runtime configuration (<COMPONENT>_ROOT_DIR,
79 OMNIORB_CONFIG)
80
81 The following provides you with specific instructions for each step.
82
83
84 2. System configuration
85 -----------------------
86
87 SALOME is compiled and tested on differents platforms with native packages:
88 - Debian sarge
89 - Mandrake 10.1
90 - ...
91
92 If you have another platform, we suggest the following configuration
93 for building process:
94
95 - gcc-3.3.x or 3.4.x
96 - CMake-2.8.8 or more
97
98 remarks:
99
100 - This is the minimum level of CMake, if you need
101   to compile all the third party softwares (included OpenCascade 5.2.x).
102
103 3. Third-party dependencies
104 ---------------------------
105
106 The SALOME platform relies on a set of third-party softwares. The
107 current version depends on the following list
108 (versions given here are from Debian Sarge, except OpenCascade, VTK and MED,
109 which are not Debian packages):
110
111 CAS-5.2.4               OpenCascade (try binaries,a source patch is needed)
112 VTK-4.2.6               VTK 3D-viewer
113 PyQt-3.13               Python-Qt Wrapper
114 Python-2.3.5            Python interpreter
115 SWIG-1.3.24             SWIG library
116 boost-1_32_0            C++ library (only include templates are used)
117 hdf5-1.6.2              Files Database library
118 med-2.2.2               MED Data Format support for file records 
119 omniORB-4.0.5           ORB used in SALOME
120 qt-x11-free-3.3.3       Qt library
121 qwt-4.2                 Graph components for Qt
122 sip4-4.1.1              langage binding software 
123
124 And, in order to build the documentation:
125
126 doxygen-1.4.2
127 graphviz-2.2.1
128
129
130 Additionnal software may be installed for optional features: 
131
132 netgen4.3 + patch
133 tix8.1.4
134 openpbs-2.3.16
135 lsf-???
136
137
138
139 3.1 To Do
140 ~~~~~~~~~
141 - Instructions for installing these software programs can be found in a
142   special note doc/configuration_examples/install-prerequis.
143 - Installation shell scripts are also provided.
144   These scripts have to be adapted to your own configuration.
145
146 - See doc/configuration_examples/*
147
148 In the following, we assume that all the third-party softwares are
149 installed in the same root directory, named <salomeroot>/prerequis.
150 Then, your file system should probably look like::
151
152   <salomeroot>/prerequis/Python-2.2.2
153   <salomeroot>/prerequis/omniORB-3.0.5
154   <salomeroot>/prerequis/qt-x11-free-3.0.5
155   ...
156
157
158 4. Preparing the shell environment
159 ----------------------------------
160
161 Some variables have to be set to get acces to third-party software
162 components (include files, executable, library, ...) during building
163 process and runtime.
164
165 The shell file prerequis.sh, embedded in the KERNEL source package,
166 provides a template for setting those variables. In this example, all the
167 softwares are supposed to be installed in the same root directory,
168 named here INSTALLROOT.
169
170 Copy the prerequis.sh in a working directory and adjust the settings
171 to your own configuration. To get the shell prepared, just
172 execute the following command in the building shell:
173
174 $ source prerequis.sh
175
176 (we assume here a ksh or bash mode)
177
178
179 5. Installing the KERNEL component
180 ----------------------------------
181
182 We use here the notation <kernel_src> to specify the source directory
183 of the KERNEL component. The shell environment is supposed to have
184 been set (cf. 4).
185
186 Installing the KERNEL from a source package needs three directories:
187
188 - the source directory, denoted here by <kernel_src>.
189
190 - the build directory, denoted by <kernel_build> in the following. This
191   directory can't be the same directory as <kernel_src>.
192
193 - the install directory, denoted by <kernel_install> in the following. This
194   directory can't be the same directory as <kernel_src> or
195   <kernel_build>.
196
197 The installing process is:
198
199 STEP 1:
200   preparing directories
201
202   create the <kernel_build> and the <kernel_install> directories::
203
204     $ mkdir <kernel_build>
205     $ mkdir <kernel_install>
206
207 STEP 2:
208   go to build directory
209
210     $ cd <kernel_build>
211
212 STEP 3:
213   configure the building process
214     $ cmake -DCMAKE_BUILD_TYPE=<Mode> -DCMAKE_INSTALL_PREFIX=<kernel_install> ../<kernel_src>
215
216   Where <Mode> is build mode(Release or Debug), <kernel_install> 
217   is a destination folder to install KERNEL module of SALOME.
218   Note that <kernel_install> must be an absolute path.
219
220   When the configure process is complete, check the status of cmake build.
221   You should not have the errors and warnings. All included products and packages must be found.
222   
223   If a software get a status "not found", then it's not "seen" in the system:
224
225 - the software is not installed, or
226 - the shell environment is not set correctly. 
227
228 STEP 4 :
229   Building the binary files
230
231   Execute make in the <kernel_build> directory::
232
233     $ make
234
235
236 STEP 5:
237   Installing binary files, scripts and documentation
238
239   Execute install target in the <kernel_install> directory::
240
241     $ make install
242
243
244 6. Installing the SALOME components
245 -----------------------------------
246
247 TInstalling a component <COMPONENT> is done by following the same
248 instructions as given for the KERNEL, replacing KERNEL by
249 <COMPONENT>.
250
251 You just have to be aware of the dependencies between components:
252
253 - MED    depends on KERNEL
254 - GEOM   depends on KERNEL
255 - SMESH  depends on KERNEL, MED, GEOM
256 - VISU   depends on KERNEL, MED
257 - SUPERV depends on KERNEL
258
259 For example, installing the component SMESH needs the previous
260 installation of the KERNEL component, and then the GEOM and MED components.
261
262 The building process uses the variables <COMPONENT>_ROOT_DIR to
263 localize the dependant components. The variables must be set to the
264 install path directory of the components <COMPONENT> (ex:
265 KERNEL_ROOT_DIR=<kernel_install>). 
266  
267 In the above example, the three variables KERNEL_ROOT_DIR,
268 GEOM_ROOT_DIR and MED_ROOT_DIR have to be set before configuring the
269 building process of the SMESH component (STEP 3).
270
271
272 7. Runtime
273 ----------
274
275 See SALOME_Application_ to define your own configuration of SALOME and run it
276 on one or several computers. This is the recommended way of configuration.
277
278 .. _SALOME_Application: ./SALOME_Application.html
279
280 The following explains the general principles.
281
282 To run the SALOME platform, the procedure is:
283
284 - set the shell environment to get acces to third-party softwares::
285
286    $ source prerequis.sh
287
288 - define the SALOME configuration by setting the whole set of
289   variables <COMPONENT>_ROOT_DIR. Here, you just have to set the
290   kernel and the components you need::
291
292     $ export KERNEL_ROOT_DIR=<kernel_install>
293     $ export MED_ROOT_DIR=<med_install>
294     $ ...
295
296 - define the CORBA configuration file by setting the variable
297   OMNIORB_CONFIG. This variable must be set to a writable file
298   path. The file may be arbitrary chosen and doesn't need to exist
299   before running. We suggest::
300
301     $ export OMNIORB_CONFIG=$HOME/.omniORB.cfg
302
303 - run the SALOME platform by executing the script runSalome::
304
305     $KERNEL_ROOT_DIR/bin/salome/runSalome
306
307
308 8. Suggestions and advices
309 --------------------------
310
311 For convenience or customization, we suggest the following organisation:
312
313 - chose and create a root directory for the SALOME platform, say
314   <salomeroot>.
315
316 - install the third-party softwares in a sub-directory "prerequis"
317
318 - install the SALOME components in a sub-directory "SALOME2"
319
320 - make personnal copies of the files prerequis.sh and runSalome in
321   <salomeroot>::
322
323     $ cp <kernel_src>/prerequis.sh <rundir>/.
324     $ cp <kernel_install>/bin/salome/runSalome <rundir>/.
325
326   Edit the file prerequis.sh and adjust it to your own configuration.
327
328 - define the SALOME2 configuration
329
330   This step consists in setting the KERNEL_ROOT_DIR, the whole set of
331   variables <COMPONENT>_ROOT_DIR you need, and the OMNIORB_CONFIG
332   variable.
333
334   We suggest to create a shell file envSalome.sh containing those
335   settings. Then the configuration consists in loading envSalome.sh in
336   the runtime shell::
337
338     $ source envSalome.sh
339
340 - When installed with this file organisation, running SALOME is done
341   with the following shell commands::
342
343     $ source <salomeroot>/prerequis.sh
344     $ source <salomeroot>/envSalome.sh
345     $ ./runSalome
346
347
348 -------------------------------------------------------------------------------
349
350 +----------------------------------+------------------------------------------+
351 | `General KERNEL documentation`_  | `End User KERNEL Doxygen documentation`_ |
352 +----------------------------------+------------------------------------------+
353
354 .. _`General KERNEL documentation`:           ./index.html
355 .. _`End User KERNEL Doxygen documentation`:  ./tui/KERNEL/index.html