Create and Build System Project - Create and Build System Project - 2026.1 English - UG1702

Vitis Reference Guide (UG1702)

Document ID
UG1702
Release Date
2026-06-23
Version
2026.1 English

The Vitis Unified IDEsupports Python APIs to create and build a system project.

After building the AI Engine component and HLS component, Vitis builds the system project. The project has a binary container. Add components such as AI Engine and HLS component to the binary container. Update the configuration file to ensure you declare the appropriate v++ linking directives and connections under the Connectivity section.

By default, the system project build considers the config file that Vitis generated. If you want to use a custom configuration file, remove the default one. To use a custom config file to build the system project, follow the steps below:
  1. Remove configuration file: remove_cfg_files([<config_file.cfg>],'<binary_container_name>')
  2. Add custom configuration file: add_cfg_files(['custom_config_file.cfg'],name='<container_name>')
Building the system project (v++ linking) through the Python API builds all the components in the binary container, and also builds the system.
Table 1. Python APIs: System Project
Python API Description Python API Example
create_sys_project Creates a system project for the template. 1 proj = client.create_sys_project(name='system_project', platform=<platform_path>)
add_container Adds a binary container with given modules, and config files. proj.add_container(name='system_prj_lab1')
add_component Adds the specified component to the given system project

proj.add_component(name='aie_component', container_name=['system_prj_lab1'])

proj.add_component(name='hls_component', container_name=['system_prj_lab1'])

set_value Sets the value of the key in a specific section of a config file. Vitis removes earlier values for the key. HLS uses the same value.

cfg.set_value(key='save-temps', value='1')

cfg.set_value(key='export_archive', value='1')

add_values Adds more repeated values for the key in a specific section of a config file. This adds one key=value assignment for each value. Does not remove earlier values for the key.

cfg.add_values(section='connectivity', key='sc', values=['mm2s_1.s:ai_engine_0.DataIn1'])

cfg.add_values(section='connectivity', key='sc', values=['ai_engine_0.DataOut1:s2mm_1.s'])

remove_cfg_files Remove configuration files from the component proj.remove_cfg_files(['<config_file.cfg>'],'<container_name>')
add_cfg_file Adds configuration files to the component proj.add_cfg_files(['<config_file.cfg>'], name='<container_name>')
build Initiates the build of a system project for the given build target proj.build(target='hw')
  1. Does not support accelerated flows for the Embedded installer.
The following is the Python script to create a system project and build for target=Hardware to export Vitis metadata archive.
# Add package: Vitis Python CLI
import vitis

# Create a Vitis client object -
client = vitis.create_client()

# Set Vitis Workspace
client.set_workspace(path=<workspace_location>)

# Create system project
proj = client.create_sys_project(name='system_project', platform=platform_path)
# Add a binary container, and add components to it
proj.add_container(name='system_prj_lab1')
proj.add_component(name='aie_component',  container_name=['system_prj_lab1'])
proj.add_component(name='mm2s', container_name=['system_prj_lab1'])
proj.add_component(name='s2mm', container_name=['system_prj_lab1'])
# Populate the link config file
cfg = client.get_config_file(proj.project_location+'/hw_link/system_prj.cfg')
cfg.set_value(key='debug', value='1')
cfg.set_value(key='save-temps', value='1')
cfg.set_value(section='advanced', key='param', value='compiler.addOutputTypes=hw_export')
cfg.add_values(section='connectivity', key='sc', values=['mm2s_1.s:ai_engine_0.DataIn1'])
cfg.add_values(section='connectivity', key='sc', values=['ai_engine_0.DataOut1:s2mm_1.s'])

# Build System Project
proj.build(target='hw')
After building the system project, see the generated output at the following location.
workspace>system_project>build>hw>hw_link