[syslog-ng] Newer libtool and autoconf versions?

Balazs Scheidler bazsi at balabit.hu
Mon Dec 13 20:13:15 CET 2010


On Fri, 2010-12-10 at 17:57 +0100, Corinna Vinschen wrote:
> On Dec 10 10:30, Corinna Vinschen wrote:
> > On Dec  9 21:13, Balazs Scheidler wrote:
> > > So for now, I can only promise to migrate to autoconf 2.67, but I'm
> > > reluctant to upgrade to libtool 2.4, so the autoreconf stuff will be
> > > needed for a little while.
> > 
> > Ok, thank you.  I can live with that.
> > 
> > Especially since even with libtool 2.4 there's still a problem.  Due to
> > the way shared libs are handled on Windows, ther's a hardcoded mechanism
> > in libtool which doesn't work overly well with syslog-ng.  When
> > installing the shared libs into $(localstatedir), libtool copies the .a
> > (static lib) and .dll.a (link stub for DLL) files into that directory,
> > while the actual module DLLs are copied to $(localstatedir)/../bin.  My
> 
> Sorry, I messed up here.  Make these directories $(libexecdir)/syslog-ng
> and $(libexecdir)/syslog-ng/../bin .
> 
> > contrib/cygwin-packaging/cygwin-postinstall script fixes this situation.
> > It removes the .a and .dll.a files and moves the DLLs over to
> > /usr/lib/syslog-ng.  That works, but I'd be glad to find a solution
> > which does the right thing already at `make install' time, not only
> > after applying some postinstall magic.  I'll investigate this further.
> 
> I just got the hint that the libtool --mode=link option "-module" is
> supposed to do exactly this on Cygwin.  I tested it and with this
> option the subsequent `make install' actually copies the DLLs into the
> $(libexecdir)/syslog-ng directory where they belong.
> 
> I checked that the -module option is already known to libtool 2.2.6, so
> it seems it would make sense to add this option generically to the
> Makefile.am files in the modules subdirectories, along these lines.
> 
> --- SNIP ---
> diff --git a/modules/affile/Makefile.am b/modules/affile/Makefile.am
> index 9917ebf..04dbaae 100644
> --- a/modules/affile/Makefile.am
> +++ b/modules/affile/Makefile.am
> @@ -12,6 +12,6 @@ EXTRA_DIST = $(BUILT_SOURCES) affile-grammar.ym
>  
>  libaffile_la_CPPFLAGS = $(AM_CPPFLAGS)
>  libaffile_la_LIBADD = ../../lib/libsyslog-ng.la
> -libaffile_la_LDFLAGS = -avoid-version
> +libaffile_la_LDFLAGS = -avoid-version -module
>  
>  include $(top_srcdir)/build/lex-rules.am
> --- SNAP ---
> 
> Would that be ok with you?

It used to be "-avoid-version -module" but it was removed by this
commit:

Author: Balazs Scheidler <bazsi at balabit.hu>  2010-09-27 15:51:22
Committer: Balazs Scheidler <bazsi at balabit.hu>  2010-09-27 15:51:22
Parent: f437439a9c28555271b1298eeaf6e962ec626cc1 (use -avoid-version for modules)
Follows: v3.2alpha1
Precedes: v3.2beta1

    modules: don't use -module libtool option
    
    As it causes a libtool warning when linking the module explicitly to
    a program and it worked without that on all of our platforms anyway.

The problem is that I'm linking pdbtool against the libdbparser.so file
and the unit tests and using -module causes a lot of warnings during
compilation.

Do you perhaps have an idea how otherwise work around the warning?

> 
> > Anyway, for the time being, the new cygwin-postinstall script
> > (https://bugzilla.balabit.com/show_bug.cgi?id=103) will do the job.
> 
> If the aforementioned -module option is a viable approach, I would have
> to change the contrib/cygwin-packaging/cygwin-postinstall script again,
> so in this case I would upload a new patch to bugzilla issue 103.



-- 
Bazsi




More information about the syslog-ng mailing list