[asterisk-dev] how to export symbols from app_ and chan_ objects?
Tilghman Lesher
tilghman at mail.jeffandtilghman.com
Mon Feb 20 15:43:52 MST 2006
On Monday 20 February 2006 15:49, Edwin Groothuis wrote:
> On Mon, Feb 20, 2006 at 06:02:05PM +0100, Olle E Johansson wrote:
> > >In chan_zap.c I have created a function which is used by a app_
> > >function (in this case, the counting of the number of active
> > > channels on a PRI. It will be used in a load-balancing function
> > > between two PRIs).
> > >
> > >Only problem is that the function in chan_zap.so doesn't get
> > > exported when it gets loaded. And AFAIK there is no other way of
> > > getting this information from a non-loadable-part of asterisk.
>
> > however, in the public version we usually create core interfaces
> > for this kind of
> > solutions so we do not make modules depend on each other. That is
> > why you
> > see modules registering for a lot of functions, like manager,
> > switches, voicemail and
> > others.
>
> True, but this is trickier: It's asking for channel driver specific
> information, for which at this moment I haven't found the proper
> abstraction function. If there is such one at all.
Why not simply write your app directly into chan_zap.c and use the
corresponding ast_register_application and ast_unregister_application
APIs? This is already being done for another app that needs similar
access to private zaptel channel structures.
--
Tilghman
More information about the asterisk-dev
mailing list