| 1 | Summary: A library which allows userspace access to USB devices
|
|---|
| 2 | Name: libusb1
|
|---|
| 3 | Version: 1.0.16
|
|---|
| 4 | Release: 1%{?dist}
|
|---|
| 5 | Source0: http://downloads.sourceforge.net/libusb/libusb-%{version}.tar.gz
|
|---|
| 6 |
|
|---|
| 7 | License: LGPLv2+
|
|---|
| 8 | Group: System Environment/Libraries
|
|---|
| 9 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|---|
| 10 | URL: http://libusb.wiki.sourceforge.net/Libusb1.0
|
|---|
| 11 |
|
|---|
| 12 | Patch0: libusb1-os2.patch
|
|---|
| 13 | Patch1: libusb1-os2-src.patch
|
|---|
| 14 |
|
|---|
| 15 | %description
|
|---|
| 16 | This package provides a way for applications to access USB devices. Note that
|
|---|
| 17 | this library is not compatible with the original libusb-0.1 series.
|
|---|
| 18 |
|
|---|
| 19 | %package devel
|
|---|
| 20 | Summary: Development files for libusb
|
|---|
| 21 | Group: Development/Libraries
|
|---|
| 22 | Requires: %{name} = %{version}-%{release}
|
|---|
| 23 | Requires: %{name}-devel-doc = %{version}-%{release}
|
|---|
| 24 | Requires: pkgconfig
|
|---|
| 25 |
|
|---|
| 26 | %description devel
|
|---|
| 27 | This package contains the header files and libraries needed to develop
|
|---|
| 28 | applications that use libusb1.
|
|---|
| 29 |
|
|---|
| 30 | %package devel-doc
|
|---|
| 31 | Summary: Development files for libusb
|
|---|
| 32 | Group: Development/Libraries
|
|---|
| 33 | Requires: %{name}-devel = %{version}-%{release}
|
|---|
| 34 | BuildArch: noarch
|
|---|
| 35 |
|
|---|
| 36 | %description devel-doc
|
|---|
| 37 | This package contains documentation needed to develop applications that
|
|---|
| 38 | use libusb1.
|
|---|
| 39 |
|
|---|
| 40 | %package static
|
|---|
| 41 | Summary: Static development files for libusb
|
|---|
| 42 | Group: Development/Libraries
|
|---|
| 43 | Requires: %{name}-devel = %{version}-%{release}
|
|---|
| 44 |
|
|---|
| 45 | %description static
|
|---|
| 46 | This package contains static libraries to develop applications that use libusb1.
|
|---|
| 47 |
|
|---|
| 48 | %package debug
|
|---|
| 49 | Summary: HLL debug data for exception handling support.
|
|---|
| 50 |
|
|---|
| 51 | %description debug
|
|---|
| 52 | HLL debug data for exception handling support.
|
|---|
| 53 |
|
|---|
| 54 | %prep
|
|---|
| 55 | %setup -q -n libusb-%{version}
|
|---|
| 56 | %patch0 -p1 -b ~os2
|
|---|
| 57 | %patch1 -p1 -b ~os2
|
|---|
| 58 |
|
|---|
| 59 | %build
|
|---|
| 60 | export CONFIG_SHELL="/@unixroot/usr/bin/sh.exe"
|
|---|
| 61 | %configure
|
|---|
| 62 | make CFLAGS="$RPM_OPT_FLAGS"
|
|---|
| 63 |
|
|---|
| 64 | %install
|
|---|
| 65 | rm -rf $RPM_BUILD_ROOT
|
|---|
| 66 | make install DESTDIR=$RPM_BUILD_ROOT
|
|---|
| 67 | rm -f $RPM_BUILD_ROOT/%{_libdir}/*.la
|
|---|
| 68 |
|
|---|
| 69 | cp -p libusb/*.dll %{buildroot}%{_libdir}
|
|---|
| 70 | cp -p libusb/.libs/usb-*_s.a %{buildroot}%{_libdir}
|
|---|
| 71 |
|
|---|
| 72 | %clean
|
|---|
| 73 | rm -rf $RPM_BUILD_ROOT
|
|---|
| 74 |
|
|---|
| 75 | %files
|
|---|
| 76 | %defattr(-,root,root)
|
|---|
| 77 | %doc AUTHORS COPYING README NEWS ChangeLog
|
|---|
| 78 | %{_libdir}/*.dll
|
|---|
| 79 |
|
|---|
| 80 | %files devel
|
|---|
| 81 | %defattr(-,root,root)
|
|---|
| 82 | %{_includedir}/*
|
|---|
| 83 | %{_libdir}/*-1.0.a
|
|---|
| 84 | %{_libdir}/pkgconfig/libusb-1.0.pc
|
|---|
| 85 |
|
|---|
| 86 | %files devel-doc
|
|---|
| 87 | %defattr(-,root,root)
|
|---|
| 88 | %doc examples/*.c
|
|---|
| 89 |
|
|---|
| 90 | %files static
|
|---|
| 91 | %defattr(-,root,root)
|
|---|
| 92 | %{_libdir}/*-1.0_s.a
|
|---|
| 93 |
|
|---|
| 94 | %files debug
|
|---|
| 95 | %defattr(-,root,root)
|
|---|
| 96 | %{_libdir}/*.dbg
|
|---|
| 97 |
|
|---|
| 98 | %changelog
|
|---|
| 99 | * Wed Apr 16 2014 yd
|
|---|
| 100 | - first public build.
|
|---|