-
Notifications
You must be signed in to change notification settings - Fork 0
/
INSTALL
37 lines (29 loc) · 1.61 KB
/
INSTALL
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
INSTALL GUIDE FOR C3P Compiler
========================================
0. Introducction
This guide explains how to prepare and install the c3p compiler
on your machine in order to be able to compile c3p source files.
Since this compiler is just a prototype, this file won't be useful
until the repository includes a Makefile at the same path of this file.
Besides, this compiler would only be supported at Linux machines or WSL
terminals, since Makefile uses Linux commands.
1. Requirements
Before the installation of the c3p compiler, you may need to
check that Make, GNU C Compiler, Flex, and Bison are installed
at your machine. Note that the compiler needs these tools.
2. Installation
To generate the compiler, please execute "make -s" at the working
directory on which you have downloaded this repository. In order
to know if the installation was a sucess, check that an executable
called "c3pc" has been created. It is important to notice that you
can move this executable at any location of your machine, but take
into account that PATH global variable must be modified in order to
execute the compiler with just its name. Besides, iq executable, and
Qlib.h header file must be located at the same path of the compiler.
3. Compilation
Now that you have the c3p compiler prepared, you can compile a c3p
file executing the command "c3pc <C3P_FILE>". If everything was ok,
you should see at the working directory of the c3p file two files
called "<FILE>.exe" and "<C3P_FILE>.q.c". It is important to notice
that execution would be a success whether these two files are always
at the same path, so do not move them after the compilation.