/[packages]/cauldron/libusb1/current/SPECS/libusb1.spec
ViewVC logotype

Contents of /cauldron/libusb1/current/SPECS/libusb1.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 6433 - (show annotations) (download)
Tue Jan 11 22:21:14 2011 UTC (10 years, 10 months ago) by pterjan
File size: 2836 byte(s)
imported package libusb1
1
2 %define api 1.0
3 %define major 0
4 %define libname %mklibname usb %api %major
5 %define devellibname %mklibname -d usb %api
6 %define sdevellibname %mklibname -s -d usb %api
7
8 Summary: A library which allows userspace access to USB devices
9 Name: libusb1
10 Version: 1.0.8
11 Release: %mkrel 1
12 Source0: http://downloads.sourceforge.net/libusb/libusb-%{version}.tar.bz2
13 License: LGPLv2+
14 Group: System/Libraries
15 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-
16 URL: http://libusb.wiki.sourceforge.net/Libusb1.0
17 BuildRequires: doxygen
18
19 %description
20 This package provides a way for applications to access USB devices. Note that
21 this library is not compatible with the original libusb-0.1 series.
22
23 %package -n %libname
24 Summary: %summary
25 Group: System/Libraries
26 # Package had originally wrong major:
27 Obsoletes: %{_lib}usb1 < 1.0.3-2
28
29 %description -n %libname
30 This package provides a way for applications to access USB devices. Note that
31 this library is not compatible with the original libusb-0.1 series.
32
33 %package -n %devellibname
34 Summary: Development files for libusb
35 Group: Development/C
36 Requires: %{libname} = %{version}
37 Provides: libusb1-devel = %version, usb1-devel = %version, usb%{api}-devel = %version
38 # Package had originally wrong api in name:
39 Obsoletes: %{_lib}usb1-devel < 1.0.3-2
40
41 %description -n %devellibname
42 This package contains the header files, libraries and documentation needed to
43 develop applications that use libusb-1.0.
44
45 %package -n %sdevellibname
46 Summary: Static development files for libusb
47 Group: Development/C
48 Requires: %devellibname = %{version}
49 Provides: usb1-static-devel = %version, usb%{api}-static-devel
50 # Package had originally wrong api in name:
51 Obsoletes: %{_lib}usb1-static-devel < 1.0.3-2
52
53 %description -n %sdevellibname
54 This package contains static libraries to develop applications that use
55 libusb-1.0.
56
57 %prep
58 %setup -q -n libusb-%{version}
59
60 %build
61 # libusb-compat is in /lib and uses libusb1
62 %configure2_5x --libdir=/%{_lib}
63 %make
64 pushd doc
65 make docs
66 popd
67
68 %install
69 rm -rf $RPM_BUILD_ROOT
70 %makeinstall_std
71
72 # static library is not needed in /lib
73 mkdir -p %{buildroot}%{_libdir}
74 mv %{buildroot}/%{_lib}/libusb-%api.a %{buildroot}%{_libdir}
75 # add a symlink just in case libtool expects it to be there due to it
76 # being referenced in the .la file
77 ln -s %{_libdir}/libusb-%api.a %{buildroot}/%{_lib}/libusb-%api.a
78 # move .pc file back
79 mv %{buildroot}/%{_lib}/pkgconfig %{buildroot}%{_libdir}
80
81 %clean
82 rm -rf $RPM_BUILD_ROOT
83
84 %files -n %libname
85 %defattr(-,root,root)
86 %doc AUTHORS COPYING README NEWS ChangeLog
87 /%{_lib}/libusb*-%{api}.so.%{major}*
88
89 %files -n %devellibname
90 %defattr(-,root,root)
91 %doc doc/html examples/*.c
92 %{_libdir}/pkgconfig/libusb-%api.pc
93 %{_includedir}/libusb-%api
94 /%{_lib}/libusb-%api.so
95
96 %files -n %sdevellibname
97 %defattr(-,root,root)
98 /%{_lib}/libusb-%api.*a
99 %{_libdir}/libusb-%api.a
100
101
102

  ViewVC Help
Powered by ViewVC 1.1.28