| 1 | Name:       libusb-compat | 
|---|
| 2 | Version:    0.1.5 | 
|---|
| 3 | Release:    1%{?dist} | 
|---|
| 4 | Summary:    libusb-compat | 
|---|
| 5 |  | 
|---|
| 6 | Group:      System Environment/libraries | 
|---|
| 7 | License:    GPLv2+ | 
|---|
| 8 | Url:        http://libusb.sourceforge.net | 
|---|
| 9 | Source:     http://downloads.sourceforge.net/libusb/%{name}-%{version}.tar.bz2 | 
|---|
| 10 | Patch0:     libusb-compat-os2.patch | 
|---|
| 11 |  | 
|---|
| 12 | BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-build | 
|---|
| 13 | BuildRequires:  libusb1-devel | 
|---|
| 14 |  | 
|---|
| 15 | %description | 
|---|
| 16 | The libusb-compat package aims to look, feel and behave exactly like libusb-0.1. It is a compatibility layer needed by packages that have not been upgraded to the libusb-1.0 API. | 
|---|
| 17 |  | 
|---|
| 18 | %package devel | 
|---|
| 19 | Summary: Development files for libusb-compat | 
|---|
| 20 | Group: Development/Libraries | 
|---|
| 21 |  | 
|---|
| 22 | %description devel | 
|---|
| 23 | This package contains the header files and libraries needed to develop | 
|---|
| 24 | applications that use libusb-compat. | 
|---|
| 25 |  | 
|---|
| 26 | %package static | 
|---|
| 27 | Summary: Static development files for libusb | 
|---|
| 28 | Group: Development/Libraries | 
|---|
| 29 | Requires: %{name}-devel = %{version}-%{release} | 
|---|
| 30 |  | 
|---|
| 31 | %description static | 
|---|
| 32 | This package contains static libraries to develop applications that use libusb1. | 
|---|
| 33 |  | 
|---|
| 34 | %package debug | 
|---|
| 35 | Summary: HLL debug data for exception handling support. | 
|---|
| 36 |  | 
|---|
| 37 | %description debug | 
|---|
| 38 | HLL debug data for exception handling support. | 
|---|
| 39 |  | 
|---|
| 40 | %prep | 
|---|
| 41 | %setup -q -n %{name}-%{version} | 
|---|
| 42 | %patch0 -p1 -b ~os2 | 
|---|
| 43 |  | 
|---|
| 44 | %build | 
|---|
| 45 | export CONFIG_SHELL="/@unixroot/usr/bin/sh.exe" | 
|---|
| 46 | %configure | 
|---|
| 47 | make CFLAGS="$RPM_OPT_FLAGS" %{?_smp_mflags} | 
|---|
| 48 |  | 
|---|
| 49 | %check | 
|---|
| 50 |  | 
|---|
| 51 | %install | 
|---|
| 52 | rm -rf %{buildroot} | 
|---|
| 53 | make DESTDIR=%{buildroot} install | 
|---|
| 54 |  | 
|---|
| 55 | cp -p libusb/*.dll %{buildroot}%{_libdir} | 
|---|
| 56 | cp -p libusb/.libs/usb_s.a %{buildroot}%{_libdir} | 
|---|
| 57 | rm %{buildroot}%{_libdir}/*.la | 
|---|
| 58 |  | 
|---|
| 59 | %clean | 
|---|
| 60 | rm -rf %{buildroot} | 
|---|
| 61 |  | 
|---|
| 62 | %files | 
|---|
| 63 | %defattr(-,root,root,-) | 
|---|
| 64 | %{_libdir}/libusbc.dll | 
|---|
| 65 |  | 
|---|
| 66 | %files devel | 
|---|
| 67 | %defattr(-,root,root,-) | 
|---|
| 68 | %{_bindir}/libusb-config | 
|---|
| 69 | %{_includedir}/usb.h | 
|---|
| 70 | %{_libdir}/usb.a | 
|---|
| 71 | %{_libdir}/pkgconfig/libusb.pc | 
|---|
| 72 |  | 
|---|
| 73 | %files static | 
|---|
| 74 | %defattr(-,root,root) | 
|---|
| 75 | %{_libdir}/usb_s.a | 
|---|
| 76 |  | 
|---|
| 77 | %files debug | 
|---|
| 78 | %defattr(-,root,root) | 
|---|
| 79 | %{_libdir}/*.dbg | 
|---|
| 80 |  | 
|---|
| 81 | %changelog | 
|---|
| 82 | * Wed Apr 16 2014 yd | 
|---|
| 83 | - first public build. | 
|---|