"Simulink is not available" error message when compiling or packaging an app.

3 views (last 30 days)
Using the Matlab compiler ("deploytool") or the "Package App" option to create packages always fail with a "Simulink is not available" error message. Everything works fine if I use a 2015b installation. The package to be compiled does not contain any Simulink components or references to Simulink.
I cannot find any reference to this type of error. Any ideas?
Log file from the Production Server Compiler:
mcc -W CTF:calc_combined_v4 -U -d C:\LocalCopy\Belt_Calculation\BCP\BCP-webbased\Calculation_Combined\calc_combined_v4\for_testing -v C:\LocalCopy\Belt_Calculation\BCP\BCP-webbased\Calculation_Combined\calc_combined_v4.m
Compiler version: 7.1 (R2019b)
Dependency analysis by REQUIREMENTS.
Error while determining required deployable files. Compilation terminated. Details:
Error using <a href="matlab:matlab.internal.language.introspective.errorDocCallback('matlab.depfun.internal.SimulinkModelInspector', 'C:\Program Files\MATLAB\R2019b\toolbox\matlab\depfun\+matlab\+depfun\+internal\SimulinkModelInspector.m', 11)" style="font-weight:bold">matlab.depfun.internal.SimulinkModelInspector</a> (<a href="matlab: opentoline('C:\Program Files\MATLAB\R2019b\toolbox\matlab\depfun\+matlab\+depfun\+internal\SimulinkModelInspector.m',11,0)">line 11</a>)
Simulink is not avaiable.
mcc failed.

Accepted Answer

Aiswarya Subramanian
Aiswarya Subramanian on 1 Dec 2020
Dear Dirk,
The issue is most likely associated with licensing. The license administrator might have excluded the account from Simulink. You can ask your license administrator to do the same for Simulink_Compiler. Once that is done, the following command shall return 0 (before it would return 1):
>> license('test','Simulink_Compiler')
You can find your license administrator by following the steps here:
Another solution to disable the dependency analysis is to run the following command:
>> license('test','Simulink_Compiler','disable')
This will force the test checkout to be disabled.
Hope this helps resolve your query.
-Aiswarya
  2 Comments
Dirk Twisk
Dirk Twisk on 1 Dec 2020
Hello Aiswarya,
I think that geting a license for Simulink or the compiler will solve the problem, but I do not need Simulunk at this time, so that solution is not really acceptable from a cost point of view.
I tried the second solution, but that did not work. Strangely enough, the error, although consistent, does not actually prevent the user from creating a new compiler project. So if I choose to "share the app" from the app designer, I will get an error but the package will compile. However, I choose the "Package App" option from "Apps" in the top menu, it will not load an existing project. So, option 1 will generate an error but work, while the second route does not work at all.
Dirk Twisk
Dirk Twisk on 4 Dec 2020
Well, I retried the second solution:
(>> license('test','Simulink_Compiler','disable')
and now it worked. Not sure why it did not work the first time. The package can now be compiled. I guess a permanent solution to the issue is then to put this line in the Matlab startup file.
Note that a similar question was raised some time ago, and a different solution was proposed there:
I can verify that this works as well, but it does require the user to modify the Matlab installation, which might require admin rights on the users' machine.

Sign in to comment.

More Answers (0)

Categories

Find more on Introduction to Installation and Licensing in Help Center and File Exchange

Products


Release

R2019b

Community Treasure Hunt

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

Start Hunting!