Real time simulink build error
7 views (last 30 days)
I am trying to build the example ex_slrt_rt_osc for real time Simulink and am getting the following error '"C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\Tools\VCVarsQueryRegistry.bat"' is not recognized as an internal or external command,operable program or batch file. I have the already installed the Visual C compiler required for this and cannot resolve this error on my own. Any immediate help is much appreciated.
Prashant Arora on 16 Oct 2017
This issue can occur if your machine does not have appropriate permissions to edit the registry. The Microsoft Visual Studio compilers are configured in such a way that they require the ability to query the system registry using "reg.exe". The compiler uses configuration batch files "vcvarsall.bat", "vcvars64.bat", and "VCVarsQueryRegistry.bat" that call the "reg query" command to query the registry for the paths of different components.
To verify that this is the cause, you can try the following:
(1) Open a Windows Command Prompt window (press Windows Key + R, type in "cmd" in the field that appears, and press "Enter")
(2) Enter the following commands, one-by-one, to query the registry:
reg query "HKLM\SOFTWARE\Microsoft\VisualStudio\SxS\VS7" /v "14.0"
reg query "HKCU\SOFTWARE\Microsoft\VisualStudio\SxS\VS7" /v "14.0"
reg query "HKLM\SOFTWARE\Wow6432Node\Microsoft\VisualStudio\SxS\VS7" /v "14.0"
reg query "HKCU\SOFTWARE\Wow6432Node\Microsoft\VisualStudio\SxS\VS7" /v "14.0"
If the output of each command shows:
"ERROR: Registry editing has been disabled by your administrator."
then this confirms that this is a permissions issue. You can work with your IT administrators to change the permissions and/or "Group Policy" to allow the "reg query" commands on your machine. Obtaining sufficient permission should then allow the batch files to execute successfully.