Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Table of Contents
maxLevel1

Info
iconfalse
titleExecutable

Verify that the executable (cpptestcli) is on $PATH. See Installation 1.

Info
iconfalse
titleIncremental Static Analysis

Anchor
Incremental Static Analysis
Incremental Static Analysis
C/C++test is optimized to minimize the impact on your development process. By reusing information collected in previous analysis runs, it can reduce the analysis time in subsequent runs. The information is stored in the .cpptest folder in your working directory (see the -workspace option).

To ensure optimal performance, avoid removing the .cpptest folder or deleting the contents of the folder.

Prerequisites

Compiler

C/C++test must be configured for use with specific C and C++ compilers and versions before you can analyze code. The configuration should reflect the original compiler and version used for building the code under test. The original compiler executable must be available on $PATH (unless it is specified with a full path). 

...

OptionEnvironment VariableDescriptionDefault

--cpptestscanOutputFile=<OUTPUT_FILE>

--cpptesttraceOutputFile=<OUTPUT_FILE>

CPPTEST_SCAN_OUTPUT_FILEDefines file to append build information to.cpptestscan.bdf

--cpptestscanProjectName=<PROJECT_NAME>

--cpptesttraceProjectName=<PROJECT_NAME>

CPPTEST_SCAN_PROJECT_NAMEDefines a suggested name of the C++test project.name of the current working directory

--cpptestscanRunOrigCmd=[yes|no]

--cpptesttraceRunOrigCmd=[yes|no]

CPPTEST_SCAN_RUN_ORIG_CMDIf set to "yes", the original command line will be executed.yes

--cpptestscanQuoteCmdLineMode=[all|sq|none]

--cpptesttraceQuoteCmdLineMode=[all|sq|none]

CPPTEST_SCAN_QUOTE_CMD_LINE_MODE

Determines the way C++test quotes parameters when preparing cmd line to run.

all: all params will be quoted

none: no params will be quoted

sq: only params with space or quote character will be quoted

--cpptestscanQuoteCmdLineMode is not supported on Linux.

all

--cpptestscanCmdLinePrefix=<PREFIX>
--cpptesttraceCmdLinePrefix=<PREFIX>

CPPTEST_SCAN_CMD_LINE_PREFIXIf non-empty and running original executable is turned on, the specified command will be prefixed to the original command line. [empty]

--cpptestscanEnvInOutput=[yes|no]

--cpptesttraceEnvInOutput=[yes|no]

CPPTEST_SCAN_ENV_IN_OUTPUT

Enabling dumps the selected environment variables and the command line arguments that outputs the file. For advanced settings use

--cpptestscanEnvFile and

--cpptestscanEnvars options.

no

--cpptestscanEnvFile=<ENV_FILE>

--cpptesttraceEnvFile=<ENV_FILE>

CPPTEST_SCAN_ENV_FILE

If enabled, the specified file keeps common environment variables for all build commands; the main output file will only keep differences. Use this option to reduce the size of the main output file. Use this option with

--cpptestscanEnvInOutput enabled.

[empty]

--cpptestscanEnvars=[*|<ENVAR_NAME>,...]

--cpptesttraceEnvars=[*|<ENVAR_NAME>,...]

CPPTEST_SCAN_ENVARSSelects the names of environment variables to be dumped or '*' to select them all. Use this option with --cpptestscanEnvInOutput enabled.*

--cpptestscanUseVariable=[VAR_NAME=VALUE,...]

--cpptesttraceUseVariable=VAR_NAME=VALUE,...]

CPPTEST_SCAN_USE_VARIABLEReplaces each occurrence of "VALUE" string in the scanned build information with the "${VAR_NAME}" variable usage.[empty]
--cpptesttraceTraceCommand=[<regexp>|<regexp>|...]CPPTEST_SCAN_TRACE_COMMANDDefines the command names that will be traced when collecting build process information. These names, specified as regular expressions, should match the original compiler/linker commands used in the build process.

...