Skip to content

Troubleshooting

dmeoli edited this page Jun 19, 2026 · 8 revisions

This page collects solutions to the most common problems encountered while building and running SMS++. For how to point CMake at libraries installed in non-standard locations, see Customize the configuration; for the full setup, see the installation guide.

[[TOC]]

Configuration errors

  • No CMAKE_CXX_COMPILER could be found.

    Your C++ compiler is not installed (or not found). Make sure a C++17-capable gcc or clang (Linux/macOS) or MSVC (Windows) is installed. If it is installed but not found, set the CXX environment variable or the CMAKE_CXX_COMPILER cache entry to the full path of the compiler (or its name if it is in the PATH).

  • Unable to find the requested Boost libraries.

    CMake could not locate your Boost installation. Install Boost, or point CMake at it with the matching *_ROOT variable:

    cmake .. -DBoost_ROOT="/my/custom/path/to/boost"

    The same pattern works for the other dependencies (Eigen3_ROOT, netCDF_ROOT, netCDFCxx_ROOT, …); see Customize the configuration.

  • A required package (Eigen3, netCDF, …) is not found.

    Install the missing dependency (the installation guide and the INSTALL scripts do this for you), or override its *_ROOT path as above.

  • No MILP solver is available / a Block cannot be solved.

    MILPSolver needs at least one back-end among HiGHS, SCIP, CPLEX and Gurobi. Install one (HiGHS and SCIP are open source) and, if needed, point CMake at it with HiGHS_ROOT / SCIP_ROOT / CPLEX_ROOT / GUROBI_ROOT.

Build errors

  • A module fails because the core library (or another module) is not found.

    When building modules individually, enable the User Package Registry so they find each other without installing:

    cmake .. -DCMAKE_EXPORT_PACKAGE_REGISTRY=ON

    In the umbrella project this is already on by default. See Customize the configuration.

  • A submodule directory is empty / a BUILD_* flag seems ignored.

    The umbrella builds a module only if its submodule is initialized. Fetch them with:

    git submodule update --init --recursive

    (turning a BUILD_* flag ON also triggers this automatically).

Windows / vcpkg

  • vcpkg packages are not picked up.

    Pass the vcpkg toolchain file at configure time:

    cmake .. -DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake

    Dependencies are resolved from the vcpkg.json manifest in manifest mode. See the installation guide.

  • Cannot copy output executable ... Permission denied or file INSTALL cannot find ... .exe: File exists.

    Typical offenders are getarch_2nd.exe (while building OpenBLAS) and tool executables such as bkbench.exe (at install time). This is not a vcpkg or SMS++ bug: an antivirus flags a freshly built, unsigned executable in the build tree as suspicious and locks or quarantines it, so CMake then cannot copy it. The : File exists part is a misleading leftover error; the real cause is that the file was made inaccessible.

    The fix is to exclude the whole build tree from your antivirus, namely C:\vcpkg and your SMS++ directory (e.g. C:\smspp-project). On Windows Defender, from a PowerShell as administrator:

    Add-MpPreference -ExclusionPath "C:\vcpkg"
    Add-MpPreference -ExclusionPath "C:\smspp-project"

    INSTALL.ps1 does this automatically (skip it with -withoutDefenderExclusions). With a third-party antivirus (Avast, AVG, Norton, …) Add-MpPreference fails with 0x800106ba, because Defender is in passive mode and does not control the scanner. In that case add the same two paths to the exclusion list of your own antivirus, or disable its real-time protection for the duration of the build. After excluding, delete the half-built artifacts (C:\vcpkg\buildtrees\openblas, C:\vcpkg\packages\openblas_x64-windows, your build directory), restore any quarantined .exe, and reconfigure. Building from a clean x64 Native Tools prompt with any conda environment deactivated also avoids unrelated toolchain interference.

Still stuck?

Check the Getting help section of the relevant module's README, and search or open an issue on the project tracker.

Clone this wiki locally