Salome HOME
For future compatibility with python 3.9.
[modules/yacs.git] / INSTALL
1 Installation Instructions
2 *************************
3
4 Specific part for YACS
5 ~~~~~~~~~~~~~~~~~~~~~~
6
7 Prerequisites
8 =============
9 YACS needs:
10  - g++ 3.3.5 or more,
11  - CPPUNIT
12  - omniORB 4.05 or more,
13  - Python,
14  - SALOME 3.2.x KERNEL (for SALOME tests)
15
16 **WARNINGS**:
17  -  with g++>= 4.1, problem with CORBA::Any and double, for omniORB <= 4.0.7
18     You need to take the latest omniORB cvs snapshot from http://omniorb.sourceforge.net/snapshots
19
20 Build and check
21 ===============
22
23 SALOME is required for directories runtime and yacsloader. For tests with make test,
24 we suppose that all SALOME <modules>_ROOT_DIR are in a directory under a name
25 <PATH_TO_ROOT_DIR>/<MODULE>_<VERSION>, for instance $HOME/SALOME/KERNEL_V3_2_3.
26 We also suppose that there a script that sets prerequisites environment for SALOME
27 under the name <PATH_TO_ROOT_DIR>/profile_<VERSION>.
28 So, to define SALOME installation, just KERNEL_ROOT_DIR is required. Other path
29 are deduced.
30
31 build and install are done in separate directories, not in source directory.
32 For instance, if the path to YACS sources is ${BASEREP}/YACS_SRC::
33
34   export KERNEL_ROOT_DIR=...
35
36   cd ${BASEREP}
37   rm -rf build install
38   mkdir build install
39
40   cd ${BASEREP}/build
41   cmake -DCMAKE_BUILD_TYPE=<Mode> -DCMAKE_INSTALL_PREFIX=${BASEREP}/install ../YACS_SRC
42   
43   Where <Mode> is build mode (Release or Debug)
44
45   make
46   make test
47
48   make install
49   
50
51 Generic part
52 ~~~~~~~~~~~~
53
54 Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005 Free
55 Software Foundation, Inc.
56
57 This file is free documentation; the Free Software Foundation gives
58 unlimited permission to copy, distribute and modify it.
59
60 Basic Installation
61 ==================
62
63 These are generic installation instructions.
64
65 The cmake command attempts to guess correct values for
66 various system-dependent variables used during compilation.  It uses
67 those values to create a `Makefile' in each directory of the package.
68
69 It is necessary to define some mandatory options, For example, option 
70 -DCMAKE_INSTALL_PREFIX sets a installation directory of project.
71 CMake command can also use an optional parameters defined in current project 
72 (For example, -DSALOME_BUILD_DOC specifies if a documentation is enable 
73 for this project or no).
74
75 The simplest way to compile this package is:
76
77   1. Before building YACS module, please ensure that SALOME environment is
78      set properly. Assume that SALOME environment is set in env_products.sh
79      script.
80      
81      source env_products.sh
82
83   2. Create a build directory of project
84   
85      mkdir YACS_BUILD
86      
87   3. go to the directory build directory
88   
89      cd YACS_BUILD
90
91   4. Invoke cmake command to configure YACS module of SALOME
92   
93     cmake -DCMAKE_BUILD_TYPE=<Mode> -DCMAKE_INSTALL_PREFIX=<YACS_module_installation_dir> ../YACS_SRC
94     
95     , where <Mode> is build mode (Release or Debug);
96     <YACS_module_installation_dir> is a destination folder to install YACS module of SALOME.
97     By default (if CMAKE_INSTALL_PREFIX option is not given), HELLO module will be 
98     configured for installation to the /usr directory that requires root permissions 
99     to complete the installation;
100     YACS_SRC is a directory containing the package's source code.
101   
102   5. Build the package
103   
104      make
105
106   6. Optionally, type `make test' to run any self-tests that come with the package.
107   
108      make test
109
110   7. Install the programs and any data files and documentation.
111   
112      make install
113
114   8. You can remove the program binaries and object files from the
115      source code directory by typing 
116      
117      make clean.  
118
119 Compilers and Options
120 =====================
121
122 Some systems require unusual options for compilation or linking.  
123 Run `cmake --help' for details on some of the pertinent environment variables.
124
125 Compiling For Multiple Architectures
126 ====================================
127
128 You can compile the package for more than one kind of computer at the
129 same time, by placing the object files for each architecture in their
130 own directory. `cd' to the directory where you want the object files 
131 and executables to go and run the `cmake' command.  CMake automatically 
132 checks for the source code in the current directory.
133
134 Installation Names
135 ==================
136
137 By default, `make install' will install the package's files in
138 `/usr/local/bin', `/usr/local/man', etc.  You can specify an
139 installation prefix other than `/usr/local' by giving `cmake' the
140 option `-DCMAKE_INSTALL_PREFIX=<install_directory>'.
141
142 In addition, if you use an unusual directory layout you can give
143 options like `-DSALOME_INSTALL_BINS=DIR' to specify different values for particular
144 kinds of files.  Run `ccmake ../<srcdir>' for a list of the directories
145 you can set and what kinds of files go in them.
146
147 `cmake' Invocation
148 ======================
149
150 `cmake' command recognizes the following options to control how it operates.
151
152 `--help'
153 `-h'
154      Print a summary of the options to `cmake', and exit.
155
156 `--version'
157 `-V'
158      Print the version of CMake.
159
160 `cmake' also accepts some other, not widely useful, options.  Run
161 `cmake --help' for more details.
162
163 You can also use command 'ccmake' which shows all options and parameters 
164 for current project; and change their if you are need.
165 For example, for YACS module of SALOME 
166    cd YACS_BUILD
167    ccmake ../YACS_SRC