Configure Sources and Build Options
If you use a build command such as make or cmake for building your source code, or if you are able to generate a JSON compilation database using your build system, you can create a Polyspace® Platform project from the build command or compilation database. The source files and build options in the Polyspace Platform project are determined from the compiler invocations in the build command or compilation database.
Otherwise, set options explicitly in your build configuration. Specifying your compiler for the option Compilation toolchain (Static Analysis) enables the analyzer to recognize compiler-specific keywords. Work around any build related analysis errors using options such as Preprocessor definitions (-D) or Command/script to apply to preprocessed files (-post-preprocessing-command).
Functions
polyspace-configure | (System Command) Create Polyspace Platform project, workspace, or options file from build command or compilation database |
Polyspace Options
Topics
Get Started
- Configure Sources and Build Options in Project for Polyspace Analysis and Testing
Set build options in Polyspace project configuration, generate source paths and build options using build command or compilation database. - Information Gathered From Build Systems for Polyspace Analysis and Testing
Learn what information is extracted when you trace your build command to create a Polyspace Platform project.
Configure Options Using Build Commands
- Create Polyspace Platform Project From Build Command in User Interface
Create a project in the Polyspace Platform user interface from a working build command or compilation database. - Requirements for Polyspace Project Creation from Build Systems
Learn why automatic Polyspace project creation might not work for your build system and how to work around some of the causes. - Select Files for Polyspace Project Using Pattern Matching
Select files to include in Polyspace project or options file using expressions with glob patterns. - Create Polyspace Platform Projects from Builds That Use Makefiles
Reuse build information in makefiles for Polyspace analysis and testing. - Modularize Polyspace Projects by Using Makefile Builds
Create a separate Polyspace project or options file for each binary in makefile build. - Create Polyspace Platform Projects From IDE Builds
Specify source files and configuration options by tracing your Visual Studio® build. - Create Polyspace Platform Projects from CMake Builds
Reuse build information in CMakeLists files for Polyspace analysis and testing.
Configure Options Manually
- Configure Sources and Build Options in Project for Polyspace Analysis and Testing
Set build options in Polyspace project configuration, generate source paths and build options using build command or compilation database. - Provide Standard Library Headers for Polyspace Analysis
Find paths to C or C++ standard library headers from your compiler and specify the paths in your Polyspace project. - Remove or Replace Keywords Before Compilation
Replace or remove keywords from preprocessed code to avoid compilation errors. - Gather Compilation Options Efficiently for Polyspace Analysis
Put workarounds for compilation errors into a single file and include that file in analysis. - Static Analysis Target Specification for Common Processors
This topic lists the target configurations for Polyspace static analysis of C/C++ code tailored for common processor families.
Support for C/C++ Language Standards and Extensions
- C/C++ Language Standard Used in Polyspace Analysis
See supported language standards and the default standard used in Polyspace analysis.
- Keil or IAR Language Extensions Supported with Polyspace
Find which Keil or IAR-specific extensions of the C language standard are supported for verification.