| https://github.com/rsyslog/rsyslog/pull/93 |
| |
| This patch removes the static library from imuxsock.so and ensures |
| that all the objects from the librsyslog.a are included on rsyslogd. |
| |
| patch by Alex Deymo <deymo@chromium.org> |
| --- |
| diff --git a/plugins/imuxsock/Makefile.am b/plugins/imuxsock/Makefile.am |
| index 34a0ad9..8949ca8 100644 |
| --- a/plugins/imuxsock/Makefile.am |
| +++ b/plugins/imuxsock/Makefile.am |
| @@ -3,4 +3,4 @@ pkglib_LTLIBRARIES = imuxsock.la |
| imuxsock_la_SOURCES = imuxsock.c |
| imuxsock_la_CPPFLAGS = -DSD_EXPORT_SYMBOLS -I../../runtime/hashtable -I$(top_srcdir) $(PTHREADS_CFLAGS) $(RSRT_CFLAGS) |
| imuxsock_la_LDFLAGS = -module -avoid-version |
| -imuxsock_la_LIBADD = $(RSRT_LIBS) |
| +imuxsock_la_LIBADD = |
| diff --git a/tools/Makefile.am b/tools/Makefile.am |
| index 962ae50..cfe9e6b 100644 |
| --- a/tools/Makefile.am |
| +++ b/tools/Makefile.am |
| @@ -35,9 +35,10 @@ rsyslogd_SOURCES = \ |
| pidfile.h \ |
| \ |
| ../dirty.h |
| -rsyslogd_CPPFLAGS = $(PTHREADS_CFLAGS) $(RSRT_CFLAGS) |
| +rsyslogd_CPPFLAGS = $(PTHREADS_CFLAGS) $(RSRT_CFLAGS) -DSD_EXPORT_SYMBOLS |
| rsyslogd_LDADD = $(ZLIB_LIBS) $(PTHREADS_LIBS) $(RSRT_LIBS) $(SOL_LIBS) |
| -rsyslogd_LDFLAGS = -export-dynamic |
| +rsyslogd_LDFLAGS = -export-dynamic \ |
| + -Wl,--whole-archive,$(top_builddir)/runtime/.libs/librsyslog.a,--no-whole-archive |
| |
| if ENABLE_DIAGTOOLS |
| sbin_PROGRAMS += rsyslog_diag_hostname msggen zpipe |