home *** CD-ROM | disk | FTP | other *** search
/ CP/M / CPM_CDROM.iso / cpm / utils / asmutl / link80.doc < prev    next >
Encoding:
Text File  |  1994-07-13  |  4.8 KB  |  122 lines

  1. 2.1.1    LINK-80 Command Strings
  2.     ------- ------- -------
  3.  
  4. To run LINK-80, type L80 followed by a carriage return.  Link-80 will return
  5. the prompt "*" indicating that it is ready to accept commands.    Each command
  6. to LINK-80 consists of a string of filenames and switches, separated by
  7. commas.
  8.  
  9. objdev1:filename.ext/switch1,objdev2:filename.ext/s,....
  10.  
  11. If the input device for a file is omitted, the default is the currently
  12. logged disk.  If the extension of a file is omitted, the default is .REL.
  13. After each line is typed, LINK will load or search (see /S below) the
  14. specified files.  After LINK finishes this process, it will list all symbols
  15. that remained undefined followed by an asterisk.
  16.  
  17.     Example:
  18.  
  19.     *TESTPROG
  20.  
  21.      DATA    0100    0200
  22.  
  23.      LABEL1     (label1 is undefined)
  24.  
  25.      DATA    0100    0300
  26.  
  27.     *LABEL1
  28.     */G        (starts execution - see below)
  29.  
  30. Typically, to execute a FORTRAN and/or COBOL program subroutines, the user
  31. types the list of filenames followed by /G (begin execution).  Before
  32. execution begins, LINK-80 will always search the system library (FORLIB.REL
  33. or COBLIB.REL) to satisfy any unresolved external references.  If the user 
  34. wishes to first search libraries of his own, he should append the filenames
  35. that are followed by /S to the end of the loader command string.
  36.  
  37. 2.1.2    LINK-80 Switches
  38.     ------- --------
  39.  
  40. A number of switches may be given in the LINK-80 command string to specify
  41. actions affecting the loading process.    Each switch must be preceded by
  42. a slash (/).  These switches are:
  43.  
  44. SWITCH        ACTION
  45. ------        ------
  46. R        Reset.    Put loader back in its initial state.  Use /R if
  47.         loaded the wrong file by mistake and want to restart.
  48.         /R takes effect as soon as it is encountered in a command
  49.         string.
  50.  
  51. E or E:Name    Exit LINK-80 and return to the Operating System.  The system
  52.         library will be searched on the current disk to satisfy any
  53.         existing undefined globals.  The optional form E:Name (where
  54.         Name is a global symbol previously defined in one of the
  55.         modules) uses Name for the start address of the program.
  56.         Use /E to load a program and exit back to the monitor.
  57.  
  58. G or G:Name    Start execution of the program as soon as the current command
  59.         line has been interpreted.  The system library will be searched
  60.         on the current disk to resolve existing undefined globals
  61.         (external references) if they exist.  Before execution begins,
  62.         LINK-80 prints three numbers and a BEGIN EXECUTION message.
  63.         The three numbers are the start address, the address of the
  64.         next available byte, and the number of 256-byte pages used.
  65.         The optional form G:Name (as with /E above) uses Name for
  66.         the start address of the program.
  67.  
  68. N        If a FILENAME/N is specified, the program will be saved on disk
  69.         under the selected name (with a default extension of .COM for
  70.         CP/M) when a /E or /G is done.    A jump to the start of the
  71.         program is inserted if needed so the program can run properly 
  72.         (at 100H for CP/M).
  73.  
  74. P and D     /P and /D allow the origin(s) to be set for the NEXT program
  75.         loaded.  /P and /D take effect when seen (not deferred), and
  76.         they have NO effect on programs already loaded.  The form is
  77.         P:ADDRESS> or /D:ADDRESS>, where ADDRESS> is the desired
  78.         origin in the current typeout radix.  (Default radix for
  79.         non-MITS versions is hex.  /O sets radix to octal; /H for hex.)
  80.         LINK-80 does a default /P:LINK origin>+3 (i.e., 103H for CP/M
  81.         and 4003H for ISIS) to leave room for the jump to the start
  82.         address.
  83.  
  84.         NOTE: Do not use /P or /D to load programs or data into the
  85.         locations of the loader's jump to the start address (100h to
  86.         102h for CP/M and 2800h to 2802h for DTC), unless it is to 
  87.         load the start of the program there.  If programs or data are
  88.         loaded into these locations, the jump will not be generated.
  89.  
  90.         If no /D is given, data areas are loaded before program areas
  91.         for each module.  If a /D is given, all Data and Common areas
  92.         are loaded starting at the data origin and the program area
  93.         at the program origin.
  94.         Example:
  95.         -------
  96.  
  97.         */P:200,F00
  98.         Data    200    300
  99.         */R
  100.         */P:200 /D:400,F00
  101.         Data    400    480
  102.         Program 200    280
  103.  
  104.  
  105. U        List the origin and end of the program and data area and all
  106.         undefined globals as soon as the current command line has been
  107.         interpreted.  The program information is only printed if a /D
  108.         has been done.    Otherwise, the program is stored in the data
  109.         area.
  110.  
  111. M        List the origin and end of the program and data area, all
  112.         defined globals and their values, and all undefined globals
  113.         followed by an asterisk.  The program information is only
  114.         printed if a /D has been done.    Otherwise, the program is
  115.         stored in the data area.
  116.  
  117. S        Search the filename immediately preceding the /S in the
  118.         command line to satisfy any undefined globals.
  119.  
  120. END OF FILE
  121. 
  122. S        Search the fi