Commit | Line | Data |
---|---|---|
af710487 | 1 | ****************************************************************************** |
d44e3c4f | 2 | * Copyright (c) 2000-2016 Ericsson Telecom AB |
af710487 | 3 | * All rights reserved. This program and the accompanying materials |
4 | * are made available under the terms of the Eclipse Public License v1.0 | |
5 | * which accompanies this distribution, and is available at | |
6 | * http://www.eclipse.org/legal/epl-v10.html | |
d44e3c4f | 7 | * Contributors: |
8 | * Balasko, Jeno | |
9 | * Baranyi, Botond | |
10 | * Lelik, Elemer | |
11 | * Pilisi, Gergely | |
12 | * Szabados, Kristof | |
af710487 | 13 | ****************************************************************************** |
14 | ||
15 | Build and install Titan on Linux | |
16 | ||
17 | 1.Install required libraries: | |
18 | (examples are given for Ubuntu 12.04/14.04; for other Linuxes, pls. use the relevant library installation method) | |
19 | ||
20 | sudo apt-get install g++ expect libssl-dev libxml2-dev libncurses5-dev flex bison | |
21 | xutils-dev is needed by makedepend: | |
22 | sudo apt-get install xutils-dev | |
23 | The following packages may be needed for titan_eclipse/automatic_build: | |
24 | sudo apt-get install ant xsltproc | |
25 | ||
3abe9331 | 26 | 2.Clone the titan directory from git into /home/<user_id>/titan.core |
af710487 | 27 | |
3abe9331 | 28 | git clone https://github.com/eclipse/titan.core titan.core |
af710487 | 29 | |
30 | 3. Configure the build | |
31 | ||
3abe9331 | 32 | cd titan.core |
e94191bf EL |
33 | |
34 | For open source users: check that MakefileFOSS.cfg is present and has the following content: | |
af710487 | 35 | cat MakefileFOSS.cfg |
36 | ||
37 | # Configurations for the Free Open Source Software version | |
38 | LICENSING := no | |
39 | USAGE_STATS := no | |
40 | ||
e94191bf EL |
41 | If you want to use your build within teh Ericsson domain: delete MakefileFOSS.cfg |
42 | This will enable licensing. | |
af710487 | 43 | |
ef855bc1 | 44 | Several build options are possible; for details on options please read through the Makefile.cfg. |
af710487 | 45 | Options can be overridden by the content of a file named Makefile.personal which can be used to |
46 | adapt to local installation directories, change config options etc. | |
47 | Below, a small number of typical scenarios are presented. | |
48 | ||
e94191bf | 49 | a) JNI disabled, gcc compiler (default) |
af710487 | 50 | |
51 | The JNI interface is used by the Eclipse Titan Executor or by the Java Executor API. | |
52 | If you don't need them , Titan can be compiled without JNI. | |
53 | ||
3abe9331 | 54 | Create ~/titan.core/Makefile.personal to override settings in Makefile.cfg with the following content: |
af710487 | 55 | (replace paths with values relevant to your installation) |
56 | ||
3abe9331 | 57 | TTCN3_DIR := /home/<user id>/titan.core/Install |
af710487 | 58 | OPENSSL_DIR := /usr |
59 | #JDKDIR := /usr/lib/jvm/java-7-openjdk-amd64 | |
60 | XMLDIR := /usr | |
61 | JNI := no | |
62 | GEN_PDF := no | |
63 | ||
e94191bf EL |
64 | b) JNI disabled, clang compiler ver. 3.8 |
65 | ||
66 | Create ~/titan.core/Makefile.personal to override settings in Makefile.cfg with the following content: | |
67 | (replace paths with values relevant to your installation). | |
af710487 | 68 | |
e94191bf EL |
69 | TTCN3_DIR := /home/<user id>/titan.core/Install |
70 | OPENSSL_DIR := /usr | |
71 | #JDKDIR := /usr/lib/jvm/java-7-openjdk-amd64 | |
72 | XMLDIR := /usr | |
73 | JNI := no | |
74 | GEN_PDF := no | |
75 | CXX := clang++-3.8 | |
76 | CC := clang-3.8 | |
af710487 | 77 | |
78 | ||
e94191bf | 79 | c) JNI enabled, gcc compiler (default) |
af710487 | 80 | |
81 | install JDK into /home/<user id>/jdk | |
82 | ||
3abe9331 | 83 | Create ~/titan.core/Makefile.personal to override settings in Makefile.cfg with the following content: |
e94191bf | 84 | (replace paths with values relevant to your installation). |
af710487 | 85 | |
3abe9331 | 86 | TTCN3_DIR := /home/<user id>/titan.core/Install |
af710487 | 87 | OPENSSL_DIR := /usr |
88 | JDKDIR := /usr/lib/jvm/java-7-openjdk-amd64 | |
89 | XMLDIR := /usr | |
90 | JNI := yes | |
91 | GEN_PDF := no | |
92 | ||
93 | ||
94 | ||
f99e8b7f | 95 | 4. Run make |
af710487 | 96 | |
97 | make | |
98 | ||
f99e8b7f | 99 | 5. Set environment variables |
af710487 | 100 | |
3abe9331 | 101 | setenv TTCN3_DIR /home/<user id>/titan.core/Install |
775259be EL |
102 | setenv PATH /home/<userid>/titan.core/Install/bin/:${PATH} |
103 | setenv LD_LIBRARY_PATH /home/<userid>/titan.core/Install/lib:${LD_LIBRARY_PATH} | |
af710487 | 104 | |
775259be | 105 | for csh |
60f48d67 | 106 | |
775259be | 107 | or |
60f48d67 | 108 | |
3abe9331 | 109 | export TTCN3_DIR=/home/<user id>/titan.core/Install |
775259be EL |
110 | export PATH=/home/<userid>/titan.core/Install/bin/:${PATH} |
111 | export LD_LIBRARY_PATH=/home/<userid>/titan.core/Install/lib:${LD_LIBRARY_PATH} | |
60f48d67 | 112 | |
775259be | 113 | for bash |
60f48d67 | 114 | |
f99e8b7f | 115 | 6. Run make install |
60f48d67 | 116 | |
775259be | 117 | make install |
60f48d67 | 118 | |
3abe9331 | 119 | This will install Titan into /home/<user id>/titan.core/Install |
af710487 | 120 | |
121 | ||
d44e3c4f | 122 | 7. Optionally , run function/regression tests |
af710487 | 123 | |
3abe9331 | 124 | cd /home/<user id>/titan.core/function_test |
af710487 | 125 | |
126 | in the following Makefiles | |
127 | ||
3abe9331 | 128 | BER_EncDec/Makefile |
af710487 | 129 | XER_EncDec/Makefile |
130 | Text_EncDec/Makefile | |
131 | RAW_EncDec/Makefile | |
132 | ||
133 | edit the value of XMLDIR to match your installation values | |
134 | ||
135 | run the tests | |
136 | ||
137 | make | |
138 | ||
139 | ( or make |& tee outputfile if you want to save the output for verification) | |
140 | ||
3abe9331 | 141 | cd /home/<user id>/titan.core/regression_test |
af710487 | 142 | make run |
143 | ||
144 | ( or make run |& tee outputfile if you want to save the output for verification) | |
145 | ||
146 | These tests might run for half an hour (regr.tests) to two hours (func.tests) | |
147 | ||
e79e2f13 | 148 | 8. Optionally, copy Titan into its final directory. |
97cee3b0 | 149 | From here on, you can continue with the Titan installation guide, see /Install/docs, to set/change environment variables etc. |
af710487 | 150 |