Bug 518150

Summary: Move libnet.so.1 to /lib (for syslog-ng)
Product: [Fedora] Fedora EPEL Reporter: Ray Van Dolson <rayvd>
Component: libnetAssignee: Robert Scheck <redhat-bugzilla>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: high    
Version: el5CC: jarod, pertusus, rayvd, redhat-bugzilla, silfreed
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: 1.1.4-3.el4 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-08-21 14:25:44 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 518582    

Description Ray Van Dolson 2009-08-19 07:25:23 UTC
See http://koji.fedoraproject.org/koji/taskinfo?taskID=1613785

The last version syslog-ng links properly against is libnet-devel-1.1.2.1-11.el5.1 which provided a .a file.

Comment 1 Douglas E. Warner 2009-08-19 13:16:04 UTC
It looks like a newer libnet/libnet-devel is now in EPEL.  I'll have to investigate what is going on with the package.  I imagine the static symbols were pulled out that syslog-ng needs to link against.

Comment 2 Douglas E. Warner 2009-08-19 13:21:41 UTC
syslog-ng needs to statically link against libnet since the libraries are outside of /lib and might not be available if the system has an nfs-mounted /usr directory.  This is common for syslog packages.

Could you restore the static bindings to the -devel package or create a new -static package per the guidelines [1]?

If the static library was removed in other branches, could you restore it there as well?

[1] http://fedoraproject.org/wiki/Packaging:Guidelines#Packaging_Static_Libraries

Comment 3 Robert Scheck 2009-08-19 13:33:35 UTC
Static linkage is a special exception and should be decided on a case-by-case 
basis. The packager must provide rationale for linking statically, including 
precedences where available, to FESCO for approval. 

http://fedoraproject.org/wiki/Packaging:Guidelines#Staticly_Linking_Executables

For the moment, I don't see any reason, why syslog-ng should statically link to
libnet, we could move libnet library to /lib like we did for other libraries...

Comment 4 Douglas E. Warner 2009-08-19 14:00:15 UTC
syslog packages have commonly statically linked libraries outside /lib, so I don't have a problem bringing this up to FESCO if necessary.  Moving libnet to /lib would be fine as well but I feel that it should only be done in rawhide to avoid a rebuild of all packages that link against it (I don't know - maybe there aren't many).

Let me know what your thoughts are.  syslog-ng has been statically linked against libnet since practically forever, but I don't really mind which solution we choose.  I might have to look at the configure script to see if it currently supports dynamically linking libnet, but that's a technical concern that can probably be handled fairly easily.  I'd like to get the policy stuff done as quickly as possible.

Comment 5 Ray Van Dolson 2009-08-19 14:06:22 UTC
Wouldn't it also be a requirement that libnet be part of @Core (or something along those lines)?  Or is that only an issue for dynlibs linked against by the default syslog daemon?

Will have to read up on that.

Comment 6 Robert Scheck 2009-08-19 14:08:15 UTC
In the past, libnet only shipped a static library. This changed with the new
upstream. Moving a shared library shouldn't cause a rebuild of all packages
that link against - it's a shared library on a standard library path, whether
its /lib or /usr/lib shouldn't matter for the depending programs. If syslog-ng
uses libnet-config(1) as nearly all other depending packages do, it works out
of the box usually.

Comment 7 Robert Scheck 2009-08-19 14:09:28 UTC
@Core? Why? Dependencies are getting satisfied automagically?! And syslog-ng
has not a wide usage compared with syslog/rsyslog, sorry.

Comment 8 Patrice Dumas 2009-08-19 14:11:18 UTC
(In reply to comment #4)
>   Moving libnet to
> /lib would be fine as well but I feel that it should only be done in rawhide to
> avoid a rebuild of all packages that link against it (I don't know - maybe
> there aren't many).

I can't see why there would be a need to rebuild packages that link against libnet if libnet is moved to /lib. Wouldn't the linker find it in /lib as well as in %_prefix/lib/? In any case the -devel content (the .so and include files) should still be in %_prefix.

Comment 9 Douglas E. Warner 2009-08-19 14:18:26 UTC
(In reply to comment #6)
> In the past, libnet only shipped a static library. This changed with the new
> upstream. Moving a shared library shouldn't cause a rebuild of all packages
> that link against - it's a shared library on a standard library path, whether
> its /lib or /usr/lib shouldn't matter for the depending programs. If syslog-ng
> uses libnet-config(1) as nearly all other depending packages do, it works out
> of the box usually.  

Sounds good; I wasn't sure that it would be handled properly if the library location moved.  If you're happy with moving libnet's library path I'll look into getting syslog-ng to link dynamically against it.

(In reply to comment #7)
> And syslog-ng has not a wide usage compared with syslog/rsyslog, sorry.  

While syslog-ng might not be the default syslog provider, it does have a wide user base and is very popular.

Comment 10 Robert Scheck 2009-08-20 13:48:24 UTC
Fix for syslog-ng is in syslog-ng-2.1.4/configure.in, change:

  DEPS_LIBS="$LIBS $LD_START_STATIC $LEXLIB $GLIB_LIBS $EVTLOG_LIBS $LIBNET_LIBS $LIBWRAP_LIBS $LD_END_STATIC $LIBDBI_LIBS $DL_LIBS"

to

  DEPS_LIBS="$LIBS $LD_START_STATIC $LEXLIB $GLIB_LIBS $EVTLOG_LIBS $LIBWRAP_LIBS $LD_END_STATIC $LIBNET_LIBS $LIBDBI_LIBS $DL_LIBS"

for example. I don't know why there's static linking in EPEL anyway? I assume
you've checked, that static (mixed) linking on EPEL is really needed?

Let me know if this change works for you. If yes, I'll move libnet.so.* to the
/%{_lib} location as talked above.

Comment 11 Ray Van Dolson 2009-08-21 03:53:45 UTC
Doug, see the following:

http://rayvd.fedorapeople.org/syslog-ng/syslog-ng.spec
http://rayvd.fedorapeople.org/syslog-ng/syslog-ng-2.1.4-4.src.rpm
http://rayvd.fedorapeople.org/syslog-ng/syslog-ng-2.1.4-libnet.patch

The patch is applied only on EL systems as syslog-ng seems to build fine under mock for Fedora.

Comment 12 Robert Scheck 2009-08-21 11:16:50 UTC
I think you need to run autoconf after touching configure.in. Otherwise you
have to patch configure as well.

Comment 13 Ray Van Dolson 2009-08-21 14:02:50 UTC
Yep, had to pull in autoconf as a BuildRequires.  It appears to be doing the right thing (didn't have to call it manually).

Comment 14 Fedora Update System 2009-08-21 14:23:30 UTC
libnet-1.1.4-3.el4 has been submitted as an update for Fedora EPEL 4.
http://admin.fedoraproject.org/updates/libnet-1.1.4-3.el4

Comment 15 Fedora Update System 2009-08-21 14:23:38 UTC
libnet-1.1.4-3.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/libnet-1.1.4-3.el5

Comment 16 Fedora Update System 2009-08-21 14:23:48 UTC
libnet-1.1.4-3.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/libnet-1.1.4-3.fc10

Comment 17 Fedora Update System 2009-08-21 14:23:55 UTC
libnet-1.1.4-3.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/libnet-1.1.4-3.fc11

Comment 18 Robert Scheck 2009-08-21 14:25:44 UTC
The libnet part is done, closing this bug report.

Comment 19 Fedora Update System 2009-08-25 04:31:21 UTC
libnet-1.1.4-3.fc11 has been pushed to the Fedora 11 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 20 Fedora Update System 2009-08-25 04:42:39 UTC
libnet-1.1.4-3.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 21 Fedora Update System 2009-09-10 22:54:58 UTC
libnet-1.1.4-3.el5 has been pushed to the Fedora EPEL 5 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 22 Fedora Update System 2009-09-10 22:56:22 UTC
libnet-1.1.4-3.el4 has been pushed to the Fedora EPEL 4 stable repository.  If problems still persist, please make note of it in this bug report.