Create a Reproducible Build Environment#

Objective#

Create a reproducible development environment that can be recreated on another machine.

Step 1. Install Silicon Labs Tool (SLT)#

Download and install SLT for your platform. For installation instructions, see First-Time Installation and Setup.

Step 2. Create a Recipe File (pkg.slt)#

Create a pkg.slt file that defines the SDKs and tools required for the project:

version = "0"

[dependency]
### Required SDK
simplicity-sdk="~"

### Optional SDK Extensions
aiml="~"
sidewalk="~"
matter_extension="~"
wiseconnect="~"

### Required Tools
cmake = "~"
commander = "~"
exx32 = "~"
gcc-arm-none-eabi = "~"
ninja = "~"
sdm = "~"
slc-cli = "~"
zap = "~"

Step 3. Install All Packages#

For more information, see Set Up Your Development Environment.

Install using the default pkg.slt recipe file:

slt install

Use a custom recipe file:

slt install -f myrecipe.slt

Step 4. Share the Lock File#

The pkg.lock file records the exact package versions that were installed. Share this file with your team or use it in your continuous integration/continuous delivery (CI/CD) pipeline to reproduce the same development environment.

slt install -f pkg.lock

Step 5. Configure the Project#

Edit the user.slconf file to define project settings.

[slc]
sdk-package-path = ["/path/to/simplicity_sdk"]
project-file = "path/to/example.slcp"
with = ["brd4403b"]
output-type = "cmake"
copy-sources = "TRUE"
new-project = "TRUE"
toolchain = "gcc"

Note: user.slconf automatically includes autogen/pkg.slconf, which provides all tool and SDK paths.

Step 6. Generate the Project#

Generate the project by using the user.slconf file.

slc generate --slt-config=user.slconf -d=output/my_project