[comp.sys.mips] A Loader question

ddh@hare.cdc.com (dd horsfall x-4622) (07/28/90)

OK, friends and neighbors, your opinion is solicited as follows:

I have a library, lib4.a, containing ~12 main programs and a small
plethora of subprograms.  According to the documentation (aha, there's
the man's first problem!), I ought to be able to load main program N, 
named pgmN, and its requisite subprograms, with  

(1)     ld -o pgmN -u pgmN lib4.a
thus producing executable file pgmN.  All _I_ can get, however is
        Usage: ld [options] files [...]

(2)     using 'cc' or 'f77' as the driver, inplace of 'ld', same thing
(3)     using pgmN_ as the Symbol Name, same again
(4)     using '-L. -l4' in place of explicitly naming lib4.a, same again
(5-7)   various combinations of above, just for completeness, same again.

The language is f77, although the diagnostic certainly doesn't indicate
a language dependency.  Machine is R3xxx, OS is 4.-not-sure.

[ Local advice to date has been, "Aw, Dan, you're _still_ trying to write 
  stuff for a cyber", with *bonehead* clearly implied. ]

One solution is obviously to keep 1 (smaller) library, sans main-pgms, 
and ~12 pgmN.o files, thus force-loading the proper main program and 
using the library for subprograms only.  However, since I ran across
'-u', that seemed to be worth looking at.  I also hoped -u was the path
whereby block data modules, which aren't explicitly called, might be 
included in the load.

O Net, where have I gone astray?
-- Horse
 [ Dan Horsfall     +1-612-482-4622    +    Control Data Corporation     ]
 [ internet = ddh@dash.udev.cdc.com    +    4201 Lexington Ave North     ]
 [ uucp = TBD                          +    Arden Hills MN 55126 USA     ]