Question regarding the SupportPackages option in standalone​Applicatio​nCompiler

I am writing to ask for guidance on the SupportPackages option for the standaloneApplicationCompiler. I encountered an error when trying to compile my application with multiple support packages.
When I specify multiple support packages, the compilation process fails with the following error message:
次を使用中のエラー: matlab.depfun.internal.SPMode.validateSupportPackageInputs (行 22)
Support Package Listは欠損値でない string スカラーまたは文字ベクトルにする必要があります。
エラー: compiler.internal.build.DependencyOptions/set.SupportPackages (行 93)
[spkgData,spkgMode] = matlab.depfun.internal.SPMode.validateSupportPackageInputs(newSupportPackageInput);
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
エラー: compiler.internal.ui.deployScriptLogger.DeployScriptLogger/logDeployment
エラー: compiler.internal.ui.deployScriptLogger.startLoggedDeployment
When I export the build script, the SupportPackages option is defined as a string array by default, as shown below. However, using this default code results in a compilation error.
▼ Default code from exported script (causes an error)
buildOpts.SupportPackages = ["Computer Vision Toolbox Model for Vision Transformer Network", "Hyperspectral Imaging Library Support Package", "Image Processing Toolbox Model for Segment Anything Model"];
▼ This code works correctly (Cell Array)
buildOpts.SupportPackages = {'Computer Vision Toolbox Model for Vision Transformer Network', 'Hyperspectral Imaging Library Support Package', 'Image Processing Toolbox Model for Segment Anything Model'};
The error message says the input must be a "string scalar or character vector," but it seems that a string array is not supported, while a cell array of character vectors is.
Is this the intended behavior? I would appreciate it if you could explain the reason for this.
Thank you for your time and assistance.

1 Comment

buildOpts.SupportPackages = ["Computer Vision Toolbox Model for Vision Transformer Network", "Hyperspectral Imaging Library Support Package", "Image Processing Toolbox Model for Segment Anything Model"];
That is not a string scalar; that is a non-scalar string array,

Sign in to comment.

Answers (0)

Categories

Asked:

on 28 Jul 2025

Edited:

on 28 Jul 2025

Community Treasure Hunt

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

Start Hunting!