The software is still pre-alpha quality. Use at your own risks.
igcc is an interactive shell for C development, which can be utilized like REPL (Read-Eval-Print-Loop) for dynamic languages such as Lisp. It would be useful for testing new libraries or learning C language. igcc is basically a thin wrapper around gcc, which invokes the compiler for each lines. Its features and limitations are listed below:
Features
- written in less than 400 lines of bash script
- line editting with GNU Readline
- some useful commands
- tab-completion of keywords and commands
Limitations
- do not support C preprocessor directives
- getting user input in C does not work correctly
- multiple lines are not allowed as input (use
:edit
instead)
- Bourne-again shell (bash) > 4.2
- GCC > 4.9
Just put the script (igcc) into anywhere included in PATH.
Usage: igcc [options]
Options:
-h, --help show this help and exit.
-v, --version show version info and exit.
-std <standard> specify c dialect.
gnu11@(igcc)> :help
:clear clear history and reset environment.
:edit invoke vi.
:exit exit igcc.
:help show this help.
:include <header> add header file.
:lib <library> add shared library to be linked.
:load <file> restore enviroment from <file>.
:save <file> save current environment into <file>.
:show show history.
! <command> excute shell command.
If source-highlight
is available on your system, :show
uses it to highlight history.
Also, if indent
is available, it is used to format history.
- CINT - a C/C++ interpreter which supports ANSI-C
- Cling - a C++ interpreter built on the top of LLVM and Clang
- PicoC - a small C interpreter, comes with REPL
- TCC - an embedable C compiler
Distributed under GPLv3