]> git.pld-linux.org Git - packages/barnyard2.git/blame - barnyard2.spec
- initial release - barnyard2 is an output processor for snort
[packages/barnyard2.git] / barnyard2.spec
CommitLineData
65fff0cc 1
2# Conditional build:
3%bcond_without mysql # don't build support for MySQL
4%bcond_without postgresql # don't build support for PostgreSQL
5
6Summary: Snort Log Backend
7Name: barnyard2
8Version: 1.10beta2
9Release: 1
10License: GPL
11Group: Networking
12Source0: https://github.com/firnsy/barnyard2/tarball/v2-1.10-beta2
13# Source0-md5: af417a3491c5a4e5605c8fbd529f2255
14Source2: %{name}.config
15Source3: %{name}
16URL: https://github.com/firnsy/barnyard2
17%{?with_mysql:BuildRequires: mysql-devel}
18%{?with_postgresql:BuildRequires: postgresql-devel}
19BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
20
21%description
22Barnyard has 3 modes of operation:
23One-shot, continual, continual w/ checkpoint. In one-shot mode,
24barnyard will process the specified file and exit. In continual mode,
25barnyard will start with the specified file and continue to process
26new data (and new spool files) as it appears. Continual mode w/
27checkpointing will also use a checkpoint file (or waldo file in the
28snort world) to track where it is. In the event the barnyard process
29ends while a waldo file is in use, barnyard will resume processing at
30the last entry as listed in the waldo file.
31%{?with_mysql:barnyard2 binary compiled with mysql support.}
32%{?with_postgresql:barnyard2 binary compiled with postgresql support.}
33
34%prep
35%setup -q -n firnsy-barnyard2-5832a85
36
37
38%build
39./autogen.sh
40%configure --sysconfdir=%{_sysconfdir}/snort \
41 %{?with_postgresql:--with-postgresql} \
42 %{?with_mysql:--with-mysql-libraries=/usr/%{_lib}} \
43
44%{__make}
45
46
47%install
48rm -rf $RPM_BUILD_ROOT
49%{__make} install \
50 DESTDIR=$RPM_BUILD_ROOT
51
52%{__install} -d -p $RPM_BUILD_ROOT%{_sysconfdir}/{sysconfig,rc.d/init.d,snort}
53%{__install} -d -p $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/contrib
54%{__install} -d -p $RPM_BUILD_ROOT%{_mandir}/man8
55%{__install} -d -p $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/doc
56%{__install} -m 644 etc/barnyard2.conf $RPM_BUILD_ROOT%{_sysconfdir}/snort/
57%{__install} -m 644 $RPM_SOURCE_DIR/barnyard2.config $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/barnyard2
58%{__install} -m 755 $RPM_SOURCE_DIR/barnyard2 $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/barnyard2
59%{__install} -m 644 doc/* $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/doc/
60
61%clean
62if [ -d $RPM_BUILD_ROOT ] && [ "$RPM_BUILD_ROOT" != "/" ] ; then
63 rm -rf $RPM_BUILD_ROOT
64fi
65
66%files
67%defattr(644,root,root,755)
68%doc LICENSE doc/
69%attr(755,root,root) %{_bindir}/barnyard2
70%attr(640,root,root) %config %{_sysconfdir}/snort/barnyard2.conf
71%attr(755,root,root) %config %{_sysconfdir}/rc.d/init.d/barnyard2
72%attr(644,root,root) %config %{_sysconfdir}/sysconfig/barnyard2
This page took 0.095284 seconds and 4 git commands to generate.