home *** CD-ROM | disk | FTP | other *** search
/ Piper's Pit BBS/FTP: ibm 0010 - 0019 / ibm0010-0019 / ibm0010.tar / ibm0010 / PROCLIB1.ZIP / LIB2.ZIP / CCWAT70.BAT < prev    next >
Encoding:
DOS Batch File  |  1990-08-20  |  1.2 KB  |  41 lines

  1. echo off
  2. cls
  3.  
  4. echo Compiling %1.c using Watcom V7.0
  5.  
  6. rem  ******************************************
  7. rem  Watcom V7.0 Compile and Link batch file 
  8. rem  ******************************************
  9. rem  Source file currently being compiled     = %1 
  10. rem  Name of EXE file placed in EXE directory = %2
  11. rem  Directory where the compiler/linker will find the Workbench
  12. rem  library Include files and compiler batch files = %3
  13. rem  Compiler error file = %4
  14. rem  Alternate Include directory = %5
  15.  
  16. rem  Compile the source file in large model 
  17. wcc %1.c >%4 /ml /zp2 /w0 /oilt /dANSI /dMSDOS /i%3 /i%5
  18.  
  19. rem  If errors occurred, copy them from the Watcom error file to ours
  20. if exist %3.err copy %3.err %4
  21.  
  22. rem  If an error occurs, abort...
  23. if errorlevel 1 goto done
  24.  
  25. rem  Compiled without error so delete the empty error file
  26. del %4
  27.  
  28. rem  Link the resulting object file to produce the executable 
  29. wlink name %2 file %2 library %3\supwat70 option stack=8192
  30.  
  31. rem  If errors occurred, copy them from the Watcom error file to ours
  32. if exist %3.err copy %3.err %4
  33.  
  34. rem  If an error occurs, abort...
  35. if errorlevel 1 goto done
  36.  
  37. rem  Delete the object file left behind
  38. del %2.obj
  39.  
  40. :done
  41.