When you install a support package, MATLAB attempts to add the necessary directories to your path. However, if your pathdef.m (path definition file) is read-only, it probably failed to save the updated path. That means the path is active until you restart MATLAB.
Try this:
- If there is only one, it is most likely in your MATLAB installation directory, and it is a read-only file.
- If you have more than one, check each of them to see whether the path to the support package is included in one and not included in the other. The one that shows up first in the list is the one that is used by MATLAB, so make sure that file includes the necessary paths.
Make sure that your pathdef.m has both read and write permissions. The pathdef.m will need to be updated with the Support Package directories if the Support Package still does not work after restarting MATLAB.
Some troubleshooting steps to try within a MATLAB session where the support package functionality is not working:
- Check if "restoredefaultpath" is called anywhere in the "startup" and "matlabrc" files, which could be removing the support package directory from the path.
- Try manually adding the support package directory and subdirectories to the path using "genpath" and "addpath"
>> addpath(genpath(<supportPackageDirectory>));
- If this does not work, try using "addpath" and "genpath" without any arguments
At any point you can check what support packages are installed using
>> matlabshared.supportpkg.getInstalled