フィルターのクリア

How can I change the rtwbuild option "skipSetupArg"?

3 ビュー (過去 30 日間)
Georg
Georg 2023 年 1 月 11 日
回答済み: Meet 2023 年 3 月 10 日
The build process (command: rtwbuild('model')) generates a model.bat file in Matlab 2022b. Here is an exemplary content:
set skipSetupArg=%2
if "%skipSetupArg%" NEQ "skip_setup_msvc" (
call "setup_msvc.bat"
)
cd .
if "%1"=="" (nmake -f model.mk all) else (nmake -f model.mk %1)
@if errorlevel 1 goto error_exit
exit /B 0
:error_exit
echo The make command returned an error of %errorlevel%
exit /B 1
The file is then automatically executed with the argument "skip_setup_msvc", skipping the corresponding call "setup_msvc". (The full Command Window output is in the text file in the attachment.)
The subsequent command "nmake -f model.mk all" thereby fails and the build process terminates.
In Matlab 2020b there was (as far as I can tell) no such argument.
Is there an option in Matlab to change the argument "skipSetupArg"?
Thank you!

回答 (1 件)

Meet
Meet 2023 年 3 月 10 日
Yes, you can change the argument "skipSetupArg" by modifying the build settings in MATLAB. Follow the steps below:
  1. Open the Simulink model that you want to build.
  2. Click on the "Modeling" tab in the MATLAB ribbon.
  3. In the "Model Settings" section, click on the "Model Settings" button.
  4. In the "Configuration Parameters" dialog box, select "Code Generation" from the left-hand side list.
  5. In the "Code Generation" section, locate the "Custom Code" pane.
  6. In the "Custom Code" pane, find the "Build command" field.
  7. In the "Build command" field, remove the "skip_setup_msvc" argument and any other arguments that you want to change.
  8. Click on the "Apply" button to save the changes.
  9. Click on the "OK" button to close the dialog box.
After you have modified the build settings, MATLAB should generate the model.bat file with the updated build command, which will include your changes to the skipSetupArg argument.

カテゴリ

Help Center および File ExchangeSimulink Coder についてさらに検索

製品


リリース

R2022b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by