File bluez-hcidump.spec of Package bluez-hcidump

#
# spec file for package bluez-hcidump
#
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
# Copyright (c) 2011-2012 B1 Systems GmbH, Vohburg, 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/
#


Name:           bluez-hcidump
BuildRequires:  bluez
BuildRequires:  bluez-devel >= 4.70
BuildRequires:  pkgconfig
BuildRequires:  xz
Url:            http://www.bluez.org
Version:        2.5
Release:        0
Summary:        HCI Dumper for Debugging Bluetooth Connections
License:        GPL-2.0+
Group:          Development/Tools/Debuggers
PreReq:         %insserv_prereq
############### http://www.kernel.org/pub/linux/bluetooth/
Source:         http://www.kernel.org/pub/linux/bluetooth/%{name}-%{version}.tar.xz
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
# not sure if we really need a specific bluez version, or if we need bluez at all
# maybe libbluetooth is enough
%requires_ge    bluez

%description
An HCI dumper for debugging Bluetooth connections for BlueZ.

Authors:
--------
        Marcel Holtmann <marcel@holtmann.org>
        Maxim Krasnyansky <maxk@qualcomm.com>
        Ricky Yuen <ryuen@qualcomm.com>
        Wayne Lee <waynelee@qualcomm.com>
        Takashi Sasai <sasai@sm.sony.co.jp>

%prep
%setup

%build
CFLAGS="$RPM_OPT_FLAGS" ./configure \
	--prefix=/usr \
	--mandir=%{_mandir} \
	--sysconfdir=%{_sysconfdir} \
	--libdir=%{_libdir}
make %{?_smp_mflags} V=1

%install
make DESTDIR=$RPM_BUILD_ROOT mandir=%{_mandir} libdir=%{_libdir} install
mkdir -p $RPM_BUILD_ROOT/%{_sbindir}
cp src/bpasniff $RPM_BUILD_ROOT/%{_sbindir}/bpasniff
cp src/csrsniff $RPM_BUILD_ROOT/%{_sbindir}/csrsniff

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-, root, root)
%{_sbindir}/hcidump
%{_sbindir}/bpasniff
%{_sbindir}/csrsniff
%{_mandir}/man8/hcidump.8.gz
%doc AUTHORS COPYING ChangeLog

%changelog
openSUSE Build Service is sponsored by