File argus-client.spec of Package argus-client

#
# spec file for package argus-client (Version 3.0.0)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#

# norootforbuild


Name:           argus-client
BuildRequires:  bison flex libpcap ncurses-devel tcpd-devel tcsh
%define name2 argus-clients
License:        BSD 3-clause (or similar) ; LGPL v2.1 or later ; NON-OSI-COMPLIANT(Restricted Shareware) ; MIT License (or similar)
Group:          Productivity/Networking/Diagnostic
AutoReqProv:    on
Summary:        Client for Network Monitoring Tool
Version:        3.0.0
Release:        6
Url:            http://www.qosient.com/argus/
Source:         %{name2}-%{version}.tar.bz2
Patch1:         %{name2}-%{version}-overflow.patch
Patch2:         %{name2}-%{version}-fclose.patch
# PATCH-FIX-UPSTREAM fix mem leak (bnc#537485)
Patch3:         %{name2}-%{version}-leak-fix.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Requires:       argus
Provides:       argus:/usr/sbin/argus

%description
Client for Argus network monitoring tool.



Authors:
--------
    Carter Bullard <carter@qosient.com>

%prep
%setup -n %{name2}-%{version}
%patch1
%patch2
%patch3

%build
%{suse_update_config -f bin config }
autoreconf -fi
export CFLAGS="$RPM_OPT_FLAGS -Wall"
./configure --libdir=%{_libdir}
make

%install
rm -rf  %{buildroot}
install -d -m 755 $RPM_BUILD_ROOT/{etc,usr/{bin,share/man},%{_docdir}}
install -m 700 bin/arg* $RPM_BUILD_ROOT/usr/bin/
rm -f $RPM_BUILD_ROOT/usr/bin/argus_linux
install -m 755 bin/ra* $RPM_BUILD_ROOT/usr/bin/
( cd man
  cp -a man* $RPM_BUILD_ROOT%{_mandir} 
  chmod a-x $RPM_BUILD_ROOT%{_mandir}/*/* )
rm -f $RPM_BUILD_ROOT%{_mandir}/man1/tcpdump.1*
install -m 600 support/Config/rarc $RPM_BUILD_ROOT/etc/ra.conf
find support -type f -exec chmod 0644 {} \;
rm -f $RPM_BUILD_ROOT/usr/bin/argus*

%clean
rm -rf  %{buildroot}

%files
%defattr(-,root,root)
%doc doc COPYING MANIFEST support
%attr(0644,root,root) %doc %{_mandir}/man*/*
%config /etc/ra.conf
/usr/bin/ra*

%changelog
openSUSE Build Service is sponsored by