User`s guide

Troubleshooting
2-25
Troubleshooting
This section identifies some of the more common problems that can occur when
installing and configuring the MATLAB Compiler.
mex Troubleshooting
Out of Environment Space Running mex or mbuild. On Windows 98 systems, the mex
and
mbuild scripts require more than the default amount of environment
space. If you get the error,
out of environment space, add this line to your
config.sys file.
shell=c:\command.com /e:32768 /p
On Windows Me systems, if you encounter this problem and are using the
MATLAB add-in for Visual Studio, follow the procedure in Configuring on
Windows 98 and Windows Me Systems on page 4-25.
Non-ANSI C Compiler on UNIX. A common configuration problem in creating C
MEX-files on UNIX involves using a non-ANSI C compiler. You must use an
ANSI C compiler.
DLLs Not on Path on Windows. MATLAB will fail to load MEX-files if it cannot find
all DLLs referenced by the MEX-file; the DLLs must be on the DOS path or in
the same directory as the MEX-file. This is also true for third-party DLLs.
Segmentation Violation or Bus Error. If your MEX-file causes a segmentation
violation or bus error, there is most likely a problem with the MATLAB
Compiler. Contact Technical Support at The MathWorks at
support@mathworks.com.
Generates Wrong Answers. If your program generates the wrong answer(s), there
are several possible causes. There could be an error in the computational logic
or there may be a defect in the MATLAB Compiler. Run your original M-file
with a set of sample data and record the results. Then run the associated
MEX-file with the sample data and compare the results with those from the
original M-file. If the results are the same, there may be a logic problem in your
original M-file. If the results differ, there may be a defect in the MATLAB
Compiler. In this case, send the pertinent information via e-mail to
support@mathworks.com.