[comp.sys.apollo] Dynamic linking of modules

krause@prlhp1.prl.philips.co.uk (krause) (07/20/90)

I would like to dynamically link modules together. A central core of code can 
then call proceedures whose names are not known to the core at compile or link
time. The names are provided to the core either by parameters, or by lookup
in a file. 

One way to do this is to inlib modules containing the procedures when required,
and then look up the addresses and call the address as a pointer to a 
proceedure. The snag is I cannot find the address of anything in an inlibed 
file. 

I have tried inlibing a binary file, and then using loader_$kg_symbol to find
the address of a proceedure in the file. Loader_$kg_symbol will return a set of
flags telling me that it has found the proceedure, but returns 0 as the address
of the proceedure. 

Does anyone know if loader_$kg_symbol should return the address of a symbol? My
reading of the manual suggests that it should. Failing that is there a better
way of finding the address of an inlibed symbol?

Many thanks in advance

David Krause