Specifying a registered toolchain
68 次查看(过去 30 天)
显示 更早的评论
When I attempt to build my Simulink model, I receive an error that none of the toolchains specified in C:\Program Files\MATLAB\R2024a\toolbox\coder\compile\tmf\ert_unix.tmf are in the current list of registered toolchains:
Error using coder.make.internal.TMFProps/extractToolchainAttributesFromName (line 219)
None of the toolchains, "Xcode with Clang | gmake (64-bit Mac), GNU gcc/g++ | gmake (64-bit Linux)", specified
in C:\Program Files\MATLAB\R2024a\toolbox\coder\compile\tmf\ert_unix.tmf in are in the current list of
registered toolchains, "AUTOSAR Adaptive Linux Executable, AUTOSAR Adaptive | CMake, Cadence Xcelium (64-bit
Linux), Catkin, CMake, Colcon Tools, eProsima 2.x Project, IBIS-AMI GNU gcc/g++ cross-compiler source code |
gmake (64-bit Windows), IBIS-AMI GNU gcc/g++ cross-compiler | gmake (64-bit Windows), IBIS-AMI Microsoft Visual
C++ 2017 v15.0 | nmake (64-bit Windows), IBIS-AMI Microsoft Visual C++ 2019 v16.0 | nmake (64-bit Windows),
IBIS-AMI Microsoft Visual C++ 2022 v17.0 | nmake (64-bit Windows), IBIS-AMI MinGW64 | gmake (64-bit Windows),
Intel oneAPI 2021 (w/Microsoft Visual Studio 2017) | nmake (64-bit Windows), Intel oneAPI 2021 (w/Microsoft
Visual Studio 2019) | nmake (64-bit Windows), Intel oneAPI 2022 (w/Microsoft Visual Studio 2017) | nmake
(64-bit Windows), Intel oneAPI 2022 (w/Microsoft Visual Studio 2019) | nmake (64-bit Windows), Intel oneAPI
2022 (w/Microsoft Visual Studio 2022) | nmake (64-bit Windows), Intel oneAPI 2023 (w/Microsoft Visual Studio
2019) | nmake (64-bit Windows), Intel oneAPI 2023 (w/Microsoft Visual Studio 2022) | nmake (64-bit Windows),
Intel Parallel Studio XE 2020 (w/Microsoft Visual Studio 2017) | nmake (64-bit Windows), Intel Parallel Studio
XE 2020 (w/Microsoft Visual Studio 2019) | nmake (64-bit Windows), LCC-win64 v2.4.1 | gmake (64-bit Windows),
Mentor Graphics QuestaSim/Modelsim (32-bit Windows), Mentor Graphics QuestaSim/Modelsim (64-bit Linux), Mentor
Graphics QuestaSim/Modelsim (64-bit Windows), Microsoft Visual C++ 2017 v15.0 | CMake/Ninja (32-bit Windows),
Microsoft Visual C++ 2017 v15.0 | CMake/Ninja (64-bit Windows), Microsoft Visual C++ 2017 v15.0 | CMake/nmake
(32-bit Windows), Microsoft Visual C++ 2017 v15.0 | CMake/nmake (64-bit Windows), Microsoft Visual C++ 2017
v15.0 | nmake (64-bit Windows), Microsoft Visual C++ 2019 v16.0 | CMake/Ninja (32-bit Windows), Microsoft
Visual C++ 2019 v16.0 | CMake/Ninja (64-bit Windows), Microsoft Visual C++ 2019 v16.0 | CMake/nmake (32-bit
Windows), Microsoft Visual C++ 2019 v16.0 | CMake/nmake (64-bit Windows), Microsoft Visual C++ 2019 v16.0 |
nmake (64-bit Windows), Microsoft Visual C++ 2022 v17.0 | CMake/Ninja (32-bit Windows), Microsoft Visual C++
2022 v17.0 | CMake/Ninja (64-bit Windows), Microsoft Visual C++ 2022 v17.0 | CMake/nmake (32-bit Windows),
Microsoft Visual C++ 2022 v17.0 | CMake/nmake (64-bit Windows), Microsoft Visual C++ 2022 v17.0 | nmake (64-bit
Windows), Microsoft Visual Studio Project 2017 | CMake (32-bit Windows), Microsoft Visual Studio Project 2017 |
CMake (64-bit Windows), Microsoft Visual Studio Project 2019 | CMake (32-bit Windows), Microsoft Visual Studio
Project 2019 | CMake (64-bit Windows), Microsoft Visual Studio Project 2022 | CMake (32-bit Windows), Microsoft
Visual Studio Project 2022 | CMake (64-bit Windows), MinGW64 | CMake/gmake (64-bit Windows), MinGW64 |
CMake/Ninja (64-bit Windows), MinGW64 | gmake (64-bit Windows), NVIDIA CUDA (w/Microsoft Visual C++ 2017) |
nmake (64-bit Windows), NVIDIA CUDA (w/Microsoft Visual C++ 2019) | nmake (64-bit Windows), NVIDIA CUDA
(w/Microsoft Visual C++ 2022) | nmake (64-bit Windows), RTI Connext 6.x Project, RTI Connext Micro 2.4 Project,
Simulink Real-Time Linux arm64 Remote Build Toolchain, Simulink Real-Time Linux x64 Remote Build Toolchain,
Simulink Real-Time Toolchain, Synopsys VCS (64-bit Linux), Xilinx Vivado Simulator (64-bit Linux), Xilinx
Vivado Simulator (64-bit Windows)".
Error in coder.make.internal.TMFProps (line 325)
lToolchain = extractToolchainAttributesFromName...
Error in coder.make.internal.getTMFProperties (line 51)
lTMFProperties = coder.make.internal.TMFProps(lTemplateMakefile, lMexCompilerKey);
Error in coder.internal.getMexCompilerForModel
Error in coder.internal.getMexCompilerForModel
Error in coder.internal.ModelCompInfo/createModelCompInfoPrivate
Error in coder.internal.ModelCompInfo.createModelCompInfo
Error in slbuild_private
Error in slbuild_private
Error in sl_feval
Error in coder.internal.codegenAndCompile
Error in slbuild
Error in slbuild
Error in rtwbuild
My installation is set up to use MSVS 2019 to compile C code:
>> mex -setup C
Renamed options file 'C:\Users\...\AppData\Roaming\MathWorks\MATLAB\R2024a\mex_C_win64.xml' to 'C:\Users\...\AppData\Roaming\MathWorks\MATLAB\R2024a\mex_C_win64_backup.xml'.
MEX configured to use 'Microsoft Visual C++ 2019 (C)' for C language compilation.
My model configuration parameter setting for Code Generation -> Build process -> Toolchain is set to Automatically locate an installed toolchain, which I believe is required by my ert.tlc system target file setting.
What can I do to fix this error?
6 个评论
回答(1 个)
Githin George
about 15 hours 前
Hello Engenuity,
I understand that you are facing issues with the toolchain configuration for your Simulink model. I noticed the following details in your configuration settings:
- You are trying to build the model on a Windows machine (as observed in the output of the “mex -setup” command).
- Based on the error message you provided, I assume that the “TemplateMakefile” property is set to “ert_unix.tmf,” which is located in “C:\Program Files\MATLAB\R2024a\toolbox\coder\compile\tmf\ert_unix.tmf”.
- The “ert_unix.tmf” is meant for UNIX-based systems and may not work well on Windows.
To resolve the build errors, you can try setting the “TemplateMakefile” to the default “ert_default_tmf” using the following command:
matlab
set_param(model, "TemplateMakefile", "ert_default_tmf")
I hope this helps resolve your issue.
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Build Configuration 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!