On Sat, February 18, 2006 3:33 pm, Aaron Stone wrote:
> On Sat, 2006-02-18 at 04:47 -0500, Leif Jackson wrote:
>
>
>>> Either that or #ifdef (SIEVE || SHARED). The jury is out.
>>>
>>
>> You know as painfull as it can be this may be a good time to work out a
>>  loadable at runtime module system using function pointers.
>
> I did that two months ago ;-) dbmodule.c, authmodule.c, sortmodule.c
>

Sorry, shows how long it has been since I have really dug into dbmail's
source. I belive the problem is that sortmodule.c is not included in
libdbmail.so when --with-sieve is not on the configure line. And thus the
function not found issue.

However from the looks of my autoconf'ed compile tree the dbmodule
authmodule are not the only things being linked in at compile time:

gcc -g -O2 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include
-I/usr/include/gmime-2.0 -I/usr/include/glib-2.0
-I/usr/lib/glib-2.0/include -W -Wall -Wpointer-arith -Wstrict-prototypes
-o .libs/dbmail-smtp main.o  -L/usr/lib ./.libs/libdbmail.so
/root/projects/dbmail-svn-2.1.3-1987/modules/.libs/libmysql.so
-lmysqlclient -lm
/root/projects/dbmail-svn-2.1.3-1987/modules/.libs/libsort_sieve.so
/root/projects/dbmail-svn-2.1.3-1987/modules/.libs/libauth_sql.so
/usr/lib/libgmime-2.0.so -lgmodule-2.0 -ldl -lgthread-2.0 -lz -lnsl
-lgobject-2.0 -lglib-2.0 -lcrypt -Wl,--rpath -Wl,/usr/local/lib
-Wl,--rpath -Wl,/usr/local/lib/dbmail -Wl,--rpath -Wl,/usr/lib

Correct me if I am wrong but shouldn't "optional" modules shuch as
libsort_sieve.so be a config option for the library as well? and then
loaded when the config item is found only?

Leif


Reply via email to