[syslog-ng] linking changes

Marius Tomaschewski mt at suse.de
Wed Feb 23 15:15:11 CET 2011


Am Mittwoch, 23. Februar 2011, 14:52:18 schrieb Balazs Scheidler:
> On Wed, 2011-02-23 at 14:31 +0100, Corinna Vinschen wrote:
> > On Feb 23 14:11, Balazs Scheidler wrote:
> > > On Wed, 2011-02-23 at 13:57 +0100, Corinna Vinschen wrote:
> > > > On Feb 23 13:05, Balazs Scheidler wrote:
> > > > > Hi,
> > > > > 
> > > > > I've tried to put a closure on how syslog-ng 3.2 and above is being
> > > > > linked. There were numerous problems as it started to get into
> > > > > Linux distributions.
> > > > > [...]
> > > > > Also, the main syslog-ng executable is not linked against
> > > > > libssl/libcrypto on purpose, it is only used by the afsocket module
> > > > > (which implements the tcp/syslog destinations).
> > > > > 
> > > > > Could anyone who is in charge of maintaining syslog-ng binaries in
> > > > > various distributions give this a test so 3.2.3 will compile
> > > > > everywhere out-of-the-box?
> > > > 
> > > > Sorry, but this won't work for the Cygwin distro.  The changes don't
> > > > take my patch from
> > > > https://lists.balabit.hu/pipermail/syslog-ng/2011-February/016007.htm
> > > > l into account.
> > > 
> > > I understand that, but pdbtool doesn't open libdbparser.so anymore and
> > > libsyslog-ng-patterndb.so has been removed and I link that into pdbtool
> > > statically.
> > > 
> > > Rechecking the patch you referenced, the only important difference is
> > > that you mark the convenience library with noinst_ whereas my patch
> > > installs that publicly (which indeed is a bug).
> > > 
> > > Am I missing something else?
> > 
> > Well, yes.  As outlined in
> > https://lists.balabit.hu/pipermail/syslog-ng/2011-February/016006.html
> > there are two problems:
> > 
> > - You can't link against a static lib when creating a shared lib.  That
> > 
> >   means, creating libdbparser.so will fail.  My patch results in
> >   creating a shared libsyslog-ng-patterndb.so for linking libdbparser.so,
> >   and a static libsyslog-ng-patterndb.a for linking pdbtool.
> >   Marking both libsyslog-ng-patterndb as noinst is just to avoid that
> >   both convenience libs are installed.
> 
> hmm.. not even with -fPIC ? If I have to duplicate executable code into
> pdbtool anyway (because of static linking it), I'd rather not have a
> separate .so which is only loaded by an .so.
> 
> If that's the case, I'd include the same source files into both targets
> (the .la one and pdbtool one)

This seems to be the easiest way :-)

Gruesse / Regards,
 Marius Tomaschewski <mt at suse.de> <mt at novell.com>
--
 Server Technologies Team, SUSE LINUX Products GmbH,
 Nuernberg; GF: Markus Rex; HRB 16746 (AG Nuernberg)
 GPG/PGP public key fingerprint:
 DF17 271A AD15 006A 5BB9   6C96 CA2F F3F7 373A 1CC0


More information about the syslog-ng mailing list