Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[vdr] Re: make plugins



Am Freitag, 11. Juli 2003 17:25 schrieb Gunnar Roth:
> >>is there a way to get an error about unresolved symbols when linking a
> >>plugin?
> >
> >Yes, there is. When the plugin is loaded, all functions in the dynamic
> > table of the plugin need to be resolved. If a function cannot be
> > resolved, VDR will terminate.
>
> But the question was, if there is a possibility to determine the
> unresolved symbol at linking time, NOT at run time.

ah... (but you can understand the other way, if "linking" means linking at run 
time ;-)  )

To the question: gcc does not (and must not) know into which executable the 
library will be loaded. However, there are two things you can do:
- link VDR's object files with the object files of the plugin (or the plugin 
library) and create a dummy executable. The linker will give the errors 
wanted.
- read the plugin's dynamic relocation table with
objdump -CT libvdr-myplugin.so | grep "UND" | less
and find symbols which should be defined in the plugin.

Marcel


-- 
Info:
To unsubscribe send a mail to ecartis@linuxtv.org with "unsubscribe vdr" as subject.



Home | Main Index | Thread Index