File usb_modeswitch.spec of Package usb_modeswitch

#
# spec file for package usb_modeswitch (Version 0.9.5)
#
# Copyright (c) 2008 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/
#


Url:            http://www.draisberghof.de/usb_modeswitch/

Name:           usb_modeswitch
Version:        0.9.5
Release:        2
Summary:        A mode switching tool for controlling multiple-device USB gear
Group:          Hardware/Mobile
License:        GPL v2 or later
Source0:        http://www.draisberghof.de/usb_modeswitch/%{name}-%{version}.tar.bz2
Source1:        http://www.draisberghof.de/usb_modeswitch/usb_modeswitch.conf
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildRequires:  gcc libusb-devel make

%description
USB_ModeSwitch is a mode switching tool for controlling "flip flop"
(multiple device) USB gear. It allows so-called "Zero-CD" devices that
show up as USB storage initially to be switched into their more useful
"application mode". This is most common for UMTS/3G wireless WAN
devices.



Authors:
--------
    Josua Dietze and others

%prep
%setup -q

%build
gcc $RPM_OPT_FLAGS -o usb_modeswitch usb_modeswitch.c -lusb
#./compile.sh

%install
install -c -D -m 755 usb_modeswitch $RPM_BUILD_ROOT%{_sbindir}/usb_modeswitch
# install -c -D -m 600 usb_modeswitch.conf $RPM_BUILD_ROOT/etc/usb_modeswitch.conf
install -c -D -m 644 %{S:1} $RPM_BUILD_ROOT/etc/usb_modeswitch.conf

%files
%defattr(-,root,root,-)
%{_sbindir}/usb_modeswitch
%config /etc/usb_modeswitch.conf
%doc README
%changelog
* Fri Nov 07 2008 seife@suse.de
- copied the package from home:perosb (Thanks!)
- added the latest config file from the home page
- install README
- use RPM_OPT_FLAGS
- enable useful debug info by not stripping the binary
openSUSE Build Service is sponsored by