home *** CD-ROM | disk | FTP | other *** search
/ Gold Fish 2 / goldfish_vol2_cd1.bin / files / dev / misc / p2c / aztec / pcompile.aztec < prev    next >
Encoding:
AmigaDOS Script File  |  1993-12-21  |  502 b   |  35 lines

  1. .key source/a,dest/a
  2. .bra {
  3. .ket }
  4.  
  5. FailAt 21
  6.  
  7. P2C {source} -a -o t:P2Ctmpfile.c
  8.  
  9. IF ERROR
  10.  
  11.   QUIT 20
  12.  
  13. ENDIF
  14.  
  15. ;insert the compiler options you want
  16. cc -fa -so t:P2Ctmpfile
  17.  
  18. IF ERROR
  19.   delete >NIL: t:P2Ctmpfile.c
  20.   echo "Fatal error: could not compile."
  21.   QUIT 20
  22. ENDIF
  23.  
  24. delete >NIL: t:P2Ctmpfile.c
  25. ;insert the linker libraries you want
  26. ln -o {dest} t:P2Ctmpfile -lp2c -lma -lc
  27.  
  28. IF ERROR
  29.   delete >NIL: t:P2Ctmpfile.o
  30.   echo "Fatal error: could not link."
  31.   QUIT 20
  32. ENDIF  
  33.  
  34. delete >NIL: t:P2Ctmpfile.o
  35.