Why does my verification for Polyspace Client for C/C++ 7.1 (R2009b) fail after installing Polyspace Client for C/C++ 8.0 (R2010b) on my client?

2 views (last 30 days)
If Polyspace Client for C/C++ 7.1 (R2009b) and Polyspace Client for C/C++ 8.0 (R2010b) are both installed on a client side, it is impossible to launch a remote R2009b verification. The verification fails with the message:
Verification process failed
It is still possible to do a local verification.

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 22 Jun 2011
When installing Polyspace Client for C/C++ 8.0 (R2010b), the folder Polyspace_Common is updated. Polyspace Client for C/C++ 7.1 (R2009b) is using some binaries of Polyspace_Common that are not compatible with this version.
To work around this, you need to have two Polyspace_Common folders, one for the R2009b version and another for the R2010b version.
To do so, you first have to “install” a R2009b Polyspace_Common folder (for example, by making a copy of this folder before installing R2010b), and then switch the Polyspace_Common folders, depending on the product you want to use.
The products are using environment variables to find the binaries and compute the verifications. So the idea is to change these environment variables and make them point to the two possible folders.
To switch to R2009b, the script is:
setx POLYSPACE_COMMON "C:\PolySpace\PolySpace_Common_9b" -m
setx POLYSPACE_C "C:\PolySpace\PolySpaceForCandCPP_R2009b" –m
To switch to R2010b, the script is:
setx POLYSPACE_COMMON "C:\PolySpace\PolySpace_Common" -m
setx POLYSPACE_C "C:\PolySpace\PolySpaceForCandCPP_R2010b" –m
setx is a command that is not always available with Windows. If this command is not present, set can be used instead, but the problem is that it will change the environment variables only inside the script, or inside a DOS command session. So the workaround is to use a script that will update the variables and launch the GUI right after (in the same DOS session):
For R2009b:
set POLYSPACE_COMMON=C:\PolySpace\PolySpace_Common_9b
set POLYSPACE_C=C:\PolySpace\PolySpaceForCandCPP_R2009b
%POLYSPACE_COMMON%\Launcher\PSTLauncher.exe
For R2010b:
set POLYSPACE_COMMON=C:\PolySpace\PolySpace_Common
set POLYSPACE_C=C:\PolySpace\PolySpaceForCandCPP_R2010b
%POLYSPACE_C%\PVE\PolySpace.exe
For Simulink, the principle is the same. Instead of using a .bat file, we can do that with a function:
function PS_Shift(varargin)
% Default initialization
verifier_root = 'C:\Polyspace\PolyspaceForCandCPP_R2009b';
common_root = 'C:\Polyspace\Polyspace_Common_9b';
% Change value if needed
if (length(varargin) > 0 && strcmpi(varargin,'R2010b'))
verifier_root = 'C:\Polyspace\PolyspaceForCandCPP_R2010b';
common_root = 'C:\Polyspace\Polyspace_Common';
end
% Set verifier_root
if (ispref('PolySpace', 'verifier_root'))
setpref('PolySpace', 'verifier_root', verifier_root);
else
addpref('PolySpace', 'verifier_root', verifier_root);
end
% Set common_root
if (ispref('PolySpace', 'common_root'))
setpref('PolySpace', 'common_root', common_root);
else
addpref('PolySpace', 'common_root', common_root);
end
% Display new settings
disp(['Polyspace common is set to: ', getpref('PolySpace', 'common_root')]);
disp(['Polyspace verifier is set to: ', getpref('PolySpace', 'verifier_root')]);

More Answers (0)

Categories

Find more on Troubleshooting in Polyspace Products for Ada in Help Center and File Exchange

Tags

No tags entered yet.

Products


Release

R2010b

Community Treasure Hunt

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

Start Hunting!