Salome HOME
Update
[tools/install.git] / doc / readme.html
1 <!DOCTYPE html PUBLIC "-//w3c//dtd html 4.0 transitional//en">\r
2 <html>
3 <head>
4   <meta http-equiv="Content-Type"
5  content="text/html; charset=iso-8859-1">
6   <meta name="GENERATOR"
7  content="Mozilla/4.8 [en] (X11; U; Linux 2.4.18-14 i686) [Netscape]">
8   <meta name="Author"
9  content="Alexander KOVALEV, Open CASCADE SAS (alexander.kovalev@opencascade.com)">
10   <meta name="Copyright" content="2002-2009 CEA">
11   <title>SALOME Installation Wizard Help</title>
12 </head>
13 <body style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 229);"
14  alink="#ff0000" link="#0000ee" vlink="#551a8b">
15 &nbsp;
16 <center>
17 <table nosave="" width="100%">
18   <tbody>
19     <tr nosave="">
20       <td nosave="">
21       <h1><a href="http://www.opencascade.com"><img src="logocorp.png"
22  border="0" height="47" width="139"> </a></h1>
23       </td>
24       <td>
25       <center>
26       <h3><font size="+4"><font color="#000099">SALOME Installation
27 Wizard Help</font></font></h3>
28       </center>
29       </td>
30       <td>
31       <div align="right"><a href="http://www.opencascade.org/SALOME/"><img
32  src="application.png" border="0" height="47" width="109"> </a></div>
33       </td>
34     </tr>
35   </tbody>
36 </table>
37 </center>
38 <div align="right"><b><font color="#000099">updated for the version </font><font
39  color="#ff0000">6.4.0</font></b></div>
40 <hr>
41 <ul>
42   <li> <a href="#install_from_wizard">Installing products with the
43 Installation Wizard<br>
44     </a></li>
45   <ul>
46     <li><a href="#gui_mode">GUI mode</a></li>
47     <li><a href="#batch_mode">Batch mode</a></li>
48     <li><a href="#env_files">Environment files</a><br>
49     </li>
50   </ul>
51   <li> <a href="#pick_up_env">Pick up the environment</a></li>
52   <li> <a href="#xml_files">Modifying XML configuration file</a></li>
53   <li> <a href="#new_products">Implementing installation scripts for
54 the new products</a></li>
55   <li> <a href="#finish_buttons">Customizing Readme page buttons</a></li>
56 </ul>
57 <h3>
58 <hr></h3>
59 <h3> <a name="install_from_wizard"></a>Installing products with the <font
60  color="#ff0000">Installation Wizard</font></h3>
61 The Installation Wizard can be launched in two modes: <span
62  style="font-weight: bold;">GUI </span>and <span
63  style="font-weight: bold;">batch</span>. <br>
64 The root directory of the Installation Wizard
65 contains Python script <span style="font-weight: bold;">runInstall</span>.
66 To run the Installation Wizard just type <b>./runInstall</b> in the
67 terminal
68 window:<span style="font-weight: bold;"></span><span
69  style="font-weight: bold;"></span>
70 <p>[ python ] <b>./runInstall </b>[options]<b><br>
71 </b></p>
72 <p>Without options this script will launch the SALOME Installation
73 Wizard in the GUI mode.<br>
74 The default installation settings can be overridden by using of command
75 line options. Each option has short and long notations:<br>
76 </p>
77 <p><b>-g / --gui</b><br>
78 </p>
79 <div style="margin-left: 40px;">Runs the Installation Wizard in the
80 GUI
81 mode (this is the default mode).<br>
82 </div>
83 <p><b>-b / --batch</b><br>
84 </p>
85 <div style="margin-left: 40px;">Runs the Installation Wizard in
86 the terminal mode. <br>
87 </div>
88 <p><b>-f FILE / --file=</b><span style="font-weight: bold;">FILE<br>
89 </span></p>
90 <div style="margin-left: 40px;">
91 This is the XML configuration file used by the Installation Wizard. 
92 If this option is not used, the installation script tries to define 
93 the<i>Linux </i>version and to use the corresponding XML file
94 if it is present.
95 For example, for <span style="color: rgb(0, 0, 153);">Linux Mandriva
96 2006</span>&nbsp; the <b>config_Mandriva_2006.0.xml</b>&nbsp;
97 file
98 will be used by default.
99 </div>
100 <p> <b>-d DIR / --target=DIR</b><br>
101 </p>
102 <div style="margin-left: 40px;">This is the target installation 
103 directory for SALOME platform. If used, this option overrides 
104 the default target directory, given in the
105 configuration XML file (usually<span style="font-weight: bold;">
106 ${HOME}/salome_&lt;version&gt;</span><!--,
107 see
108 <a href="#xml_files">here</a> for more details-->).<br>
109 </div>
110 <p><b>-t DIR / --tmp=DIR </b></p>
111 <div style="margin-left: 40px;">This is the directory, for 
112 temporary files. If given, this option overrides the default 
113 temporary directory, given in the configuration xml file 
114 (usually <span style="font-weight: bold;">/tmp</span>
115 <span style="font-weight: bold;"></span><!--, 
116 see <a href="#xml_files">here</a> for more information-->).<br>
117 </div>
118 <p><b>-a / --all-from-sources</b></p>
119 <div style="margin-left: 40px;">
120 Force all the products to be installed from sources (including all
121 SALOME modules). If this option is used, all the default installation
122 modes for all the products are ignored.<br>
123 This option is helpful when the user wants to install SALOME on the
124 platform which is not officially supported. In this case, the user can
125 try to run the SALOME Installation Wizard with the <span
126  style="font-weight: bold;">-a</span> option in order to build all the
127 products from sources.<br>
128 <b>Note, that this is long-time operation which can take more than 
129 24 hours depending on the computer.</b><br>
130 </div>
131 <p><b>-s / --single-directory </b></p>
132 <div style="margin-left: 40px;">Install all SALOME binaries packages 
133 to one directory.<br>
134 <b>This option is ignored when --all-from-sources (-a) option is used.
135 </b></div>
136 <p><b>-h / --help</b><br>
137 </p>
138 <div style="margin-left: 40px;">Prints help information on
139 the usage of the Installation Wizard. <br>
140 </div>
141 <p></p>
142 <p>
143 <b>-v / --version</b><br>
144 </p>
145 <div style="margin-left: 40px;">Prints version information
146 (<span style="font-weight: bold;">Note: </span>this
147 is the version number of the Installation Wizard, not of SALOME platform). <br>
148 </div>
149 <p>
150 </p>
151 <p>The installation procedure supports different <span style="color: rgb(0, 0, 153);">Linux
152 </span>platforms and installs various 3d-party installation prerequisite products, which
153 are required by SALOME platform. The basic target platforms for SALOME
154 5.0.0 and newer are <b>Linux Mandriva 2008 32bit</b> and <b>Linux Debian 4.0 (Etch) 64bit</b>.<br>
155 The usage of configuration XML files provides a flexible way to modify
156 the list of products to be installed by the Installation Wizard without
157 changing the source code of the application. Just create your own XML
158 configuration file and implement installation scripts for the prerequisite products you
159 need and then use this XML file with the Installation Wizard. This can
160 be done, for example, for some <span style="color: rgb(0, 0, 153);">Linux
161 </span>platform which is not supported directly by the
162 Installation Wizard. See <a href="#xml_files">Modifying XML
163 configuration file</a> and <a href="#new_products">Implementing installation
164 scripts for the new products</a> sections for more information. </p>
165 <h3 style="margin-left: 40px;"> <a name="gui_mode"></a>GUI
166 mode<br>
167 </h3>
168 <p>The GUI of the <font color="#ff0000">Installation Wizard</font> has been
169 developed with <span style="font-weight: bold;"><span style="color: rgb(0, 0, 153);">Qt
170 3.3.8 </span> </span>toolkit by <span style="color: rgb(0, 0, 153);">
171 Trolltech </span>. After launching the Installation Wizard
172 in the GUI mode the wizard window is shown to the user. This wizard
173 guides the user through several subsequent pages. To navigate between
174 the pages use <i>"Next"</i> and <i>"Back"</i>
175 buttons in the lower part of the wizard window. <i>"Cancel"</i> button
176 closes the wizard window&nbsp;and quits the installation procedure after user
177 confirmation. <i>"Help"</i> button opens a window with the help information. </p>
178 <p>The first "<span style="font-style: italic;">Introduction"</span>
179 page is shown in <a href="#IntroPage">Figure 1</a>.
180 Skip this page by pressing <i>"Next"</i> button:
181 </p>
182 <center><a name="IntroPage"></a><br>
183 <img alt="Intro page" src="intropage.png" style="width: 606px; height: 419px;">
184 <p><b>Figure 1:</b> "Introduction" page</p>
185 </center>
186 <p>In the second page you are proposed to select the type of the
187 SALOME installation.<br>
188 <br>
189 At this step three possible types of installation are available:<br>
190 </p>
191 <ol>
192   <li><span style="font-style: italic;"> <font color="#ff0000"><b>"Install binaries"</b></font></span>
193 type:<br>
194     <ul>
195       <li>all binaries and sources of the chosen modules are
196 installed;</li>
197       <li>all binaries of the chosen prerequisites are installed.</li>
198       <br>
199     </ul>
200   </li>
201   <li><span style="font-style: italic;"> <font color="#ff0000"><b>"Install sources"</b></font></span>
202 type:<br>
203     <ul>
204       <li>all sources of the chosen modules and prerequisites are
205 installed without compilation.</li>
206       <br>
207     </ul>
208   </li>
209   <li><span style="font-style: italic;"> <font color="#ff0000"><b>"Install sources and
210 make compilation"</b></font></span> type:<br>
211     <ul>
212       <li>all sources of the chosen modules and prerequisites are
213 installed;</li>
214       <li>all sources are compiled.</li>
215     </ul>
216   </li>
217 </ol>
218 <p></p>
219 <p>In case you select "Install sources and make compilation"
220 installation type, then you can also check "Remove sources and
221 temporary files after compilation" option.
222 </p>
223 <center><a name="Installation_type_page"></a><br>
224 <img alt="Installation type page" src="installtypepage.png" style="width: 606px; height: 419px;">
225 <p><b>Figure 2:</b> "Type of installation" page
226 </p>
227 </center>
228 <p>After the installation type has been selected you click <i>"Next"</i>
229 button and the Installation Wizard tries to determine the Linux
230 platform to load the corresponding configuration file. If the operating
231 system is not defined or the current SALOME package does not support
232 this system, the warning message will appear ("<i>Install binaries</i>"
233 and "<i>Install sources</i>" installation types only):
234 </p>
235 <center><a name="Platform_page"></a><br>
236 <img alt="Platform page" src="platformpage.png" style="width: 606px; height: 419px;">
237 <p><b>Figure 3:</b> "Installation platform" page
238 </p>
239 </center>
240 <p>If "<i>Install sources and make compilation</i>"
241 installation type has been selected, the warning message will be
242 slightly different: "<i>Your Linux platform is not supported by
243 this SALOME package and compilation is not tested on this one</i>".<br>
244 There is a list of all platforms supported by SALOME, but only those
245 supported by the current package are available for selection. in this
246 page you need to to select the reference platform, if you wish to
247 proceed with the present installation procedure.<br>
248 <b>Note:</b> this page is not displayed if the installation
249 platform has been defined automatically.
250 </p>
251 <p>In the next page you are proposed to enter the target
252 installation directory for SALOME platform. You can also press <i>"Browse..."</i>
253 button and choose the destination folder using the standard browse
254 directory dialog box. <br>
255 If the necessary directory does not exist you are
256 prompted to confirm the directory creation. If you type a wrong
257 directory
258 path, or if you do not have the permissions to write to the chosen
259 directory, the corresponding message box is shown.<br>
260 </p>
261 <p><b>Note: you are strongly recommended to avoid using
262 directory names containing spaces.</b> Otherwise you can
263 experience some troubles with the
264 installation.
265 </p>
266 <center><a name="Directory_page"></a><br>
267 <img alt="Directory page" src="directorypage.png" style="width: 606px; height: 419px;">
268 <p><b>Figure 4:</b> "Installation directory" page
269 </p>
270 </center>
271 <p>You can select the products to be installed in the "Choice of
272 the products to be installed" page.<br>
273 In the default mode it gives you the possibility to view and select
274 SALOME modules only. There is a hidden list of 3d-party prerequisite
275 products. To show it, just click "<i>Show prerequisites...</i>"
276 button.
277 </p>
278 <center><a name="Products_page1"></a><br>
279 <img alt="Products page (default mode)" src="productpage1.png" style="width: 606px; height: 419px;">
280 <p><b>Figure 5:</b> Choice of the SALOME modules
281 </p>
282 </center>
283 <p>In the full mode you also have the possibility to select
284 prerequisites.<br>
285 The checkbox before each product indicates if this one will be
286 installed or not (checked or unchecked). The second column shows the
287 disk space occupied by the corresponding module. This value depends on
288 the selected type of installation.<br>
289 To hide the prerequisites list - click "<i>Hide prerequisites</i>"
290 button.</p>
291 <center><a name="Products_page2"></a><br>
292 <img alt="Products page (full mode)" src="productpage2.png" style="width: 606px; height: 419px;">
293 <p><b>Figure 6:</b> Choice of the prerequisites
294 </p>
295 </center>
296 <p>
297 Some products may require some other prerequisite products to be
298 installed. So the installation procedure has a special feature to
299 automatically mark these products in the list view. For example, to
300 install PyQt it is necessary to have gcc, Python, Qt and Sip installed,
301 and these products will be also turned on when you check on PyQt. GEOM
302 module requires KERNEL, GUI modules and such prerequisites as:
303 OpenCascade, Python, Swig, Qt, etc.
304 </p>
305 <p>The dependencies between SALOME modules are managed in the
306 following way:
307 </p>
308 <ul>
309   <li>If one module is unchecked, all modules which depend on
310 this one are also unchecked automatically;</li>
311   <li>If one module is checked, all modules required for this one
312 are also checked automatically.</li>
313 </ul>
314 <p></p>
315 <p>Dependency between modules and prerequisites is realized in
316 the following way:
317 </p>
318 <ul>
319   <li>The choices made by the user in the list of modules have a
320 direct impact on the list of prerequisites;</li>
321   <li>Whenever a module is checked, all the necessary
322 prerequisites are checked automatically with no possibility for the
323 user to uncheck them (see <a href="#Products_page3">Fig.7</a>
324 below);</li>
325   <li>Whenever a module is unchecked, according to the remaining
326 checked modules, the unnecessary prerequisites are unchecked
327 automatically (see <a href="#Products_page3">Fig.7</a>
328 below).</li>
329 </ul>
330 It is possible to check again the prerequisites, which have been
331 automatically unchecked. In other words, it is possible to add more
332 prerequisites than necessary.
333 <p></p>
334 <center><a name="Products_page3"></a><br>
335 <img alt="Products page (dependencies presentation)" src="productpage3.png" style="width: 606px; height: 419px;">
336 <p><b>Figure 7:</b> Dependencies between modules and
337 prerequisites
338 </p>
339 </center>
340 <p>The "<i>Installation with GUI</i>" checkbox allows
341 managing the installation of the graphical interface. Only modules for that 
342 'woguimode' attribute is set to "true" value in the XML file 
343 (see <a href="#xml_files">here</a> for more information about
344 customizing this installation mode) support without GUI mode and 
345 will be checked and installed with their necessary prerequisites in 
346 case of installation without GUI. And other modules are unchecked with no
347 possibility to check them in this mode (see <a href="#Products_page4">figure</a> below).<br>
348 By default 'Installation with GUI' checkbox is switched on.
349 </p>
350 <center><a name="Products_page4"></a><br>
351 <img alt="Products page (Installation without GUI)" src="productpage4.png" style="width: 606px; height: 419px;">
352 <p><b>Figure 8:</b> Installation without GUI mode
353 </p>
354 </center>
355 <p>The box at the right side of the page displays the information
356 about the currently selected product: name, version and short description,
357 required disk space, disk space required for the temporary files and
358 the list of prerequisites (this information is provided in the XML
359 file).
360 </p>
361 <p>The <i>"Disk space required:"</i> field displays
362 how much
363 disk space on the hard drive is required for installation of the
364 selected
365 products.<br>
366 <b>Note:</b> please, take into account that the displayed
367 amount of
368 the required disk space is approximate and may differ when you actually
369 install products on your hard drive.
370 </p>
371 <p>The installation procedure uses a special directory to store
372 temporary files. The <i>"Space for temporary files"</i>
373 field shows
374 the information about the required disk space on the hard drive for
375 extracting and compiling the selected products. You can change the
376 temporary directory (this information is provided in the XML file) to
377 the folder you want.<br>
378 <span style="font-weight: bold;">Note:</span>
379 actually, the temporary files
380 are not stored directly in the directory selected by the user. The
381 Installation Wizard creates in this directory an additional folder
382 named
383 like INSTALLWORK<span style="font-weight: bold;">XXXXX</span>
384 where XXXXX is a unique number. This allows launching several
385 Installation Wizards simultaneously. This temporary directory is
386 removed automatically when the installation finishes.<br>
387 </p>
388 <p>The installation procedure also checks the available disk
389 space. If
390 there is not enough disk space on your hard drive you will see the
391 corresponding error message box.
392 </p>
393 <p>Also in the current version of Installation Wizard is possible
394 to install all binaries of the selected SALOME modules into a <b>single</b>
395 directory. It is "<i>SALOME</i>" directory.
396 For this purpose there is a checkbox "<i>Install modules to a
397 single directory</i>" checkbox exists (see <a href="#Products_page4">Fig.8</a>).<br>
398 This feature helps to get shorter PYTHONPATH and LD_LIBRARY_PATH
399 environment variables.<br>
400 <b>Note:</b> the installation into a single directory is
401 available with the binaries installation type only.
402 </p>
403 <p>To proceed further, click <i>"Next"</i> button.
404 At this moment
405 the program will make some tests to check the installation settings: if
406 there is enough disk space on the hard drive, check for the
407 dependencies for each product you have selected to be installed. If any
408 test fails you will see the corresponding warning message box.
409 Otherwise the wizard will proceed to the next page:
410 </p>
411 <center><a name="ChoicePage"></a><br>
412 <img alt="Choice page" src="choicepage.png" style="width: 606px; height: 419px;">
413 <p><b>Figure 9:</b> "Check your choice" page
414 </p>
415 </center>
416 <p>This page summarizes the installation options you've selected
417 in the
418 previous pages. You can review again your choices and change them if
419 necessary returning to the previous pages. <br>
420 When you are sure that everything is OK, press <i>"Next"</i>
421 button to
422 follow to the <a href="#ProgressPage1">progress page</a>.
423 </p>
424 <center><a name="ProgressPage1"></a><br>
425 <img alt="Progress page (not started yet)" src="progresspage1.png" style="width: 606px; height: 419px;">
426 <p><b>Figure 10:</b> "Installation progress" page:
427 not started yet
428 </p>
429 </center>
430 <div style="text-align: left;">To start the installation
431 of the selected products click <i>"Start"</i>
432 button. It launches the shell installation script and you will be able
433 to see the output of the script in the topmost frame of the dialog box.
434 If any errors occur during the installation progress, the corresponding
435 messages will be printed to the log window in the bold red font and 
436 installation process will be aborted with error message box. But user 
437 has possibility to change this default behaviour by 
438 <i>"Ignore installation errors"</i> checkbox. It is necessary to check 
439 it before start and all occured errors will be passed, 
440 and installation will be continued in any case.<br>
441 </div>
442 <div style="text-align: left;">It is possible to break the
443 installation at any time by pressing <span style="font-style: italic;">"Stop"</span>
444 button. Then you can get back to the previous pages if you wish to
445 change the installation settings or restart the installation by
446 pressing <span style="font-style: italic;">"Start"</span>
447 button again.<br>
448 </div>
449 <p style="text-align: left;"><span style="font-weight: bold;">Note:</span>
450 in the current
451 implementation it is not possible to resume the stopped installation
452 process; the installation will restart from the very beginning. <br>
453 </p>
454 <center><a name="ProgressPage2"></a><br>
455 <img alt="Progress page (installation started)" src="progresspage2.png" style="width: 606px; height: 419px;">
456 <p><b>Figure 11:</b> "Installation progress" page:
457 installation in
458 progress
459 </p>
460 </center>
461 <p>The <i>"Installation Status"</i> frame window
462 shows you the
463 progress of installation. "<font color="#ff0000">Waiting</font>"
464 status
465 means that the installation of this product has not started
466 yet. The product currently being installed is marked as "<font color="#ff9900">Processing</font>" and is displayed in
467 the status bar under "Installation Status" view. All installed products
468 have "<font color="#33ff33">Completed</font>"
469 status.
470 </p>
471 <p>You can abort the installation and close the installation
472 procedure
473 using <i>"Cancel"</i> button. <br>
474 <span style="font-weight: bold;">Note:</span> this
475 button sends the
476 signal "SIGTERM" to the shell script.
477 The script tries to clear all temporary files.
478 The process of removing the temporary files can take some time, so the
479 installation wizard will wait for 3 seconds before closing.
480 </p>
481 <p>At the end of the installation "<b>Installation completed</b>"
482 message will appear in the status bar. You can return to the previous
483 pages to start a new installation or click <i>"Next"</i>
484 button to go to the readme page: </p>
485 <center><a name="readmepage"></a><br>
486 <img alt="Readme page" src="readmepage.png" style="width: 606px; height: 419px;">
487 <p><b>Figure 12:</b> "Finish installation" page
488 </p>
489 </center>
490 <p>In this page you can read important information about the
491 Installation Wizard itself and some tips: how to run and test SALOME or
492 how to build SALOME from the sources. This is also described the
493 README file which you can find in the root directory of the
494 Installation Wizard. <br>
495 You can also launch SALOME Desktop from this
496 page or read the Release Notes file by clicking on the corresponding
497 buttons in the lower part of the page (see <a href="#xml_files">here</a>
498 and <a href="#finish_buttons">here</a> for more
499 information about
500 customizing these buttons).<br>
501 </p>
502 <h3 style="margin-left: 40px;"> <a name="batch_mode"></a>Batch mode<br>
503 </h3>
504 To launch the Installation Wizard in the batch mode use <span
505 style="font-weight: bold;">-b</span>
506 (<span style="font-weight: bold;">--batch</span>) parameter.<br>
507 In this mode the GUI wizard is not shown but all the installation
508 status is displayed directly in the console. In the batch mode user do
509 not have a possibility to change installation settings which are given
510 in the configuration file, except target and temporary directories
511 which can be overridden by the corresponding command line options.<br>
512 There are two exceptions: <b>--all-from-sources</b>
513 (<b>-a</b>) option which enables
514 special installation mode in which all the products (including SALOME
515 modules) are installed from sources, ignoring default mode defined in
516 the XML configuration file (see <a href="#install_from_wizard">here</a>
517 for details) and <b>--single-directory</b> (<b>-s</b>) option which defines
518 that all SALOME modules have to be installed into the one directory 
519 (SALOME_&lt;version&gt;, by default, where &lt;version&gt; is SALOME version).
520 <center><a name="BatchMode"></a><br>
521 <br>
522 <img alt="Batch mode" src="batchmode.png"
523 style="width: 638px; height: 425px;">
524 <p><b>Figure 9:</b> Batch mode</p>
525 </center>
526 <h3 style="margin-left: 40px;"><a name="env_files"></a>Environment
527 files</h3>
528 <p>During the process of installation the
529 script creates some
530 environment files to simplify the procedure of launching SALOME. These
531 shell scripts set
532 all necessary environment variables for all products you have
533 installed.
534 To learn how the installation scripts collect the environment, see <a href="#pick_up_env">here</a>. These files are: <b>salome.csh</b>
535 + <b>salome.sh</b>
536 in the <span style="font-style: italic;"><span style="font-weight: bold;">KERNEL module</span></span><b><i>
537 sources</i></b>
538 and <span style="font-style: italic;"><span style="font-weight: bold;">KERNEL
539 module</span></span><b><i> binaries</i></b>
540 root directories and <b>env_products.csh</b>
541 + <b>env_products.sh </b>and <span style="font-weight: bold;">env_build.csh
542 </span>+ <span style="font-weight: bold;">env_build.sh</span>
543 in the
544 target installation directory.<br>
545 </p>
546 <span style="font-weight: bold;">Note:</span> there
547 is some difference
548 between these files: <span style="font-weight: bold;">env_build.*</span>
549 files are optimized to
550 be used for the building of SALOME modules from sources (see <span style="font-weight: bold;">README </span>file
551 provided with the
552 installation procedure on the CD). The <span style="font-weight: bold;">env_products.*</span>
553 (and<span style="font-weight: bold;"> salome.*</span>)
554 files are
555 optimized for
556 the SALOME launching. The behavior is defined by the environment
557 variable<span style="font-weight: bold;"> </span><b>ENV_FOR_LAUNCH</b>
558 which is set to <span style="font-weight: bold;">0</span>
559 in
560 env_build.* files and to <span style="font-weight: bold;">1</span>
561 in
562 env_products.*
563 (salome.*) files.<br>
564 <br>
565 <hr>
566 <h3> <a name="pick_up_env"></a>Pick up the <font color="#ff0000">environment</font></h3>
567 Please, read carefully the following information. This section
568 describes how the installation procedure generates the environment
569 scripts for the SALOME platform being installed.
570 <p>After the installation of each product the shell script
571 creates a special
572 environment file for the product in its installation folder. The name
573 of the file is generated from the name of the product by the following
574 scheme: <b>env_&lt;product_name&gt;.sh</b>
575 (for example <b>env_Vtk.sh </b>for the Vtk).
576 This file includes all necessary environment settings. At the final
577 step of the installation the script picks up all settings files and
578 generates from them two common environment files: <b>salome.sh</b>
579 and <b>salome.csh
580 </b>for <span style="font-weight: bold;">bash</span>
581 and <span style="font-weight: bold;">csh</span>
582 shells correspondingly. This
583 approach helps to save time when reinstalling products and you may can
584 avoid setting all environment variables
585 manually to build/launch SALOME. What you need is to source one of
586 these environment files. </p>
587 <p>This also concerns the products which are not being installed.
588 For example, you install some SALOME binaries to the directory where
589 you have previously installed other products.&nbsp; The
590 installation
591 procedure tries to collect the environment files from the target
592 directory if it finds necessary products installed there. If a
593 product is not found in the target directory the corresponding
594 section of <b>salome.sh/salome.csh</b> files will be
595 commented. <br>
596 For the native products (like <i><b>gcc, tcl, etc...</b><b>)</b></i>
597 the installation procedure tries to find them first using <b>PATH</b>
598 / <b>LD_LIBRARY_PATH</b> variables and then in the system
599 default
600 directories (<b>/usr/bin, /usr/lib</b> etc., depending on
601 the product).
602 </p>
603 <p>In any case you are able to edit <b>salome.*</b>
604 files after the installation procedure finished.<br>
605 <span style="font-weight: bold;"><br>
606 Note:</span> as it has been mentioned <a href="#env_files">above</a>
607 there
608 are other environment files generated by the installation procedure: <span style="font-weight: bold;">env_products.csh</span> + <span style="font-weight: bold;">env_products.sh</span> and <span style="font-weight: bold;">env_build.csh</span> + <span style="font-weight: bold;">env_build.sh</span>. These
609 files can be
610 found in the target installation root directory.<br>
611 </p>
612 <hr>
613 <h3><a name="xml_files"></a>Modifying <font color="#ff0000">XML</font>
614 configuration <font color="#ff0000">file</font></h3>
615 <font color="#000000">You can create your own XML
616 configuration file.
617 The Installation Wizard can take it as a command line argument to
618 provide a list of products you want to install with it. The list of
619 products and some other settings for the Installation Wizard are
620 provided in the XML file.<br>
621 This section describes the structure of the configuration file.</font>
622 <font color="#000000">XML tags are in bold blue, optional
623 sections/tags
624 are in brackets.</font>
625 <font face="Courier">
626 <p><b><font color="#000099">&lt;document&gt;</font></b>
627 <br>
628 <font color="#000000"><b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
629 </b></font><b><font color="#000099">
630 &lt;config</font></b><font color="#000000">
631 [ version=&lt;application_version&gt;
632 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;]</font> <br>
633 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
634 &nbsp;
635 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [
636 caption=&lt;application_caption&gt;
637 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;]</font> <br>
638 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
639 &nbsp;
640 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [
641 copyright=&lt;application_copyright&gt;&nbsp; ]</font>
642 <br>
643 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
644 &nbsp;
645 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [
646 license=&lt;application_license_info&gt; ]</font> <br>
647 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
648 &nbsp;
649 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
650 platforms=&lt;target_platform&gt;</font> <br>
651 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
652 &nbsp;
653 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [
654 targetdir=&lt;target_directory&gt;
655 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;] </font>
656 <br>
657 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
658 &nbsp;
659 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
660 [
661 tempdir=&lt;temp_directory&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
662 &nbsp;&nbsp;&nbsp;&nbsp; ]</font>
663 <br><font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
664 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[
665 optionallibs=&lt;optional_libraries&gt;&nbsp;&nbsp;]</font>
666 <b><font color="#000099"><br>
667 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /&gt; </font></b>
668 <br>
669 <font color="#000000"><b>&nbsp;&nbsp;&nbsp;
670 </b>[ </font><b><font color="#000099">&lt;buttons&gt;</font></b>
671 <br>
672 <font color="#000000"><b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
673 </b>[ </font><b><font color="#000099">&lt;button</font></b>
674 <font color="#000000">&nbsp;
675 label=&lt;button_label&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</font>
676 <br>
677 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
678 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
679 [ tooltip=&lt;button_tooltip&gt; ]</font> <br>
680 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
681 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
682 &nbsp;
683 script=&lt;button_script&gt;&nbsp;&nbsp;&nbsp;</font>
684 <br>
685 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
686 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
687 [ disable=&lt;disable_flag&gt;&nbsp;&nbsp;&nbsp;]</font><font color="#000099"><br>
688 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <b>/&gt;</b>
689 </font><font color="#000000"><br>
690 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ]</font> <br>
691 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
692 [</font><b><font color="#000099">
693 &lt;button</font></b><font color="#000000">
694 ... </font><font color="#000099"><br>
695 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <b>/&gt;</b></font>
696 <br>
697 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
698 ]</font><br>
699 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
700 ...</font>
701 <font color="#000099"><br>
702 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <b>&lt;/buttons&gt;</b>
703 </font><font color="#000000"><br>
704 &nbsp;&nbsp;&nbsp; ]</font> <br>
705 <font color="#000000">&nbsp;&nbsp;&nbsp; [</font><b><font color="#000099"> &lt;products&gt;</font></b>
706 <br>
707 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
708 [</font><b><font color="#000099">
709 &lt;product</font></b><font color="#000000">&nbsp;
710 name=&lt;product_name&gt;</font> <br>
711 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;
712 &nbsp;
713 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
714 type=&lt;product_type&gt;</font> <br>
715 &nbsp;&nbsp;&nbsp; &nbsp; &nbsp;
716 &nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp; [
717 description=&lt;product_description&gt; ]<br>
718 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
719 </font><b><font color="#000099">
720 &lt;installation</font></b><font color="#000000">&nbsp;
721 os=&lt;installation_platform&gt;</font> <br>
722 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;
723 &nbsp;&nbsp;&nbsp;&nbsp;
724 &nbsp;&nbsp;
725 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
726 version=&lt;product_version&gt;</font> <br>
727 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
728 &nbsp;&nbsp;&nbsp;
729 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
730 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [
731 disable=&lt;disable_flag&gt;
732 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;]
733 <font color="#000000"><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
734 &nbsp;&nbsp;&nbsp;
735 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
736 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [
737 woguimode=&lt;without_gui_mode_flag&gt; ]
738 <font color="#000000"><br>
739 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
740 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
741 installdiskspace=&lt;install_disk_space&gt;</font><br>
742 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
743 &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
744 &nbsp;&nbsp;&nbsp;&nbsp; [
745 pickupenv=&lt;pickup_env_flag&gt;
746 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;]</font>&nbsp;
747 <font color="#000000"><br>
748 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
749 &nbsp;
750 &nbsp;&nbsp;&nbsp;&nbsp;
751 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
752 script=&lt;installation_script_name&gt;</font><br>
753 <font color="#000099">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
754 <b>/&gt;</b></font><br>
755 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
756 ...</font>
757 <font color="#000099"><br>
758 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <b>/&gt;</b></font><font color="#000000">
759 <br>
760 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ]</font> <font color="#000000"><br>
761 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [</font><b><font color="#000099"> &lt;product</font></b><font color="#000000"> ... </font><font color="#000099"><br>
762 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <b>/&gt;</b></font><font color="#000000"> <br>
763 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ]</font><br>
764 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
765 ...</font><br>
766 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</font><b><font color="#000099"> &lt;/products&gt;</font></b>
767 <br>
768 <font color="#000000">&nbsp;&nbsp;&nbsp; ]</font><br>
769 <font color="#000000">&nbsp;&nbsp;&nbsp; [</font><b><font color="#000099"> &lt;dependencies&gt;</font></b>
770 <br>
771 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
772 [</font><b><font color="#000099">
773 &lt;product</font></b><font color="#000000">&nbsp;
774 name=&lt;product_name&gt;</font><b><font color="#000099"> &gt;</font></b> <br>
775 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
776 [</font><b><font color="#000099">
777 &lt;dep&gt;</font></b> <font color="#000000">&lt;prerequisite_name&gt;</font>
778 <b><font color="#000099"> &lt;/dep&gt;</font></b>
779 <font color="#000000">]</font><br>
780 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
781 ...</font><br>
782 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</font><b><font color="#000099"> &lt;/product&gt;</font></b>
783 <br>
784 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
785 ]</font><br>
786 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
787 ...</font><br>
788 <font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</font><b><font color="#000099"> &lt;/dependencies&gt;</font></b>
789 <br>
790 <font color="#000000">&nbsp;&nbsp;&nbsp; ]</font><br>
791 <b><font color="#000099">
792 &lt;/document&gt;</font></b> </font></p>
793
794 <h4><font color="#000000">&lt;config&gt;
795 section</font></h4>
796 <font color="#000000">This section provides general
797 information about an application that will be installed.<br>
798 <br>
799 Attributes:<br>
800 </font>
801 <ul>
802   <li> <font color="#000000"><b>version</b></font></li>
803 </ul>
804 <font color="#000000">The application version number to be
805 shown in the
806 caption.</font>
807 <ul>
808   <li> <font color="#000000"><b>caption</b></font></li>
809 </ul>
810 <font color="#000000">The application main window caption
811 - if this
812 string contains '%1' text the title will contain
813 the version number in this place (see above).</font>
814 <ul>
815   <li> <font color="#000000"><b>copyright</b></font></li>
816 </ul>
817 <font color="#000000">The application
818 copyright information (shown in the first page).</font>
819 <ul>
820   <li> <font color="#000000"><b>license</b></font></li>
821 </ul>
822 <font color="#000000">The application license information
823 (shown in the
824 first page).</font>
825 <ul>
826   <li> <font color="#000000"><b>platforms</b></font></li>
827 </ul>
828 <font color="#000000">This parameter defines platforms for
829 whose the configurations from this file will be used. Also it provides
830 the directory name (relative from ./Products/BINARIES) where the
831 Installation Wizard will search for precompiled binaries packages.</font>
832 <ul>
833   <li> <font color="#000000"><b>targetdir</b></font></li>
834 </ul>
835 <font color="#000000">The target
836 directory is the path to the directory where the products should be
837 installed.</font>
838 <ul>
839   <li> <font color="#000000"><b>tempdir</b></font></li>
840 </ul>
841 <font color="#000000">The temporary directory is
842 the path to the directory for the temporary files.</font>
843 <ul>
844   <li> <font color="#000000"><b>optionallibs</b></font></li>
845 </ul>
846 <font color="#000000">A list of names of libraries. 
847 An absence of these libraries in the user's system 
848 doesn't affect on the correct work of SALOME platform.</font>
849 <h4> <b>&lt;buttons&gt; section</b></h4>
850 This is an optional section and may contains one or more
851 &lt;product&gt; sections.
852 <h4> <b>&lt;button&gt; section</b></h4>
853 This optional section allows customization of the last <i>"Finish
854 installation"</i> page of the Installation Wizard by adding one
855 or
856 more buttons in the lower part of the Installation Wizard window. The
857 script
858 which is attached to each such button, can perform some specific
859 actions, for example, launch the application or show the 'Release
860 Notes'
861 file by using an external program.
862 See <a href="#finish_buttons">here</a> for more
863 details about
864 writing scripts.<br>
865 <font color="#000000"><br>
866 Attributes:</font><br>
867 <ul>
868   <li> <font color="#000000"><b>label</b></font></li>
869 </ul>
870 <font color="#000000">This is the button text.</font>
871 <ul>
872   <li> <font color="#000000"><b>tooltip</b></font></li>
873 </ul>
874 <font color="#000000">The button tooltip (optional).</font>
875 <ul>
876   <li> <font color="#000000"><b>script</b></font></li>
877 </ul>
878 <font color="#000000">The script attached to the button.</font>
879 <ul>
880   <li> <font color="#000000"><b>disable</b></font></li>
881 </ul>
882 <font color="#000000">If this optional flag has 'true'
883 value, the corresponding button will not appear in the <i>"Finish
884 installation"</i> page - the section of XML file is ignored.</font><br>
885 <h4> <b>&lt;products&gt; section</b></h4>
886 This one contains a list of &lt;product&gt; sections. The
887 products appear in the tree view and are installed in the order they
888 are described in this section.
889 <h4> <b>&lt;product&gt; section</b></h4>
890 Current section is optional. It describes the product to be installed
891 with the Installation
892 Wizard. The &lt;products&gt; container should include
893 &lt;product&gt; section for each
894 product to be installed.<br>
895 <font color="#000000"><br>
896 Attributes:</font><br>
897 <ul>
898   <li> <font color="#000000"><b>name</b></font></li>
899 </ul>
900 <font color="#000000">The name of the product.</font>
901 <ul>
902   <li> <font color="#000000"><b>type</b></font></li>
903 </ul>
904 <font color="#000000">The type of the product: '<i>component</i>'
905 - SALOME module or '<i>prerequisite</i>' - prerequisite
906 product.</font>
907 <ul>
908   <li> <font color="#000000"><b>description</b></font></li>
909 </ul>
910 The <font color="#000000">product </font><font color="#000000">description
911 (optional).</font>
912 <h4> <b>&lt;installation&gt; section</b></h4>
913 It is a part of the &lt;product&gt; section, that provides
914 installation information by platforms. The &lt;product&gt;
915 section may contains a several &lt;installation&gt; ones for
916 the different platforms.
917 <br>
918 <font color="#000000"><br>
919 Attributes:</font><br>
920 <ul>
921   <li> <font color="#000000"><b>os</b></font></li>
922 </ul>
923 <font color="#000000">A possible installation platform.</font>
924 <ul>
925   <li> <font color="#000000"><b>version</b></font></li>
926 </ul>
927 <font color="#000000">The version of the product.</font>
928 <ul>
929   <li> <font color="#000000"><b>disable</b></font></li>
930 </ul>
931 <font color="#000000">If this optional flag has 'true'
932 value, the corresponding product will not appear in the list of
933 products and will not be installed.</font>
934 <ul>
935   <li> <font color="#000000"><b>woguimode</b></font></li>
936 </ul>
937 <font color="#000000">This optional flag defines that 
938 it's possible to install this module without GUI.</font>
939 <ul>
940   <li> <font color="#000000"><b>installdiskspace</b></font></li>
941 </ul>
942 <font color="#000000">List of three total amount spaces
943 (integer, in Kbytes, derived by comma), which product occupies on the
944 hard drive after the installation in case 'binary', 'sources' and
945 'sources and compile' installation type.</font>
946 <ul>
947   <li><b>pickupenv</b></li>
948 </ul>
949 This flag shows that the pickup environment
950 procedure should be performed for this product. If this flag equal to
951 'true',
952 &nbsp;salome.sh and salome.csh files will&nbsp; be created in
953 the product's
954 installation directory. Usually this option is set to true for SALOME
955 KERNEL module. This is optional key, default value is 'false'<b>.</b><br>
956 <ul>
957   <li> <font color="#000000"><b>script</b></font></li>
958 </ul>
959 <font color="#000000">The installation script name.
960 This script is in charge of the installation of the product. It is
961 called
962 automatically by the Installation Wizard when necessary from the main
963 program. See the <a href="#new_products">next
964 section</a> for
965 more information.</font><br>
966 <br>
967 <b>Note:</b> If you add new products to be
968 installed with Installation Wizard, you should also provide
969 installation script for this product. See the next section for more
970 details.
971 <p><br>
972 </p>
973 <hr>
974 <h3><a name="new_products"></a>Implementing <font color="#ff0000">installation
975 scripts</font> for the new products</h3>
976 When you want some product to be installed with the Installation
977 Wizard, you should add it's description it <a href="#xml_files">in
978 the
979 configuration file</a> and create the installation script,
980 following
981 rules described in this section. <br>
982 <br>
983 There are some obligatory functions which should be implemented in this
984 installation
985 script. These functions are automatically called by master installation
986 script
987 or/and its GUI shell when it is necessary.<br>
988 <font color="#000000">File <b>common.sh</b>
989 contains some service
990 functions
991 which can be used in your installation script, like <b>make_env()</b>,<b>
992 make_dir()</b>, <b>try_existing()</b>, <b>sort_path()</b>,<b>
993 find_in_path()</b>,
994 etc.</font>
995 <ul>
996   <li> <b>check_version()</b></li>
997 </ul>
998 This function allows to check the
999 version of the product already installed on the computer. It should try
1000 to find product (native or preinstalled in the target directory) and
1001 check
1002 its version. This helps to avoid unnecessary reinstallation. This is
1003 internal
1004 function and is not called from the master installation script.<br>
1005 <ul>
1006   <li><font color="#000000"><b>install_binary()</b></font></li>
1007 </ul>
1008 <font color="#000000">This function is
1009 called when <i>'Install binaries'</i> installation mode is
1010 selected by
1011 the user. The function is responsible for the extracting of the product
1012 from the binaries package. It should create environment for the product
1013 in
1014 the temporary directory (see also the description of <b>print_env()</b>
1015 function). It is not necessary to implement this function if you do not
1016 provide binaries mode
1017 installation for the current product. <br>
1018 </font>
1019 <ul>
1020   <li> <font color="#000000"><b>install_source()</b></font></li>
1021 </ul>
1022 <font color="#000000">This function is
1023 called to install SALOME modules sources, if <i>'Install binaries</i>'
1024 installation mode is selected by the user, and to install prerequisite
1025 products sources, in <i>'Install sources</i>' case (see <a href="#Installation_type_page">Fig.2</a> above). The
1026 function is responsible for the building of the product from
1027 the sources package. It should create the environment file for the
1028 product
1029 in the temporary directory (see also the description of <b>print_env()</b>
1030 function). It is not necessary to implement this function if you do not
1031 provide a sources mode installation for the current product.</font>
1032 <br>
1033 <ul>
1034   <li> <font color="#000000"><b>install_source_and_build()</b></font></li>
1035 </ul>
1036 <font color="#000000">This function is
1037 called when <i>'Install sources and make a compilation'</i>
1038 installation mode is selected. This function should be used to unpack
1039 SALOME or prerequisite sources package and then call build/install
1040 procedure for it.<br>
1041 For more details please refer to <a href="#gui_mode">this</a>
1042 section for more details.<br>
1043 </font>
1044 <ul>
1045   <li> <b>try_preinstalled()</b></li>
1046 </ul>
1047 <font color="#000000">This function
1048 is used to parse the target directory to try to find an already
1049 installed product, to pick up and to check the environment from
1050 there. See <a href="#pick_up_env">here</a> for more
1051 details.</font>
1052 <ul>
1053   <li> <font color="#000000"><b>print_env_bin()
1054     </b> &amp; <b> print_env_src()</b></font></li>
1055 </ul>
1056 <font color="#000000">These functions are in charge of the
1057 creation of the environment scripts. They should create in the
1058 temporary directory two files with <b>env_&lt;product_name&gt;.sh</b>
1059 and <b>env_&lt;product_name&gt;_src.sh</b>
1060 names and then copy them into the binary and sources product
1061 installation directories correspondingly. The file should contain all
1062 necessary
1063 environment variable settings for the product. It will be collected
1064 during the 'pick-up-environment' procedure.</font>
1065 <ul>
1066   <li><b>pickup_env()</b></li>
1067 </ul>
1068 This procedure corresponds to <b>pickupenv</b> tag
1069 of the configuration xml file (see the previous section). It should
1070 call <b>make_env</b>
1071 procedure to perform the pick-up environment procedure for the product.<br>
1072 <br>
1073 <font color="#000000">The calling signature of the product
1074 installation
1075 script is the following:</font> <br>
1076 <b><font color="#000000">
1077 &lt;product_script_name&gt;
1078 &lt;function_name&gt;
1079 &lt;temp_folder&gt;
1080 &lt;products_directory&gt;
1081 &lt;target_directory&gt;
1082 &lt;all_products&gt;
1083 &lt;product_name&gt;
1084 &lt;install_products&gt;
1085 &lt;sources_directory&gt;
1086 &lt;remove_sources_flag&gt;
1087 &lt;binaries_directory&gt;
1088 &lt;single_directory_flag&gt; </font></b>
1089 <p><font color="#000000">where</font> <br>
1090 </p>
1091 <p><font color="#000000"><b>&lt;product_script_name&gt;</b>
1092 -
1093 the name of the installation script (described in the configuration XML
1094 file);</font> <br>
1095 <font color="#000000"><b>&lt;function_name&gt;</b>
1096 - the name of
1097 the function, corresponding to the selected installation type and
1098 currently installed product; </font> <br>
1099 <font color="#000000"><b>
1100 &lt;temp_folder&gt; </b> - the directory for the
1101 temporary files; </font> <br>
1102 <font color="#000000"><b>&lt;products_directory&gt;</b>
1103 - the directory
1104 where the sources/binaries package can be found. You should provide
1105 sources package in the <i>&lt;Install_Wizard_root_directory&gt;/Products/SOURCES</i>
1106 directory and binaries package in the <i>&lt;InstallWizard_root_directory&gt;/Products/BINARIES/&lt;os_version&gt;</i>,
1107 where &lt;os_version&gt; is the target platform description,
1108 which appears
1109 in the corresponding section of the <a href="#xml_files">configuration
1110 xml
1111 file</a>.</font> <br>
1112 <font color="#000000"><b>
1113 &lt;target_directory&gt; </b> - the root target
1114 directory where the product should be installed to;</font> <br>
1115 <font color="#000000"><b>
1116 &lt;all_products&gt; </b> - single-quoted list
1117 of all products, separated by space;</font> <br>
1118 <font color="#000000"><b>
1119 &lt;product_name&gt; </b>- product name
1120 itself;</font> <br>
1121 <font color="#000000"><b>
1122 &lt;install_products&gt; </b> - single-quoted list
1123 of all products to be installed, separated by space;</font> <br>
1124 <font color="#000000"><b>
1125 &lt;sources_directory&gt; </b> - the directory
1126 where the sources package can be found (it is usable if the
1127 &lt;products_directory&gt; parameter gives the binaries
1128 directory path); </font> <br>
1129 <font color="#000000"><b>
1130 &lt;remove_sources_flag&gt; </b> - bool parameter, that
1131 is equal to 'TRUE' if 'Remove sources and temporary files after
1132 compilation' option has been selected by the user (see <a href="#Installation_type_page">Fig.2</a> in the <a href="#gui_mode">GUI part</a>);</font> <br>
1133 <font color="#000000"><b>
1134 &lt;binaries_directory&gt; </b> - the directory
1135 where the binaries package can be found (it is usable if the
1136 &lt;products_directory&gt; parameter gives the sources
1137 directory path); </font> <br>
1138 <font color="#000000"><b>
1139 &lt;single_directory_flag&gt; </b> - bool parameter,
1140 that is equal to 'TRUE' if 'Install modules to a single directory'
1141 option is selected by the user (see <a href="#Products_page1">Fig.5</a>
1142 above). </font> <br>
1143 </p>
1144 <p><font color="#000000">Example:</font> <br>
1145 <i><font color="#000000">med-2.3.3.sh install_binary
1146 /tmp/INSTALLWORK21797
1147 ./Products/BINARIES/Mandriva2006.0
1148 'gcc tcltk tcltk_src Python Python_src Qt Qt_src ... DOCUMENTATION
1149 DOCUMENTATION_src'
1150 Med
1151 'gcc Hdf Med'
1152 ./Products/SOURCES
1153 FALSE
1154 ./Products/BINARIES/Mandriva2006.0
1155 </font></i></p>
1156 <p><font color="#000000">Copy the created script
1157 into
1158 the <i>&lt;Install_Wizard_root_directory&gt;/config_files</i>
1159 sub-directory where all installation scripts are stored. The Installation
1160 Wizard will automatically search and call your script during the
1161 installation
1162 procedure.</font>
1163 </p>
1164 <hr> <br>
1165 <h3><a name="finish_buttons"></a>Customizing <font color="#ff0000">Readme
1166 page</font> buttons</h3>
1167 The Installation Wizard allows customizing the layout of the last
1168 <i>"Finish installation"</i> page. If you want to add one
1169 or more
1170 buttons in this page to perform some specific actions at the
1171 end of the installation (for example, show the 'Release Notes' file by using
1172 Open Office) you can put an additional section to the XML
1173 configuration file. This is the <b>&lt;button&gt;</b>
1174 section (see <a href="#xml_files">here</a> for more
1175 details). <br>
1176 <br>
1177 To implement the action which will be performed when the user clicks on
1178 the button, you need to create a script and to put it into the
1179 <i>&lt;Install_Wizard_root_directory&gt;/config_files</i>
1180 directory.<br>
1181 There are some obligatory functions which should be implemented in this
1182 script. These functions are automatically called by the Installation
1183 Wizard GUI.
1184 <ul>
1185   <li><b>check_enabled()</b></li>
1186 </ul>
1187 This procedure is called by the Installation Wizard when the
1188 <i>"Finish installation"</i> page is displayed and the
1189 status of the
1190 buttons should be modified according to the installation options. This
1191 procedure should return <b>0</b> if the corresponding
1192 action can be
1193 performed and, thus, the button should be enabled. Otherwise, it
1194 should return <b>1</b> - in this case the corresponding
1195 button will be
1196 disabled.
1197 <ul>
1198   <li><b>execute()</b></li>
1199 </ul>
1200 This procedure is invoked when the user clicks the button. This
1201 procedure should return <b>0</b> if the corresponding
1202 action is carried out
1203 successfully and <b>1</b> if any error occurs.<br>
1204 <br>
1205 The calling signature of the script is the following:<br>
1206 <b><font color="#000000">&lt;product_script_name&gt;
1207 &lt;function_name&gt; &lt;target_directory&gt;
1208 &lt;temp_folder&gt;</font></b>
1209 <p><font color="#000000">where</font> <br>
1210 </p>
1211 <p><font color="#000000"><b>&lt;product_script_name&gt;</b>
1212 -
1213 the script name itself (retrieved from the XML configuration xml
1214 file);</font> <br>
1215 <font color="#000000"><b>&lt;function_name&gt;</b>
1216 - the name of the function;</font> <br>
1217 <font color="#000000"><b>&lt;target_directory&gt;</b>
1218 - the root target
1219 directory where the product is
1220 installed to;</font> <br>
1221 <font color="#000000"><b>&lt;temp_folder&gt;
1222 </b> - the directory for the temporary files.</font> <br>
1223 <br>
1224 <b>Note:</b> The standard Installation Wizard buttons
1225 "Launch
1226 SALOME" and "Release Notes" are implemented with this
1227 feature. Refer to the scripts <b>start_salome.sh</b> and
1228 <b>release_notes.sh</b> for the sample implementation.<br>
1229 <br>
1230 <b>Note:</b> Any button (even standard) can be ignored by
1231 the
1232 Installation Wizard if the attribute <b>&lt;disable&gt;</b>
1233 in the XML
1234 configuration file is set to the "true" value.
1235 </p>
1236 <hr><br>
1237 </font></body>
1238 </html>