Both of these arguments improve the workflow with rtags.
--macro (-m) appends a list of predefined compiler macros to the end of
"arguments" section in compilation database.
This argument is useful when working with codebase that has a lot of
directives like these:
#if defined(__arch1__) || defined(__arch2__)
If they are not explicitly defined, the code in those #ifs
won't be added to the rtags database.
--full-path searches the user's $PATH for the compiler executable and in
case it's found, replaces the executable name with the full path to
executable in "arguments" section in compilation database.
This argument allows to specify the compiler path only once, when
calling compiledb, like so:
PATH=/opt/buildroot/bin:$PATH compiledb --full-path make
After that no additional configuration is needed for
rtags and one rdm service can be used to handle separate projects with
separate compilers in separate PATHs.
Both of these arguments improve the workflow with rtags.
--macro
(-m
) appends a list of predefined compiler macros to the end of "arguments" section in compilation database.This argument is useful when working with codebase that has a lot of directives like these:
#if defined(__arch1__) || defined(__arch2__)
If they are not explicitly defined, the code in those#if
s won't be added to the rtags database.--full-path
searches the user's$PATH
for the compiler executable and in case it's found, replaces the executable name with the full path to executable in "arguments" section in compilation database.This argument allows to specify the compiler path only once, when calling
compiledb
, like so:PATH=/opt/buildroot/bin:$PATH compiledb --full-path make
After that no additional configuration is needed forrtags
and onerdm
service can be used to handle separate projects with separate compilers in separatePATH
s.