How To Install ComenC
From ClearSy Tools
- Download the ComenC archive file [1]. Unzip it and untar it in the directory you want to install it in (referred to <ComenC_install_dir>)
- Download the library AdaCocktail 3.13 [2].
Unzip it and untar it in the / directory, as root.
User> cd / User> sudo tar xvf ~/libAdaCocktail.tar usr/lib/libAdaCocktail-3.13p.so.1 usr/lib/libAdaCocktail-3.13p.so.1.1
- Download the library Gnat 3.13 [3].
Unzip it and untar it in the / directory, as root.
User> sudo tar xvf ~/libgnat-3.13.tar usr/lib/libgnat-3.13p.so.1 usr/lib/libgnat-3.13p.so.1.7
- Modify the comenc/bin/bpp.sh script file.
At the beginning of the file, the variable is defined as:
BIN_RED=`pwd`
Modify this line to point to the location of b2c and bpp binary file. For example:
BIN_RED=/home/comenc/bin/linux
- Launch the ComenC translator to verify if it is properly installed. You should get the following messages:
User> ComenC/bin/linux/b2c
b2c: erreur: missing option 'i'
b2c: erreur: missing option 'C'
b2c: erreur: missing option 'p'
b2c: erreur: missing option 'b'
Usage: b2c options
B to C Translator, Copyright ClearSy 2007
Version V1.0 (08/08/2007)
-i <comp> : component to translate (either an implementation or a basic machine) without extension
-C <out_dir> : output directory
-p <proj_fil> : file describing the components list
<component_name> <file_path>
-b : path of the B preprocessor script (bpp.sh)
-h : display this message
-I : display the translator version
-1 : stop after syntactic analysis
-2 : stop after semantic analysis
-g : generate debug information, dump syntactic and semantic trees