Technical Solutions
Why do I receive an error about gcc version when executing a MEX-file or an executable generated by MATLAB Compiler on Linux?
Date Last Modified: 04 Mar 2008
| Solution ID: | 1-2H64MF | |
| Product: | MATLAB; MATLAB Compiler | |
| Reported in Release: | No Release | |
| Fixed in Release: | R2007b | |
| Platform: | Linux | |
| Operating System: | Linux Any |
Subject:
Why do I receive an error about gcc version when executing a MEX-file or an executable generated by MATLAB Compiler on Linux?
Problem Description:
If I call a MEX-file that I compiled using gcc, or an executable that I created using MATLAB Compiler and gcc, I receive the following error:
/opt/linux/matlabR14SP3/bin/glnx86/../../sys/os/glnx86/libgcc_s.so.1: version `GCC_3.3' not found (required by /usr/lib/libstdc++.so.6)
Solution:
This bug has been fixed in Release 2007b (R2007b). For previous product releases, read below for any possible workarounds: For csh users:
Workaround 2: Another workaround is to replace some library files in the MATLAB installation with the corresponding libraries from the version of GCC you are using. Be sure to create backup copies of any libraries you replace, since you may have errors in MATLAB after replacing the libraries. For example in MATLAB 7.1 (R14SP3) you could replace the following files: libg2c.so.0.0.0 libgcc_s.so.1 libstdc++.so.5.0.3 and the symbolic links associated with these files with newer libraries from your gcc release. The files to be replaced are in the following directory: $MATLABROOT/sys/os/$ARCH (where $MATLABROOT is the MATLAB root directory on your machine, as returned by typing:
matlabroot
at the MATLAB command prompt and $ARCH is your architecture "glnx86" for 32-bit Linux and "glnxa64" for 64-bit Linux.)
|
Related Solutions:
|
|
Store