Release coccinelle-0.2.5-rc2
[bpt/coccinelle.git] / install.txt
CommitLineData
174d1640
C
1
2 ** Compilation **
3
4You must first install a recent version of
5 - OCaml (at least 3.09.2),
34e49164 6 see http://caml.inria.fr/download.en.html
174d1640
C
7 At least, OCaml 3.11 is required to use the OCaml scripting
8 feature in the SmPL code.
9 - The Menhir parser generator (at least 20080912),
34e49164
C
10 see http://cristal.inria.fr/~fpottier/menhir/
11 (unless you got a version of the coccinelle source with
12 the SmPL parser pre-generated)
13 - Python and its development files (python-dev)
14 (unless you run configure with the --without-python option)
34e49164 15
c491d8ee
C
16On Debian/Ubuntu, install the following packages
17 - ocaml-native-compilers (or alternatively ocaml)
18 - pycaml
19 - libsexplib-camlp4-dev
20 - menhir and libmenhir-ocaml-dev
21
22
174d1640 23Then simply type
34e49164
C
24 ./configure
25 make depend
26 make
27 make install
28
b1b2de81 29
708f4980
C
30
31
32
174d1640
C
33'make' will compile the bytecode version by default. You could use
34'make all.opt' to have the optimized version. If you compile both,
35'make install' will take care of that and install both, spatch and
36spatch.opt. If you use only one of them, 'make install' will install
37the one you have compiled, either spatch ou spatch.opt, under the
38front-end spatch. You could use 'make world' to compile the bytecode
39and the optimized code version.
40
41We provide the files generated by menhir in the tarball. However,
42'make distclean' will remove them. You could either restore them from
43the tarball or install menhir. Using 'make clean' should be safe with
44regards to these files.
45
46Note: The test target is intended for developers. In particular, you
47 should not expect that every test will pass.
48
49
50 In order to use the OCaml scripting feature in SmPL, you must compile
51Coccinelle with at least OCaml version 3.11.
52
53
aba5c457
C
54
55 ** Bash integration **
56
57 To have completion under Bash, you can execute the following command:
58
59 make install-bash
60
61 It will install the shell script 'scripts/spatch.bash_completion'
62 in /etc/bash_completion.d/spatch
63
64 You can manually copy that file elsewhere if you have a different
65 bash_completion directory.
66
67
68
174d1640
C
69 ** Runtime dependencies **
70
71 - Basic shell commands:
72 - ls, cat, cp, mv, rm, grep, mkdir, find
73 - Developper tool: diff
74
75
76 ** Optional runtime dependencies **
77
78 - To quickly apply the semantic patches
79 - glimpse indexer
80
81 - To use OCaml scripting feature in SmPL
82 - ocaml-native-compilers or ocaml-nox
83 - ocaml-findlib
84
85 - To generate a PDF of the control flow graph with '-graphical_trace'
86 - pdftk and graphviz (with PDF support)
87
88
708f4980 89
174d1640 90 ** Dependencies for additional tools **
9f8e26f4 91
174d1640 92 git, pushd, popd, sed, diffstat, cpp
aba5c457
C
93
94 ** Uninstall **
95
96 To uninstall Coccinelle, you should use the following command
97
98 make uninstall
99
100
101 To also remove the bash completion script, run
102
103 make uninstall-bash