+++ /dev/null
---- syslog-ng-3.2.4/configure.in~ 2011-05-04 17:45:07.000000000 +0200
-+++ syslog-ng-3.2.4/configure.in 2011-05-30 20:09:43.852080011 +0200
-@@ -770,7 +770,7 @@
- else
- SYSLOGNG_DEPS_LIBS="$LIBS $BASE_LIBS $RESOLV_LIBS $LD_START_STATIC -Wl,--whole-archive $GLIB_LIBS $EVTLOG_LIBS $PCRE_LIBS $REGEX_LIBS -Wl,--no-whole-archive $LD_END_STATIC $LIBCAP_LIBS $DL_LIBS "
- TOOL_DEPS_LIBS="$LIBS $BASE_LIBS $GLIB_LIBS $EVTLOG_LIBS $RESOLV_LIBS $LIBCAP_LIBS $PCRE_LIBS $REGEX_LIBS $DL_LIBS"
-- CORE_DEPS_LIBS=""
-+ CORE_DEPS_LIBS="$LD_START_STATIC -Wl,--whole-archive $GLIB_LIBS $EVTLOG_LIBS -Wl,--no-whole-archive $LD_END_STATIC $LIBCAP_LIBS"
-
- # bypass libtool in case we want to do mixed linking because it
- # doesn't support -Wl,-Bstatic -Wl,-Bdynamic on a per-library basis.
# Source4-md5: 4fa86dc863ed0206c004b3be7292bcbf
Source5: %{name}-simple.conf
Source6: %{name}.upstart
-Patch0: %{name}-link.patch
-Patch1: %{name}-datadir.patch
+Patch0: %{name}-datadir.patch
URL: http://www.balabit.com/products/syslog_ng/
BuildRequires: autoconf >= 2.53
BuildRequires: automake
Conflicts: syslog
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+# syslog-ng has really crazy linking rules (see their bugzilla).
+# Some rules, according to syslog-ng devs, are like this:
+# - libsyslog-ng.so has undefined symbols for third party libraries
+# and these symbols should go via main syslog-ng binary
+# - same applies for modules
%if %{without dynamic}
%define no_install_post_check_so 1
+# filterout_ld - see comment few lines above
+%define filterout_ld -Wl,--as-needed -Wl,--no-copy-dt-needed-entries
%define _sbindir /sbin
%define _libdir /%{_lib}
%endif
%prep
%setup -q
%patch0 -p1
-%patch1 -p1
cp -a %{SOURCE4} doc
cp -a %{SOURCE5} contrib/syslog-ng.conf.simple