- Posts: 2
SAM-generated MATLAB code cannot find Shared Library
- mkovacs
- Topic Author
Less
More
17 Sep 2021 22:10 #10074
by mkovacs
SAM-generated MATLAB code cannot find Shared Library was created by mkovacs
Sam generated a MATLAB *.m file (SAM_Test_MATLAB.m) , a shared library file (ssc.dylib), a header file (sccapi.h) and a grid_curtailment.csv file. All these files are in the same directory. When I run the *.m file (named SAM_Test_MATLAB.m) , I received the following error code from MATLAB:
>> SAM_Test_MATLAB Error using loadlibrary Supported compiler not found. For options, visit www.mathworks.com/support/compilers .
Error in loadlibrary Error in SAM_Test_MATLAB/ssccall (line 12) loadlibrary(strcat(ssclibpath,ssclib),strcat(ssclibpath,'sscapi.h')); Error in SAM_Test_MATLAB (line 213) ssccall('load');I am unfamiliar with handling shared libraries and associated header files and how a compiler would be used in this case. I would appreciate any suggestion you offer in resolving this problem. I am attaching the SAM-generated MATLAB file
Thank you
Mark Kovacs
>> SAM_Test_MATLAB Error using loadlibrary Supported compiler not found. For options, visit www.mathworks.com/support/compilers .
Error in loadlibrary Error in SAM_Test_MATLAB/ssccall (line 12) loadlibrary(strcat(ssclibpath,ssclib),strcat(ssclibpath,'sscapi.h')); Error in SAM_Test_MATLAB (line 213) ssccall('load');I am unfamiliar with handling shared libraries and associated header files and how a compiler would be used in this case. I would appreciate any suggestion you offer in resolving this problem. I am attaching the SAM-generated MATLAB file
Thank you
Mark Kovacs
Attachments:
Please Log in or Create an account to join the conversation.
- pgilman
Less
More
- Posts: 5423
21 Sep 2021 09:38 #10086
by pgilman
Replied by pgilman on topic SAM-generated MATLAB code cannot find Shared Library
Hi Mark,
You may want to check the ssclibpath variable to make sure it is pointing to the folder that contains the sscapi.h file.
You could also use the libisloaded() function to verify that the library is loaded.
Best regards,
Paul.
You may want to check the ssclibpath variable to make sure it is pointing to the folder that contains the sscapi.h file.
You could also use the libisloaded() function to verify that the library is loaded.
Best regards,
Paul.
Please Log in or Create an account to join the conversation.
Moderators: pgilman