Re: [Hamlib-developer] backend lib loading strategy.
Library to control radio transceivers and receivers
Brought to you by:
n0nb
|
From: Stephane F. <f4...@fr...> - 2000-10-01 21:49:52
|
Frank Singleton wrote:
>
> 1. frontend should load appropriate backend lib
> at say, rig_init or similar.
nope, rig_init is already in use. init_rig isn't ;-)
>
> 2. multiple instances of same RIG type should not
> cause multiple dl_open requests ??
>
sure not. Actually, the backend won't be loaded
by rig type, but by backend lib!
using something like rig_load_backend("ft847");
which would load libhamlib-ft847.so and register it.
> 3. Must have way of resolving symbol names for
> dlsym(handle, "symbol_name"); stuff.
>
We need to call dlsym() only once, ie. when the frontend
resolves the init_rig symbol. Then, the init_rig function
will register the capabilities in the frontend rig list.
And that's it! Thanks to the cool API design.
> 4. A whole lot more to come, but you see the idea.
>
Well, very much. The registering and rig_load_backend()
are coded, and are working fine! There's only a couple of
lines to add in a backend to support it!
I haven't commited this code yet, just to let you some time
to catch up with the last commit. I will do on monday.
> 5. GNU libtool ??
>
done already with autoconf/automake stuff
> 6. Lots of other stuff to follow...
>
yup, sure!
--
Stephane Fillod F4CFE
|