Set Up Polyspace Project

Tutorial Overview

In this tutorial, you create a Polyspace® project to verify Ada code.

What Is a Project?

A Polyspace project consists of:

  • Source folders and their files.

  • Include folders.

  • One or more modules. You run verification on the source files in each module. Each module has the following folders:

    • Source — Contains files used for verification.

    • Configuration — Contains analysis options used for verification.

    • Result — Contains results of verification.

Prepare Project Folder

In the following procedures, Polyspace_Install is the Polyspace installation folder, for example, C:\Program Files\Polyspace\.

  1. Create a folder polyspace_project in a particular location, for example C:\.

  2. Open polyspace_project and create subfolders:

    • sources

    • includes

  3. Copy example.adb and from Polyspace_Install\polyspace\examples\ada\Demo_Ada_Single-File\sources to polyspace_project\sources.

  4. Copy the files from Polyspace_Install\polyspace\examples\ada\Demo_Ada_Single-File\sources to polyspace_project\includes.

Open Polyspace Verification Environment

  • Windows®: From the Polyspace_Install\polyspace\bin folder, double-click the polyspace executable.

  • Linux® or Mac: Run the following command:


For project setup, you can use the following panes in the Polyspace user interface here.

SectionUse For
Project BrowserSpecifying:
  • Source files

  • Include folders

  • Results folder

ConfigurationSpecifying analysis options
Output SummaryMonitoring the progress of a verification, and viewing status, log messages, and general verification statistics.

You can resize or hide sections.

Create Project

Create New Project

  1. Select File > New Project.

  2. In the Project – Properties dialog box:

    • For Project name, enter polyspace_project.

    • Clear the Use default location check box. To specify where your polyspace_project folder is, click .

    • Clear the boxes under Project Configuration.

      For more information on the option Use template, see Create Project Using Template.

  3. Click Next.

Specify Source Files and Include Folders

  1. Use the Browse button to select the sources folder that you created.

  2. Click Add Source Folder, then click Next.

  3. Use the Browse button to select the includes folder that you created.

  4. Click Add Include Folders, then click Finish.

You can see your project in the Project Browser.

Next Steps

  1. Run Verification

  2. Review Verification Results

Was this topic helpful?