Summary:ASTERISK-10378: Should be able to dynamically link against libc-client for IMAP storage
Reporter:Faidon Liambotis (paravoid)Labels:
Date Opened:2007-09-24 01:47:02Date Closed:2011-06-07 14:08:07
Versions:Frequency of
Environment:Attachments:( 0) dynamic-libc-client.diff
Description:Currently, "configure" allows you only to link against libc-client (for IMAP storage) statically.

On Debian, we have the libc-client2006j2 package which only provides a shared object for us to link against.
That's the correct behavior for the obvious benefits that dynamic linking has.

Attached is a simple patch that we have in our tree for "configure.ac" (it's for "configure" too, so that we don't have to run autoconf and diverge too much from upstream sources) that switches to -lc-client.

The linker will dynamically link if a .so is found or will switch to static linking if only .a is found.
I can see no reason why your scripts were looking c-client.a under ${IMAP_TK_DIR}/c-client/ but if there's a good reason, you should probably add -L${IMAP_TK_DIR}/c-client to the link options to keep old behavior.
Comments:By: Mark Michelson (mmichelson) 2007-09-24 14:48:17

I strongly agree with your assessment of the situation. The only thing is that we can't put this in the 1.4 branch since this is actually a new feature. Please upload a trunk version of the patch.

Thank you very much!

By: Tilghman Lesher (tilghman) 2007-11-01 16:42:58

Suspended, due to no response in over a month.  Reopen if/when you are able to provide a patch against trunk.

By: Faidon Liambotis (paravoid) 2007-11-01 19:05:55

Well, I'm not currently able to provide a patch against trunk because of lack of time.
But it *is* a bug and it is confirmed.
I don't understand why it should be closed without being fixed (eventually).

By: Tilghman Lesher (tilghman) 2007-11-01 21:59:33

Well, it's not a bug, specifically (have a crash?), but it is interesting, but there hasn't been an update in over a month, so it's being suspended.

As I said before, reopen WHEN you have a patch for trunk, not reopen because you think it needs it needs to be open for you to think about ever providing an updated patch (especially since that didn't work over the past month).