README.linux 3.02 KB
Newer Older
Elemer Lelik's avatar
Elemer Lelik committed
1
2
3
4
5
6
7
8
9
10
11
12
13
Build and install Titan on Linux

1.Install required libraries: 
(examples are given for Ubuntu 12.04/14.04; for other Linuxes, pls. use the relevant library installation method)

sudo apt-get install g++ expect libssl-dev libxml2-dev libncurses5-dev flex bison
xutils-dev is needed by makedepend:
sudo apt-get install xutils-dev
The following packages may be needed for titan_eclipse/automatic_build:
sudo apt-get install ant xsltproc

2.Clone the titan directory from git  into /home/<user_id>/titan

Elemer Lelik's avatar
Elemer Lelik committed
14
15
git clone https://github.com/eclipse/titan.core  titan

Elemer Lelik's avatar
Elemer Lelik committed
16
3. Configure the build 
Elemer Lelik's avatar
Elemer Lelik committed
17

Elemer Lelik's avatar
Elemer Lelik committed
18
19
20
21
22
23
24
25
26
27
cd titan
check  that MakefileFOSS.cfg is present   and  has the following content:
cat MakefileFOSS.cfg

# Configurations for the Free Open Source Software version
LICENSING := no
USAGE_STATS := no


Several build options are possible; for details on options , please read through the Makefile.cfg.
Elemer Lelik's avatar
Elemer Lelik committed
28
29
Options can be overridden by the content of  a file named Makefile.personal which can be used to 
adapt to local installation directories, change config options etc.
Elemer Lelik's avatar
Elemer Lelik committed
30
31
32
33
34
Below, a small number of typical scenarios are presented.

1) JNI  disabled

The JNI interface is used by the Eclipse Titan Executor or by the Java Executor API.
Elemer Lelik's avatar
Elemer Lelik committed
35
If you don't need them , Titan can be compiled without JNI. 
Elemer Lelik's avatar
Elemer Lelik committed
36
37

Create ~/titan/Makefile.personal to override settings in Makefile.cfg with the following content:
Elemer Lelik's avatar
Elemer Lelik committed
38
(replace paths with values relevant to your installation)
Elemer Lelik's avatar
Elemer Lelik committed
39
40

TTCN3_DIR := /home/<user id>/titan/Install
Elemer Lelik's avatar
Elemer Lelik committed
41
42
43
OPENSSL_DIR := /usr
#JDKDIR := /usr/lib/jvm/java-7-openjdk-amd64
XMLDIR := /usr
Elemer Lelik's avatar
Elemer Lelik committed
44
JNI := no
Elemer Lelik's avatar
Elemer Lelik committed
45
GEN_PDF := no
Elemer Lelik's avatar
Elemer Lelik committed
46
47
48
49
50
51
52
53
54




2) JNI  enabled

install JDK   into /home/<user id>/jdk

Create ~/titan/Makefile.personal to override settings in Makefile.cfg with the following content:
Elemer Lelik's avatar
Elemer Lelik committed
55
(replace paths with values relevant to your installation)
Elemer Lelik's avatar
Elemer Lelik committed
56
57

TTCN3_DIR := /home/<user id>/titan/Install
Elemer Lelik's avatar
Elemer Lelik committed
58
59
60
OPENSSL_DIR := /usr
JDKDIR := /usr/lib/jvm/java-7-openjdk-amd64
XMLDIR := /usr
Elemer Lelik's avatar
Elemer Lelik committed
61
JNI := yes
Elemer Lelik's avatar
Elemer Lelik committed
62
GEN_PDF := no
Elemer Lelik's avatar
Elemer Lelik committed
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85



3. Run make

make

4. Run make install

make install

This will install Titan into  /home/<user id>/titan/Install

5. Optionally , run function/regression tests

set environment variable TTCN3_DIR to /home/<user id>/titan/Install

(setenv  TTCN3_DIR /home/<user id>/titan/Install  for csh,
export TTCN3_DIR=/home/<user id>/titan/Install for bash )



cd /home/<user id>/titan/function_test
Elemer Lelik's avatar
Elemer Lelik committed
86
87
88
89
90
91
92
93
94
95
96

in the following Makefiles 

XER_EncDec/Makefile
Text_EncDec/Makefile
RAW_EncDec/Makefile

edit the value of XMLDIR to match your installation values 

run the tests

Elemer Lelik's avatar
Elemer Lelik committed
97
98
99
make

( or make |& tee outputfile if you want to save the output for verification)
Elemer Lelik's avatar
Elemer Lelik committed
100

Elemer Lelik's avatar
Elemer Lelik committed
101
102
cd /home/<user id>/titan/regression_test
make run
Elemer Lelik's avatar
Elemer Lelik committed
103

Elemer Lelik's avatar
Elemer Lelik committed
104
105
106
107
108
109
110
111
112
113
( or make run |& tee outputfile if you want to save the output for verification)

These tests might run for half an hour (regr.tests)  to two hours (func.tests)

6. Optionally , copy Titan into its' final directory.
From here on, you can continue with the Titan installation guide, see /Install/docs, to set environment variables etc.