Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought



     OS2LD(CP)                 UNIX System V                 OS2LD(CP)



     Name
          os2ld - OS/2 cross linker

     Syntax
          os2ld [ options ]  file ...

     Description
          os2ld links the object files(s) given by file to create a
          program for execution under OS/2.  Although similar to
          ld(CP), os2ld has many options that differ significantly
          from ld.  The options are described below:

          -B   Produce a .COM file. This instructs os2ld to produce an
               executable .COM file.

          -D   DS Allocate.  This instructs os2ld to perform DS
               allocation.  It is generally used in conjunction with
               the -H option.

          -H   Load high.  This option instructs os2ld to set a field
               in the header of the executable file to tell OS/2 to
               load the program at the highest available position in
               memory.  It is most often used with programs in which
               data precedes code in the memory image.

          -L   Include line numbers.  This option instructs os2ld to
               include line numbers in the listing file (if any).
               Note that os2ld cannot put line numbers in the listing
               file if the source translator hasn't put them in the
               object file.

          -M   Include public symbols.  This option instructs os2ld to
               include public symbols in the list file.  The symbols
               are sorted twice, lexicographically and by address.

          -C   Ignore case. This option instructs os2ld to treat upper
               and lower case characters in symbol names as identical.

          -F num
               Set stack size. This option should be followed by a
               hexadecimal number. os2ld will use this number for the
               size in bytes of the stack segment in the output file.

          -P   Pack code segments.

          -Pc[<dec#>]
               Pack code segments; the default limit for a segment is
               64k minus 36.

          -Pd[<dec#>]
               Pack data segments; default limit is 64k.

          -Q   Don't pack code segments; this option is the default
               for segmented-executable pack code.

          -S num
               Set segment limit.  This option should be followed by a
               decimal number between 1 and 1024.  The number sets the
               limit on the number of different segments that may be
               linked together.  The default is 128.  Note that the
               higher the value given, the slower the link will be.

          -m filename
               Create map file.  This option should be followed by a
               filename.  os2ld will create a file with the given name
               in which it will put information about the segments and
               groups in the executable.  Additionally, public symbols
               and line numbers will be listed in this file if the -M
               and -L options are given.

          -nl num
               Set name length.  This option should be followed by a
               decimal number.  The option instructs os2ld to truncate
               all public and external symbols longer than num
               characters.

          -o filename
               Name output file.  This option should be followed by a
               filename which os2ld will use as the name of the
               executable file it creates.  The default name is a.out.

          -u name
               Name undefined symbol.  This option should be followed
               by a symbol name.  os2ld will enter the given name into
               its symbol table as an undefined symbol.  The -u option
               may appear more than once on the command line.

          As with ld, the files passed to os2ld may be either UNIX-
          style libraries (objects collected using ar(CP) and indexed
          using ranlib(CP)) or ordinary 8086 object files.  Unless the
          -u option appears, at least one of the files passed to os2ld
          must be an ordinary object file.  Libraries are searched
          only after all the ordinary object files have been
          processed.

     Files
          /usr/bin/os2ld

     See Also
          ar(CP), as(CP), cc(CP), dosld(CP), ld(CP), ranlib(CP)

     Value Added
          os2ld is an extension of AT&T System V provided by the Santa
          Cruz Operation.

                                                (printed 6/21/89)



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026