home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / fwktl101.zip / MK_ALP.CMD < prev    next >
OS/2 REXX Batch file  |  1996-05-28  |  2KB  |  74 lines

  1. @echo off
  2. cls
  3. if .%1 == . goto a
  4. if %1 == ? goto a
  5. if %1 == /? goto a
  6. if %1 == /* goto a
  7. if %1 == /h goto a
  8. if %1 == /H goto a
  9. goto b
  10. :a
  11. echo.Part of the FWKTL(TM) Text_program Launcher kit, version 1.01.
  12. echo (C)Copyright Frederick W. Kantor 1996. All rights reserved.
  13. echo.
  14. echo. MK_ALP.CMD for use with
  15. echo.            IBM Assembly Language Processor (ALP), Ver. 3.00.004 or later,
  16. echo.            LINK386, and
  17. echo.            FWKTRIM.EXE, version 1.01.
  18. echo.
  19. echo. Usage:   MK_ALP FILENAME (k) "<enter>"
  20. echo.
  21. echo.    where option  k  keeps the intermediate files (see below)
  22. echo.
  23. echo. Important: for input, use only the filename, without any file extension
  24. echo.
  25. echo.  Input files: FILENAME.ASM, FILENAME.DEF
  26. echo.
  27. echo. Output files: FILENAME.COM    for loading with FWKTL
  28. echo.
  29. echo.  IF k option: FILENAME.OBJ    intermediate step, made by ALP
  30. echo.               FILENAME.LST    code list, from ALP
  31. echo.               REPORT          describing work done by ALP
  32. echo.               FILENAME.MAP    byproduct of LINK386
  33. echo.               FILENAME.DLL    intermediate step, before stripping
  34. goto z
  35. :b
  36. if not exist %1.asm goto h0
  37. if not exist %1.def goto h1
  38. fwktrim /ver
  39. if errorlevel 102 goto h2
  40. if not errorlevel 101 goto h2
  41. echo on
  42. alp +Sme +Fl -Sfs -Sc +M:ALL+ +Lp:ALL %1.asm > report
  43. if errorlevel 1 goto y
  44. LINK386 /ALIGN:4 /PM:PM /BASE:0x010000 /RUNFROMVDM /NOS /L /M /NOF /NOP %1.obj,%1.dll,%1.map,,%1.DEF
  45. if errorlevel 1 goto y
  46. fwktrim < %1.dll > %1.com
  47. @echo off
  48. if .%2 == .k goto y
  49. if .%2 == .K goto y
  50. if exist %1.DLL del %1.DLL
  51. if exist %1.LST del %1.LST
  52. if exist %1.MAP del %1.MAP
  53. if exist %1.OBJ del %1.OBJ
  54. if exist REPORT del REPORT
  55. goto y
  56. :h0
  57. echo.
  58. echo. Did not find  %1.ASM
  59. goto x
  60. :h1
  61. echo.
  62. echo. Did not find  %1.DEF
  63. goto x
  64. :h2
  65. echo.
  66. echo. Need FWKTRIM.EXE version 1.01.
  67. :x
  68. echo.
  69. echo. Execution aborted.
  70. :y
  71. @echo off
  72. echo.
  73. :z
  74.