SHA256
1
0
forked from pool/libusb-1_0
libusb-1_0/libusb-1_0.spec

89 lines
2.4 KiB
RPMSpec

#
# spec file for package libusb-1_0
#
# Copyright (c) 2015 SUSE LINUX 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/
#
Name: libusb-1_0
Version: 1.0.20
Release: 0
Summary: USB Library
License: LGPL-2.1+
Group: System/Libraries
%define _name libusb
Url: http://libusb.info/
Source: http://downloads.sourceforge.net/project/%{_name}/%{_name}-1.0/%{_name}-%{version}/%{_name}-%{version}.tar.bz2
Source1: baselibs.conf
BuildRequires: pkg-config
%if 0%{?suse_version} >= 1200
BuildRequires: pkgconfig(libudev)
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%define debug_package_requires libusb-1_0-0 = %{version}-%{release}
%description
Libusb is a library that allows userspace access to USB devices.
%package -n libusb-1_0-0
Summary: USB Library
Group: System/Libraries
%description -n libusb-1_0-0
Libusb is a library that allows userspace access to USB devices.
%package devel
Summary: USB Library
Group: Development/Libraries/C and C++
Requires: glibc-devel
Requires: libusb-1_0-0 = %{version}
%description devel
Libusb is a library that allows userspace access to USB devices.
%prep
%setup -q -n %{_name}-%{version}
tr -d '\r' <NEWS >NEWS.unix ; touch -r NEWS NEWS.unix ; mv NEWS.unix NEWS
%build
%configure\
%if 0%{?suse_version} < 1200
--disable-udev\
%endif
--with-pic\
--disable-static
make
%install
%makeinstall
rm -f %{buildroot}%{_libdir}/*.la
%post -n libusb-1_0-0 -p /sbin/ldconfig
%postun -n libusb-1_0-0 -p /sbin/ldconfig
%files -n libusb-1_0-0
%defattr(-,root,root)
%doc AUTHORS ChangeLog COPYING NEWS README TODO
%{_libdir}/*.so.*
%files devel
%defattr(-,root,root)
%doc PORTING
%{_includedir}/libusb-1.0
%{_libdir}/*.so
%{_libdir}/pkgconfig/*.pc
%changelog