Building on Linux#
This guide shows how to build a SAMSON Extension on Linux with Qt Creator and CMake.
Use it after you have already installed the SDK and generated an extension workspace. The goal is to configure the root CMake project, build the install target, and run the matching SAMSON executable from the IDE.
Requirements#
If you have not installed the SAMSON SDK yet, complete Installation first.
- gcc/g++ 5.4 or newer
- CMake 4.0 or newer
- Qt 6.10.2
- Qt Creator or another IDE you prefer
Qt Creator is the workflow described below because it matches the generated project layout and the Qt-based extension workflow well.
Configuration of a project in Qt Creator#
Open Qt Creator and choose Open Project... or File > Open File or Project... (Ctrl+O).
Select the root CMakeLists.txt file in the extension workspace. Use the root workspace file, not the CMakeLists.txt inside one specific extension folder.

Configure Project#
- Choose the default kit, for example Desktop Qt 6.10.2 GCC 64 bit.
- Expand Details.
- Configure both build directories:
-
Debug:PathToExtensions/build/Debug-Release:PathToExtensions/build/Release - Click Configure Project.

You may see errors initially because CMake variables still need to be added. Switch to Projects mode (Ctrl+5) to finish the configuration.
Build Settings#
CMake configuration#
Add the variables that the generated extension workspace expects:
- Add a string variable named
SAMSON_SDK_PATHand set it to:$HOME/OneAngstrom/SAMSON-Sdks/11.0.0 - Add a boolean variable named
DEBUG. - Set it toONfor theDebugconfiguration - Leave itOFFfor theReleaseconfiguration - Click Re-configure with Initial Parameters and confirm the reconfiguration.

Build Steps#
To ensure the built extension is installed automatically:
- Scroll to Build Steps
- Expand the step details
- Enable the
installoption

Build#
Open the Edit view to inspect the project tree, then build the project with Ctrl+B or Build > Build Project "SAMSON-Elements".
Checkpoint:
- the build finishes successfully
- the
installstep runs - the extension is copied into the correct SAMSON location
Note
Building the install target automatically builds the project if needed.
Note
If the extension does not compile, you may need the 64-bit development and static packages for libstdc++.
Run Settings#
Debug and Release extensions must be run against different SAMSON executables:
Debug: the SAMSON Debug executable from the SDKRelease: the normal SAMSON application executable
In Projects mode (Ctrl+5), create one run configuration for each build configuration and set the executable:
$HOME/OneAngstrom/SAMSON-Sdks/11.0.0/SAMSON-Debug/Binaries/SAMSON-Core-Console
$HOME/Applications/SAMSON.app/11.0.0/Binaries/SAMSON-Core-Console
Important
Replace $HOME with the actual path to your user directory.
Then set the environment variables needed to locate Qt and SAMSON runtime libraries:

Run#
Once the run settings are configured:
- build with Ctrl+B
- run with Ctrl+R
- verify that SAMSON starts and your extension is loaded
Tip
If you use Debug for both build and run, you can set breakpoints and debug the extension directly from Qt Creator.
Adding files to a SAMSON Extension#
When you add or remove source files, classes, or resources, regenerate the project by:
- rerunning CMake, or
- making a small change to the relevant
CMakeLists.txtfile and letting Qt Creator trigger reconfiguration automatically on the next build
Adding new SAMSON Extensions to the project#
If you generate new extensions in the same workspace, the Extension Generator updates the root CMakeLists.txt through ADD_SUBDIRECTORY. The next CMake reconfiguration should add the new extension targets automatically.
Compatibility with older Linux distributions#
SAMSON supports Linux distributions with GLIBC 2.17 or newer. Check your local GLIBC version with:
If you want your extension to run on older supported Linux distributions even when you build it on a newer system, SAMSON SDK provides SBCSystemDefinitions.hpp. This header forces linking against compatibility symbols not newer than GLIBC 2.17 for selected cases.
In many extensions it is already included indirectly. If you use external code or external libraries that require it, include it explicitly:
To inspect which GLIBC symbols your extension currently depends on, run:
where UUID.so is the built extension library.
When it is useful
This matters when you build on a recent distribution but want the extension to remain loadable on older distributions with supported GLIBC versions.
Troubleshooting#
- If configuration fails, verify
SAMSON_SDK_PATHand the selected Qt kit. - If the extension builds but does not load, check that the run configuration matches the build configuration.
- If Qt Creator shows stale targets, force a CMake reconfiguration.
If you have questions or issues, use the SAMSON Connect Forum or contact us.
Next steps#
- Continue with Developing GUI for widget-based extensions.
- Continue with Publishing a SAMSON Extension once the Linux build is stable.