-
Notifications
You must be signed in to change notification settings - Fork 17
Running the barectf command line tool
Using the barectf
command-line utility is easy. In its simplest form,
it outputs a CTF metadata file and a few C files out of a
YAML configuration file:
barectf config.yaml
will output, in the current working directory:
-
metadata
: CTF metadata file -
barectf-bitfield.h
: macros used by tracing functions to pack bits -
barectf.h
: other macros and prototypes of context/tracing functions -
barectf.c
: context/tracing functions
barectf_
is the default name of the files and the default prefix of
barectf C functions and structures. The prefix is read from the
configuration file, but
you may override it on the command line:
barectf --prefix=my_app_ config.yaml
You may also output the files elsewhere:
barectf --code-dir=src --headers-dir=include --metadata-dir=ctf config.yaml
By default, barectf
searches for relative
included YAML files
in the current working directory, and then in
the provided include directory
if not found.
Other directories can be searched into before searching those default
directories thanks to the -I
option, which can be repeated:
barectf -I /path/to/includes -I ~/my-includes -I project/include config.yaml
Copyright © 2014-2016 Philippe Proulx (project license)