|
|
@@ -0,0 +1,129 @@
|
|
|
+##
|
|
|
+## syslog-ng.spec -- OpenPKG RPM Specification
|
|
|
+## Copyright (c) 2000-2003 The OpenPKG Project <http://www.openpkg.org/>
|
|
|
+## Copyright (c) 2000-2003 Ralf S. Engelschall <rse@engelschall.com>
|
|
|
+## Copyright (c) 2000-2003 Cable & Wireless <http://www.cw.com/>
|
|
|
+##
|
|
|
+## Permission to use, copy, modify, and distribute this software for
|
|
|
+## any purpose with or without fee is hereby granted, provided that
|
|
|
+## the above copyright notice and this permission notice appear in all
|
|
|
+## copies.
|
|
|
+##
|
|
|
+## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
|
|
|
+## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
|
|
+## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
|
|
+## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
|
|
|
+## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
|
+## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
|
|
+## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
|
|
|
+## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
|
|
|
+## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
|
|
+## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
|
|
+## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
|
+## SUCH DAMAGE.
|
|
|
+##
|
|
|
+
|
|
|
+# package version
|
|
|
+%define V_sl_major 1.6
|
|
|
+%define V_sl_minor 0rc4
|
|
|
+%define V_ol_major 0.3
|
|
|
+%define V_ol_minor 11
|
|
|
+
|
|
|
+# package information
|
|
|
+Name: syslog-ng
|
|
|
+Summary: Syslog Daemon
|
|
|
+URL: http://www.balabit.com/products/syslog_ng/
|
|
|
+Vendor: Balázs Scheidler
|
|
|
+Packager: The OpenPKG Project
|
|
|
+Distribution: OpenPKG [EVAL]
|
|
|
+Group: System
|
|
|
+License: GPL
|
|
|
+Version: %{V_sl_major}.%{V_sl_minor}
|
|
|
+Release: 20031102
|
|
|
+
|
|
|
+# list of sources
|
|
|
+Source0: http://www.balabit.com/downloads/syslog-ng/%{V_sl_major}/src/syslog-ng-%{V_sl_major}.%{V_sl_minor}.tar.gz
|
|
|
+Source1: http://www.balabit.com/downloads/libol/%{V_ol_major}/libol-%{V_ol_major}.%{V_ol_minor}.tar.gz
|
|
|
+Source2: rc.syslog-ng
|
|
|
+Source3: syslog-ng.conf
|
|
|
+
|
|
|
+# build information
|
|
|
+Prefix: %{l_prefix}
|
|
|
+BuildRoot: %{l_buildroot}
|
|
|
+BuildPreReq: OpenPKG, openpkg >= 20030103
|
|
|
+PreReq: OpenPKG, openpkg >= 20030103
|
|
|
+AutoReq: no
|
|
|
+AutoReqProv: no
|
|
|
+
|
|
|
+%description
|
|
|
+ syslog-ng is a syslogd(8) replacement, but with new functionality
|
|
|
+ for the new generation. The original syslogd allows messages only
|
|
|
+ to be sorted based on priority/facility pairs; syslog-ng adds the
|
|
|
+ possibility to filter based on message contents using regular
|
|
|
+ expressions. The new configuration scheme is intuitive and powerful.
|
|
|
+ Forwarding logs over TCP and remembering all forwarding hops makes
|
|
|
+ it ideal for firewalled environments.
|
|
|
+
|
|
|
+%prep
|
|
|
+ %setup -q
|
|
|
+ %setup -q -T -D -a 1
|
|
|
+
|
|
|
+%build
|
|
|
+ # configure and build libol
|
|
|
+ ( cd libol-%{V_ol_major}.%{V_ol_minor}
|
|
|
+ CC="%{l_cc}" \
|
|
|
+ CFLAGS="%{l_cflags -O}" \
|
|
|
+ CPPFLAGS="%{l_cppflags}" \
|
|
|
+ LDFLAGS="%{l_ldflags}" \
|
|
|
+ ./configure \
|
|
|
+ --prefix=%{l_prefix} \
|
|
|
+ --disable-shared
|
|
|
+ %{l_make} %{l_mflags -O}
|
|
|
+ ) || exit $?
|
|
|
+
|
|
|
+ # configure and build syslog-ng
|
|
|
+ %{l_shtool} subst \
|
|
|
+ -e 's;ACLOCAL=aclocal;ACLOCAL=true;g' \
|
|
|
+ -e 's;AUTOCONF=autoconf;AUTOCONF=true;;' \
|
|
|
+ -e 's;AUTOMAKE=automake;AUTOMAKE=true;;' \
|
|
|
+ -e 's;AUTOHEADER=autoheader;AUTOHEADER=true;;' \
|
|
|
+ -e 's;MAKEINFO=makeinfo;MAKEINFO=true;;' \
|
|
|
+ configure
|
|
|
+ CC="%{l_cc}" \
|
|
|
+ CFLAGS="%{l_cflags -O}" \
|
|
|
+ CPPFLAGS="%{l_cppflags}" \
|
|
|
+ LDFLAGS="%{l_ldflags}" \
|
|
|
+ ./configure \
|
|
|
+ --prefix=%{l_prefix} \
|
|
|
+ --with-libol="`pwd`/libol-%{V_ol_major}.%{V_ol_minor}"
|
|
|
+ %{l_make} %{l_mflags -O}
|
|
|
+
|
|
|
+%install
|
|
|
+ # install syslog-ng
|
|
|
+ rm -rf $RPM_BUILD_ROOT
|
|
|
+ %{l_make} %{l_mflags} install AM_MAKEFLAGS="DESTDIR=$RPM_BUILD_ROOT"
|
|
|
+ strip $RPM_BUILD_ROOT%{l_prefix}/sbin/* >/dev/null 2>&1 || true
|
|
|
+
|
|
|
+ # install additional files
|
|
|
+ %{l_shtool} mkdir -f -p -m 755 \
|
|
|
+ $RPM_BUILD_ROOT%{l_prefix}/etc/rc.d \
|
|
|
+ $RPM_BUILD_ROOT%{l_prefix}/etc/syslog-ng \
|
|
|
+ $RPM_BUILD_ROOT%{l_prefix}/share/syslog-ng
|
|
|
+ %{l_shtool} install -c -m 755 %{l_value -s -a} \
|
|
|
+ %{SOURCE rc.syslog-ng} $RPM_BUILD_ROOT%{l_prefix}/etc/rc.d/
|
|
|
+ %{l_shtool} install -c -m 644 %{l_value -s -a} \
|
|
|
+ %{SOURCE syslog-ng.conf} $RPM_BUILD_ROOT%{l_prefix}/etc/syslog-ng/
|
|
|
+ %{l_gzip} -d -c doc/sgml/syslog-ng.html.tar.gz | %{l_tar} xf -
|
|
|
+ %{l_shtool} install -c -m 644 %{l_value -s -a} \
|
|
|
+ syslog-ng.html/* $RPM_BUILD_ROOT%{l_prefix}/share/syslog-ng/
|
|
|
+
|
|
|
+ # determine installation files
|
|
|
+ %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
|
|
|
+ %{l_files_std} \
|
|
|
+ '%config %{l_prefix}/etc/syslog-ng/*'
|
|
|
+
|
|
|
+%files -f files
|
|
|
+
|
|
|
+%clean
|
|
|
+ rm -rf $RPM_BUILD_ROOT
|
|
|
+
|