* HOW? Dynamically load subroutine at runtime.
@ 1995-04-04 4:00 Tim Endres
0 siblings, 0 replies; only message in thread
From: Tim Endres @ 1995-04-04 4:00 UTC (permalink / raw)
I have an application with a common shell that wants to "plug in"
a subroutine to perform the computation. In other words, I wish
to produce a program that is missing one subroutine and then use
dlopen() to load the subroutine that I wish to use at runtime.
What I am very confused about is how to link the subroutine
to be loaded, and more importantly, the program that will load it.
I can not seem to get past the "unresolved external", and it
seems that anytime that I do I dump core as soon as I enter the
program and try to call fprintf().
Could someone please explain how to link the two files so that
I may use dlopen() to load and resolve a subroutine call at runtime?
Assume that the subroutine is in a file called "sub.c" and is
named "dyna_sub()", and assume that program is in a file named
"prgm.c", and its main() makes a call to "dyna_sub()".
thank you
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1995-04-04 4:00 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1995-04-04 4:00 HOW? Dynamically load subroutine at runtime Tim Endres
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox