home *** CD-ROM | disk | FTP | other *** search
/ ftp.barnyard.co.uk / 2015.02.ftp.barnyard.co.uk.tar / ftp.barnyard.co.uk / cpm / walnut-creek-CDROM / CPM / LANGUAGS / PASCAL-P / PP319DOC.LBR / STARTUP.MZN / STARTUP.MAN
Text File  |  2000-06-30  |  5KB  |  116 lines

  1. .macro chttl = Getting Started
  2. .ch .chttl
  3.  
  4. .note CPM version
  5. This chapter is directed towards CPM 2.2 users.  Other systems must
  6. make slight modifications, especially MS/PCDOS users.
  7. .hl 1 Files needed.
  8. To compile and execute Pascal programs you should have available:
  9.  
  10. .list 1
  11. .le RUNPCD.COM (and possibly RUNPCDI.COM).  These are distributed
  12.     as INTERP.COM and INTERPI.COM, and may be renamed as is, or
  13.     customized for access to system timers.
  14. .le PASCALP.PCD, the compiler
  15. .le either ASSMPCD.COM or ASSMPCD.PCD.  The _.PCD version is much
  16.     more compact, but significantly slower in execution.
  17. .le (optional) EF (no extension). The error messages file for compilation.
  18. .le (optional) PCDHELP.PCD, which is executed by RUNPCD whenever
  19.     no code file is specified.  This gives on-line information.
  20. .le Your favorite text editor.
  21. .endlist .b
  22.  
  23. For _.COM file generation under CPM you will also need: .b
  24. .list 1
  25. .le SLRMAC.COM from SLR systems (Z80ASM may also be used).
  26. .le SLRNK.COM from SLR systems
  27. .le PASCLIB.SLR.  The run-time library.
  28. .le CPMLINK.SLR.  The master interface to CPM
  29. .le (optional) HEAPMARK.SLR (allows reduced object size when no
  30.     use of the DISPOSE procedure is made).
  31. .le (optional) ERRMSGL.SLR (allows more elaborate run-time error
  32.     messages. The "L" stands for long.)
  33. .endlist
  34.  
  35. Also recommended, for convenience:
  36. .list 1
  37. .le JOB.COM.  The improved replacement for SUBMIT.
  38. .le JOBS.LBR (or extractions of COMPILE.JOB and/or PASCPREP.JOB) to
  39.     allow single command compilation.
  40. .endlist
  41.  
  42. .note    ASSMPCD and ASSMAP.COM
  43. If you use these rather than the _.PCD versions simply omit the
  44. "runpcd#" prefix for them in the following.
  45. .res
  46. .hl 1 Creating _.PCD programs
  47. To compile the source program YOURPROG.PAS to a _.PCD file, do: .b
  48. .i 10 runpcd pascalp (yourprog.pas, con, yourprog.tic) .b
  49. where "con" (the console) will receive the list file, and "yourprog.tic"
  50. will receive the temporary intermediate code.  At completion enter: .b
  51. .i 10 runpcd assmpcd (yourprog.tic,yourprog.pcd) .b
  52. If JOB.COM and COMPILE.JOB are available (COMPILE.JOB may be a component of
  53. JOBS.LBR) this can all be simplified to: .b
  54. .i 10 job compile yourprog .b
  55. At completion YOURPROG.TIC may be erased. To then execute yourprog, enter: .b
  56. .i 10 runpcd yourprog .b
  57.  
  58. .hl 1 Creating _.COM programs
  59. To compile the source program YOURPROG.PAS to a _.COM file, do: .b
  60. .i 10 runpcd pascalp (yourprog.pas, con, yourprog.tic) .b
  61. just as for a _.PCD file.  If you have saved the _.TIC file from a previous
  62. compilation (above) this step can be eliminated. .b
  63. .i 10 runpcd assmap (yourprog.tic, yourprog.mac) .b
  64. Again, at completion YOURPROG.TIC may be erased, unless required to create
  65. a _.PCD executable file.  If you are going to use Z80ASM in place of SLRMAC
  66. add "[64]" to the above command line, replace ".mac" with ".z80", and 
  67. replace "slrmac" with "z80asm" in the following step.  The resultant
  68. intermediate source file will be about 10% larger, but the final code will
  69. be unchanged. .b
  70. .i 10 slrmac yourprog.@@z/rf .b
  71. will assemble the _.MAC source file.  At completion YOURPROG.SLR will have
  72. been created, and the _.MAC file is no longer needed.  (If you have not
  73. configured SLRMAC to use the _.SLR extension, change the extension
  74. accordingly) .b
  75. .i 10 slrnk /a:100,cpmlink,yourprog,pasclib/s,yourprog/n,/e .b
  76. will do the complete linking, and leave you with YOURPROG.COM. .b
  77. Again, if JOB.COM and PASCPREP.JOB are available (PASCPREP.JOB may be
  78. a component of JOBS.LBR) this can be simplified to: .b
  79. .i 10 job pascprep yourprog .b
  80. YOURPROG can then be executed just like any other program.
  81.  
  82. .hl 1 Using PCDS.LBR
  83. Any _.PCD file may be stored in PCDS.LBR, and RUNPCD will find and
  84. load it whenever no file.PCD is found.  Since _.PCD files tend to
  85. be small, this can result in significant savings in disk storage.
  86.  
  87. .hl 1 Connecting files to programs
  88. The standard input and output may always be redirected by including
  89. ">outputfile" and/or "_<inputfile" on the command line.  This applies
  90. to both _.COM and _.PCD programs.  Other external files should have
  91. been described in the program header line, and are simply described
  92. as parameters to the program by suitable replacements within parenthesis
  93. in the command line.  Any unspecified file will be attached to the
  94. default name, which is the name used in the source program, with no
  95. extension.  The standard input and output must be text files, but other
  96. files may be of any type.
  97.  
  98. Standard device file names available (on CPM) are:
  99. .list 1
  100. .le CON the console for output, keyboard for input.  Lines are buffered
  101. and input lines can be edited.
  102. .le KBD The console for output, keyboard for input.  No buffering.
  103. .le RDR The system RDR: device.  Input lines are buffered, but may not
  104. be edited.
  105. .le PUN The system PUN: device. No buffering.
  106. .le LST The system LST: device. No buffering.
  107. .le AUX The system RDR: device, no input buffering.
  108. .endlist
  109. All these file are textfiles.
  110. .hl 1 Using CCP+ (and possibly DOS+)
  111. If you have installed CCP+ in your system, together with CCPXTEND.SYS,
  112. you can omit the "runpcd" prefixes.  The system will automatically
  113. execute RUNPCD if no _.COM file is found.
  114.  
  115.  
  116. â