Skip to content
Snippets Groups Projects
Commit d8256f7d authored by Nicola Vigano's avatar Nicola Vigano
Browse files

MCC: fixed matlab functions compilation

parent f83c482a
No related branches found
No related tags found
No related merge requests found
......@@ -34,12 +34,13 @@ function gtCompileFunctions( force, mfiles, funcs_to_compile )
try
gtMcc(func_name, 'bin_path', comp_file_dir)
catch mexc
fprintf('Compilation of function "%s" failed!\n', func_name);
error_log(ii_f, :) = {func_name, mexc};
end
end
end
errors = find(~isempty(error_log(:, 1)));
errors = find(cellfun(@(x)(~isempty(x)), error_log(:, 1)));
for ii_e = 1:numel(errors)
func_name = error_log{errors(ii_e), 1};
mexc = error_log{errors(ii_e), 2};
......
......@@ -18,7 +18,7 @@ function gtMcc(myfunctionname, varargin)
end
if ( mcc_vers_major < 4 || (mcc_vers_major == 4 && mcc_vers_minor < 8))
gtError('gt_mcc:wrong_matlab_version', ...
error('gtMcc:wrong_matlab_version', ...
'Compilation using Matlab versions before R2008 is not supported')
end
......@@ -82,7 +82,8 @@ function gtMcc(myfunctionname, varargin)
try
mcc('-m', myfunctionname, '-d', conf.bin_path, '-a', 'workspaceGlobal.mat');
catch mexc
if (gtCheckExceptionType(mexc, 'mcc_err_checkout_failed'))
if (gtCheckExceptionType(mexc, 'mcc_err_checkout_failed') ...
|| gtCheckExceptionType(mexc, 'MATLAB:req_failed_to_checkout_license'))
disp('Could not get a compiler license.');
disp('Surf to http://compweb/public/nice/matlab_licence.php');
disp('and call the person with the compiler license to see if you could use it!');
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment