                        README.first for MATLAB 4.2c
                        ----------------------------
0. Table of Contents
   -----------------

   1. DEC Ultrix Anomalous Behavior
   2. DEC Alpha OSF/1 Anomalous Behavior
   3. SunOS, Sun Solarius Anomalous Behavior
   4. Multiple Platform Bug Fixes
   5. In Situ MEX-File Debugging
   6. Linux System Requirements and Anomalous Behavior
   7. FLEXlm lmdiag License Administration Utility
   8. CD-ROM Installtion Anomalous Behavior


1. DEC Ultrix Anomalous Behavior
   -----------------------------

   1.1 Printing using Epson devices
       ----------------------------

       Printing using Epson devices causes the

           "Fixed up unaligned data access"

       system message to appear. This message should be ignored.


   1.2 Generating nonreal-time code
       ----------------------------

       When generating nonreal-time code using the Real-Time 
       Workshop, you must include an additional flag due to a problem 
       with the C compiler.   To include this flag, edit the file 

           $MATLAB/toolbox/local/matlabrc.m

       and insert the line below:

           set_param(0,'Nonreal-time build command','make_nrt OPTS="-std1"')


   1.3 MEX-files in startup.m or matlabrc.m
       ------------------------------------

       When using MEX-files, place the following line in your startup.m or
       matlabrc.m script:

          set_param(0,'Compile Command','!cmex CC=gcc $model.c')


2. DEC Alpha OSF/1 Anomalous Behavior
   ----------------------------------

   2.1 Printing using any GhostScript device 
       -------------------------------------

       Printing using any GhostScript device causes the

           "Fixed up unaligned data access"

       system message to appear. This message should be ignored.


   2.2 Rebuilding a loaded MEX-file will cause MATLAB to crash
       -------------------------------------------------------

       Rebuilding a loaded MEX-file will cause MATLAB to crash the 
       next time the MEX-file is cleared or run.  To work around this 
       operating system bug, you must explicitly clear the MEX-file from 
       memory before rebuilding.  To do this, use the command

            >> clear mex

       to clear all loaded MEX-files or the command

            >> clear name

       where 'name' is the name of the MEX-file to clear. We have
       notified DEC of the problem and are currently working to resolve
       this problem.


   2.3 GhostScript device 'pcx16'
       --------------------------

       The GhostScript device 'pcx16' is not supported in this release.


   2.4 Generating nonreal-time code
       ----------------------------

       When using the Real-Time Workshop to generate nonreal-time
       applications, you must compile the source code without 
       optimization.  To do this, edit the file

                $MATLAB/toolbox/local/matlabrc.m

       and insert the line below:
 
          set_param(0,'Nonreal-time build command','make_nrt OPT_OPTS=""');


   2.5 libmat and engine interface
       ---------------------------

       Stand alone C and Fortran files that make calls to the libmat
       interface or engine routines need to be linked against the sytem
       'ots' library.  Add the following line to the list of system
       libraries that are linked against the code.

                -lots


3. SunOS, Sun Solaris Anomalous Behavior
   ---------------------------------------

   3.1 GhostScript device 'bj10e'
       --------------------------

       The GhostScript device 'bj10e' does not support the Handle Graphics 
       property PaperType uslegal.

      
4. Multiple Platform Bug Fixes
   ---------------------------

   4.1 MATLAB 4.2c bug fixes
       ---------------------

       G60021  -- Fixed a memory leak using MATLAB I/O commands inside an
                  Engine program.

       G63820  -- Limitations for the 'findobj' command with large numbers
                  of objects have been corrected.

       G64401  -- The 'csvwrite' function has been redesigned to write
                  matrices properly with commas used as separators for
                  elements.

       G65277  -- Imported HPGL graphs to some third party packages no
                  longer render upside down.

       G65833  -- The coding error in the sample Fortran file mattest4.F
                  found in the $MATLAB/extern/src directory has been
                  corrected.
                                                  
       G66642  -- Issuing a 'title' command no longer erases the current
                  plot from axes when using versaterm 3.6.2 to connect to
                  a SunOS machine.

       G67031  -- Fixed a bug in the fscanf and sscanf functions when given
                  the empty output case.

       G95257  -- Large plots are now correctly printed using the HPGL
                  format.
 
       G99587  -- Implemented support for the -debug flag in cmex.

       G104535 -- The file 'bench.m', which displays benchmarks for
                  different machines, has been updated.

       G106450 -- PostScript and Illustrator drivers now use the filename
                  instead of just 'MATLAB graph' as the title in the DSC
                  comment area.


   4.2 SIMULINK 1.3c bug fixes
       -----------------------

       G63654  -- A problem where the 2-D Look-up Table block in SIMULINK
                  used to output NaNs has been corrected. 

       G66002  -- Problems using the control keys for SIMULINK editing
                  have been corrected.

       G61872  -- A problem with short line connections was corrected in
                  SIMULINK.

       G92235  -- Implemented vectorization of SIMULINK MUX blocks.

       G94764  -- An HPGL printing problem where sides of some SIMULINK
                  blocks were being clipped has been fixed.

       G100000 -- A model under SIMULINK 1.2 no longer displays a sample
                  time color error message when used in SIMULINK 1.3c.


5. In Situ MEX-File Debugging
   --------------------------

   For a general description of in situ MEX-file debugging, consult
   your release notes.  The following information pertains to MEX-file
   debugging on specific platforms.


   5.1 Platform specific caveats
       -------------------------

       5.1.2 Sun SPARC (SunOS 4.1.x)
             -----------------------

             Only the GNU debugger, gdb, is supported.


       5.1.2 HP 9000/700 (HP-UX 9.x)
             -----------------------

             To debug MEX-files, you must append a .sl extension. This
             happens automatically when you use the -g option with cmex. 
             Specify the MEX-file you wish to debug with the -l option on 
             the MATLAB command line.  For example, to debug yprime.c,
             type:

                        matlab -Dxdb -l yprime.sl

             At the debugger prompt, you can then set breakpoints.  There
             is no need to turn MEX-file debugging on.

             MEX-files are only supported using the native ANSI C compiler
             that comes with xdb (the native debugger) in the Program
             Developers Toolkit. The standard bundled compiler does not
             support position-independent code generation, which is needed
             to build MEX-files.

             You can use gcc, the GNU compiler, to build your MEX-files, 
             although you will not be able to debug them. To obtain a copy
             of gcc-2.6.0 for HP-UX that supports pic, first ftp to
             jaguar.cs.utah.edu.  Login as anonymous and use your e-mail
             address as your password, and cd to /dist.

             To compile your files using gcc, specify 

                        CC=gcc CFLAGS=-fpic

             on the cmex command line. For example, to compile
             yprime.c, type:

                        cmex CC=gcc CFLAGS=-fpic yprime.c

             Unfortunately, at present, the GNU debugger, gdb, does not
             support debugging MEX-files on these platforms.

  
       5.1.3 SGI (IRIX 5.x)
             --------------

             Both dbx and gdb are supported.


       5.1.4 IBM RS/6000 (AIX 3.x)
             ---------------------

             Only dbx is supported.


       5.1.5 DECstation (Ultrix 4.x)
             -----------------------

             In situ debugging is not supported on this platform.


       5.1.6 Sun SPARC (Solaris 2.x)
             -----------------------

             dbx version 4.0 will allow you to debug MEX-files but was
             not available at the time this document was written.  To
             debug MEX-files under dbx version 3.0.1, you will need to
             install patch number 101961-04, which may be obtained from
             Sun.  A patch level of -04 or greater will contain the fix.

             The GNU debugger, is supported only if your MEX-files were
             compiled with gcc, the GNU compiler.  To compile your MEX-
             files using gcc, specify CC="gcc -shared" to the cmex
             command line.  For example, to compile yprime.c:

                        cmex -g CC="gcc -shared" yprime.c

             Note: Specifying CC="gcc -shared" did not work under
                   Solaris 2.x with MATLAB versions prior to 4.2c.


       5.1.7 DEC Alpha (OSF/1 3.x)
             ---------------------

             Both dbx and gdb are supported.
 

       5.1.8 HP 9000/300-400 (HP-UX 9.x)
             ---------------------------

             In situ debugging is not supported on this platform.


   5.2 Trouble shooting
       ----------------

       5.2.1 Symptom: You try to add breakpoints and the system says the 
                      symbol doesn't exist.

             . Be sure to specify -g when invoking cmex even if you are
               only using it to link precompiled object files.  Note that,
               by default, MEX-files created by cmex are stripped of all
               symbols.

             . If using gdb, make sure the symbol table was loaded.  You
               will know that symbols were successfully loaded if a
               message to that effect is displayed. If no message appears,
               try issuing the same command again.  If this still does not
               work, try moving your MEX-file to the current directory and
               not specifying the absolute path when loading the symbol
               table.  For example, try

                   (gdb) shared yprime.mexsol

               where yprime.mexsol is the name of your MEX-file in the
               current directory.

       5.2.2 Symptom: You try to step over a MathWorks MEX-function and
                      the debugger never returns you to your MEX-file.

             . (SunOS 4.1.x) If you are using the GNU gdb debugger version
               4.13 switch to version 4.12.  There is a known problem
               with 4.13 which will hopefully be fixed in the next release.


6. Linux System Requirements and Anomalous Behavior
   ------------------------------------------------

   6.1 System requirements
       -------------------

       6.1.1 Linux '95 version 1.2
             ---------------------

             MATLAB requires the Linux'95 operating system to be installed 
             and configured to execute ELF binary object files. 
       

       6.1.2 ELF shared libraries
             --------------------

             MATLAB requires you to install ELF shared libraries.

             Here's the list of the ELF share libraries referenced by
             MATLAB 4.2c Linux release.  These files should be located
             in the /lib/elf directory.

            ---------------------------------------------------------------
            ld-linux.so.1:       symbolic link to ld-linux.so.1.0.14
            ld-linux.so.1.0.14:  ELF 32-bit LSB dynamic lib 80386 Version 1
            libc.so:             symbolic link to libc.so.4
            libc.so.4:           symbolic link to libc.so.4.6.27
            libc.so.4.6.27:      ELF 32-bit LSB dynamic lib 80386 Version 1
            libdl.so:            symbolic link to libdl.so.1
            libdl.so.1:          symbolic link to libdl.so.1.0.14
            libdl.so.1.0.14:     ELF 32-bit LSB dynamic lib 80386 Version 1
            libm.so:             symbolic link to libm.so.4
            libm.so.4:           symbolic link to libm.so.4.6.27
            libm.so.4.6.27:      ELF 32-bit LSB dynamic lib 80386 Version 1
            libtermcap.so:       symbolic link to libtermcap.so.1
            libtermcap.so.1:     symbolic link to libtermcap.so.1.2.3
            libtermcap.so.1.2.3: ELF 32-bit LSB dynamic lib 80386 Version 1
            ---------------------------------------------------------------

            You may FTP the Linux ELF shared libraries from The MathWorks
            FTP site:

         ftp.mathworks.com:/pub/tech-support/outgoing/linux/elflinlib.tar.Z

            NOTE: 'elflinlib.tar.Z' is a tar-compressed file.
                

       6.1.3 GNU ELF C compiler 2.6.3
             ------------------------

             You *must* have version 2.6.3 or greater of the GNU ELF C 
             compiler installed on your Linux system to create C MEX-files.


       6.1.4 No support for Fortran MEX-Files 
             --------------------------------

             There is no support for Fortran MEX-files. 
 

       6.1.5 No support for FLEXlm licensing
             -------------------------------

             There is no support for FLEXlm on Linux yet. All references 
             to FLEXlm and the lm scripts should be ignored for the MATLAB 
             4.2c Linux release.


       6.1.6 Mixing MATLAB licenses for Linux and other platforms
             ----------------------------------------------------

             The FEATURE lines for Linux licenses are unique and can not be
             used with other UNIX platform releases of MATLAB. If you need
             to support both, rename your license.dat file for Linux to
             license.lnx and start MATLAB for Linux by typing:

                 matlab -c license.lnx


       6.1.7 Unsupported software 
             --------------------

             There is no support for ACSL, Maple, Real-Time Workshop &
             SIMULINK Accelerator.


   6.2 Anomalous Behavior
       ------------------

       6.2.1 Executing csh commands from within MATLAB
             -----------------------------------------

             Because of a bug in the Linux csh, you cannot execute csh shell 
             commands from within MATLAB. (Use sh, bash, or another shell.)


       6.2.2 MATLAB File Selection Widget
             ----------------------------

             The MATLAB file selection widget has been substituted to work 
             around an issue in Motif. This widget will appear differently 
             than it does on other UNIX platforms. This will be addressed 
             in the next major release of MATLAB for Linux.


       6.2.3 fscanf/sscanf can't read Nan & Inf
             ----------------------------------

             See "MATLAB Release Notes Version 4.2" page 72.
             This is the entry for the Linux platform.

             Platform |  fscanf  |  fscanf  |  sscanf  |  sscanf  |
                      | read nan | read nan | read nan | read nan |
              Linux        No         No         No         No


       6.2.4 MATLAB math function results for NaN and Inf
             --------------------------------------------

             Some Linux math functions produce different results for 
             NaN and Inf conditions than other Unix workstations.

                 ----------------------------------------
                 rem(1,0)=1              not NaN
                 rem(1,nan)=1            not NaN
                 exp(-inf) is -Inf       not zero (false)
                 (1+eps)^(-inf) is NaN   not zero (false)
                 (1-eps/2)^inf is NaN    not zero (false)
                 inf^(-eps/2) is NaN     not zero (false)
                 2^(-inf) is NaN         not zero (false)
                 pow2(realmax,1)=NaN     not Inf
                 inf^(eps/2)=NaN         not Inf
                 (1+eps)^inf=NaN         not Inf
                 (-(1+eps))^inf=NaN      not Inf
                 (1-eps/2)^(-inf)=NaN    not Inf
                 (-(1-eps/2))^(-inf)=NaN not Inf
                 (-inf)^2=NaN            not Inf
                 (1+eps)^inf=NaN         not Inf
                 gamma(-inf)=NaN         not Inf
                 ----------------------------------------


7. FLEXlm lmdiag License Administration Utility
   --------------------------------------------

   There is now an additional FLEXlm License Manager Utility that can
   be found in $MATLAB/etc after installing the license manager. It can
   be used to diagnose problems when you cannot check out a license.
   It is currently available on all UNIX platforms except Linux.

   The most common usage is to:

        cd $MATLAB/etc
        ./lmdiag

   This checks all features in the default license file,
   $MATLAB/etc/license.dat, on the local host.

   Here is a more complete description of the utility.

   ------------------------------------------------------------------------
   Name:
      lmdiag    script file for diagnosing problems when you cannot
                check out a license.
 
   Usage:
      lmdiag [[-r matlabdir] | [-c licensefile] | -m [marker]] [-n]
             [feature]
 
   Description:
      lmdiag will print information about the license, then attempt to
      checkout each feature unless feature is specified on the command
      line in which case only that feature is checked. If the checkout
      fails because lmdiag cannot connect to the license server then the
      user has the option of running "extended connection diagnostics".
      This will attempt to connect to each port on the license server node
      and can detect if the port number in the license file is incorrect.
      If lmdiag finds the vendor daemon for the feature being tested, then
      it will indicate the correct port number for the license file to
      correct the problem.
 
   Options:
 
      -r matlabdir      (MathWorks added option)
 
           Provide the MATLAB root directory path. Should be used when
           MATLAB is in an automounted file system.
 
      -c licensefile
 
           Path of the license file.
           DEFAULT: $MATLAB/etc/license.dat
 
      -m [marker]       (MathWorks added option)
 
           Check the license file in /usr/tmp/marker.dat on the
           current host. This is created by lmstart/lmboot.
 
           If marker is not given then it defaults to:  lm_TMW4
 
      -n
 
           Run in non-interactive mode. No extended connection
           diagnostics are available.
 
      feature
 
           Check only this feature.        
   ------------------------------------------------------------------------
 

8. CD-ROM Installtion Anomalous Behavior

   8.1 /cdrom/install -t 
       -----------------
       
       Terminal installation is not supported on DEC Alpha OSF/1 for Vol. V 
       of the MATLAB CD-ROM.


   8.2 Symbolic 64 bit libraries
       -------------------------

       The Symbolic Toolbox always installs 64 bit libraries. If you do 
       not need these libraries for your platform, you may remove them.
       

   8.3 Restricted operation on file system
       -----------------------------------

       If you received the message, "Restricted operation on file system,"
       while installing MATLAB on DEC ULTRIX. Install as superuser (root).

---------------------------------------------------------------------------
Copyright (c) 1995 by The MathWorks, Inc.
$Revision: 1.16 $  $Date: 1995/06/19 23:29:05 $
---------------------------------------------------------------------------
