home *** CD-ROM | disk | FTP | other *** search
- @echo off
- :: Batch file to build the COBOL simple samples
- :: Run with one parameter - the compiler to use (Realia or MicroFocus)
- :: Example for MicroFocus COBOL:
- :: build microfocus
- ::
- :: You MUST have the appropriate environment variables set for the compiler
- ::
-
- if %1$ == $ goto usage
- if %1$ == realia$ goto realia
- if %1$ == REALIA$ goto realia
- if %1$ == Realia$ goto realia
- if %1$ == microfocus$ goto microfocus
- if %1$ == MICROFOCUS$ goto microfocus
- if %1$ == Microfocus$ goto microfocus
- goto usage
-
- :realia
- realcob realsamp;
- if errorlevel 1 goto err
- link /nopackcode realsamp+sqlreal4,,,realdos;
- if errorlevel 1 goto err
- goto out
-
- :microfocus
- cobol mfsamp.cob;
- if errorlevel 1 goto err
- link mfsamp+sqlcob,,,lcobol+cobapi/nod;
- if errorlevel 1 goto err
- goto out
-
- :usage
- echo USAGE: build realia OR build microfocus
- goto out
-
- :err
- echo An error occured during compilation ...
- :out