package FrontC
All checked builds passInstall
dune-project
Dependency
Authors
Maintainers
Sources
sha256=f70063a72a39cb9192069ce3b1a20dd28f7e1c2ef6a56bbfbf7079533f2210e4
md5=08e58fa6c9eb311b03c0b85d74d2e256
Description
FrontC provides a C parser and an OCaml definition of an abstract syntax treee for the C language. It also includes AST pretty-printers in plain and XML formats.
README
FrontC v4.0
FrontC is C language front-end. It provides the program in "C Abstract Form", a tree representation of the original C source. It may be used for many source works including:
- compilation,
- source pre-processing,
- source beautification,
- source analysis,
- and so on.
It provides also an XML back-end making easier to transform the C program using XML tools like XSLT (it was my first goal when I perform this task).
ctoxml
The ctoxml package provides a
calipso
The calipso package provides a program analysis tool that removes non-structural control-flow from C programs. See https://dblp.org/rec/journals/tsi/CasseFRS02 for more details. The tool provides two binaries, calipso and calipso_stat
FrontC v3.0 (stable)
The stable branch supports only ANSI C (C89) with partial support for some GNU extensions. This branch is using ocamlyacc as a parser generator and doesn't accept new features, only occasional bug fixes.
Building and Installing
The easiest option is to install using opam, e.g.,
opam install FrontC # or calipso, or ctoxmlThe command above will install the latest version of the package from the ocaml.org opam-repositor. To get the current development (not yet released to ocaml.org) version of a package, you can use the opam pin command, e.g.,
opam pin FrontC --dev-repoYou can also just clone this repo and do
make && make install # translates to `dune build && dune install`If you change anything do not forget to run tests with make test.
Documentation
You can easily get the documentation using odig,
odig doc FrontC
Dev Dependencies (1)
-
odoc
with-doc
Used by (3)
-
bap-frontc
>= "2.3.0" - calipso
- ctoxml
Conflicts
None
Build status
Results of building FrontC with each compiler on check.ci.ocaml.org, run of against opam-repository 7cdc698. All results for this package.
Each result links to its build log. To keep crawlers from overloading the site, build logs require a GitHub sign-in (see ocurrent/opam-health-check). On your first log, GitHub asks you to “Authorize opam-health-check”, the OCurrent app that runs these checks; it sees only your public profile, not your repositories. The sign-in lasts 30 days.
| Version | OCaml 4.11 | OCaml 4.14 | OCaml 5.2 | OCaml 5.4 | OCaml 5.5 |
|---|---|---|---|---|---|
| 4.1.0 (this version) | good | good | good | good | good |
- good Package successfully built
- partial One of the dependencies failed to build
- bad Package failed to build
- n/a Package is not available in this environment
- internal Internal failure