Compare commits
15 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6b3d37f480 | ||
|
|
bec0139843 | ||
|
|
1cccab3d9a | ||
|
|
b054e05391 | ||
|
|
8d77bdb699 | ||
|
|
07705d7c6a | ||
|
|
e287585e3a | ||
|
|
3b41605ea1 | ||
|
|
c829f2771e | ||
|
|
3f253a11e3 | ||
|
|
f0537eb40a | ||
|
|
be1108d4c7 | ||
|
|
bfc02a6404 | ||
|
|
94b95e344a | ||
|
|
b5f05ff601 |
9 changed files with 148 additions and 0 deletions
1
.fmf/version
Normal file
1
.fmf/version
Normal file
|
|
@ -0,0 +1 @@
|
|||
1
|
||||
3
.gitignore
vendored
Normal file
3
.gitignore
vendored
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
/libusb-compat-0.1.7.tar.bz2
|
||||
/libusb-compat-0.1-0.1.8-rc1.tar.bz2
|
||||
/libusb-compat-0.1.8.tar.bz2
|
||||
6
gating.yaml
Normal file
6
gating.yaml
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
--- !Policy
|
||||
product_versions:
|
||||
- fedora-*
|
||||
decision_context: bodhi_update_push_testing
|
||||
rules:
|
||||
- !PassingTestCaseRule {test_case_name: dist.depcheck}
|
||||
94
libusb-compat-0.1.spec
Normal file
94
libusb-compat-0.1.spec
Normal file
|
|
@ -0,0 +1,94 @@
|
|||
Name: libusb-compat-0.1
|
||||
Version: 0.1.8
|
||||
Release: %autorelease
|
||||
Summary: Compatibility shim around libusb-1.0 offering the old 0.1 API
|
||||
# Automatically converted from old format: LGPLv2+ - review is highly recommended.
|
||||
License: LicenseRef-Callaway-LGPLv2+
|
||||
URL: https://github.com/libusb/libusb-compat-0.1
|
||||
Source0: https://github.com/libusb/libusb-compat-0.1/releases/download/v%{version}/libusb-compat-%{version}.tar.bz2
|
||||
Patch0: libusb-config-multilib.patch
|
||||
BuildRequires: gcc libtool
|
||||
BuildRequires: libusb1-devel
|
||||
BuildRequires: make
|
||||
Provides: deprecated()
|
||||
# libusb was removed in F34
|
||||
Provides: libusb = 1:%{version}-%{release}
|
||||
Obsoletes: libusb < 1:%{version}-%{release}
|
||||
# libusb-compat-0.1 version 0.1.6 and later dlopen'ed the library
|
||||
Requires: libusb1%{?_isa}
|
||||
|
||||
%description
|
||||
This package provides a shim / compatibility layer on top of libusb1
|
||||
offering the old 0.1 API for applications which do not have been ported
|
||||
to the new 1.0 API yet. Where ever possible applications really should
|
||||
use and / or be ported to the new 1.0 API instead of relying on this
|
||||
compatibility library.
|
||||
|
||||
|
||||
%package devel
|
||||
Summary: Development files for %{name}
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
Obsoletes: libusb-devel < 1:%{version}-%{release}
|
||||
|
||||
%description devel
|
||||
This package contains the header files, libraries and documentation needed to
|
||||
develop applications that use libusb-0.1. However new applications should use
|
||||
libusb-1.0 library instead of this one.
|
||||
|
||||
|
||||
%package tests-examples
|
||||
Summary: Tests and examples for %{name}
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
Provides: libusb-tests-examles = 1:%{version}-%{release}
|
||||
Obsoletes: libusb-tests-examles < 1:%{version}-%{release}
|
||||
|
||||
%description tests-examples
|
||||
This package contains tests and examples for %{name}.
|
||||
|
||||
|
||||
%prep
|
||||
%autosetup -n libusb-compat-%{version}
|
||||
autoreconf -ivf
|
||||
|
||||
|
||||
%build
|
||||
%configure --disable-static --enable-examples-build
|
||||
%make_build
|
||||
|
||||
|
||||
%install
|
||||
%make_install
|
||||
rm $RPM_BUILD_ROOT%{_libdir}/libusb.la
|
||||
for i in lsusb testlibusb; do
|
||||
install -m 755 examples/.libs/$i \
|
||||
$RPM_BUILD_ROOT%{_bindir}/libusb-compat-0.1-$i
|
||||
done
|
||||
|
||||
|
||||
%check
|
||||
LD_LIBRARY_PATH=libusb/.libs ldd -r $RPM_BUILD_ROOT%{_bindir}/libusb-compat-0.1-lsusb
|
||||
LD_LIBRARY_PATH=libusb/.libs $RPM_BUILD_ROOT%{_bindir}/libusb-compat-0.1-lsusb
|
||||
LD_LIBRARY_PATH=libusb/.libs $RPM_BUILD_ROOT%{_bindir}/libusb-compat-0.1-testlibusb
|
||||
|
||||
|
||||
%ldconfig_scriptlets
|
||||
|
||||
|
||||
%files
|
||||
%doc AUTHORS NEWS README
|
||||
%license COPYING
|
||||
%{_libdir}/libusb-0.1.so.*
|
||||
|
||||
%files devel
|
||||
%{_includedir}/usb.h
|
||||
%{_libdir}/libusb.so
|
||||
%{_libdir}/pkgconfig/libusb.pc
|
||||
%{_bindir}/libusb-config
|
||||
|
||||
%files tests-examples
|
||||
%{_bindir}/libusb-compat-0.1-lsusb
|
||||
%{_bindir}/libusb-compat-0.1-testlibusb
|
||||
|
||||
|
||||
%changelog
|
||||
%autochangelog
|
||||
25
libusb-config-multilib.patch
Normal file
25
libusb-config-multilib.patch
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
Resolve multilib conflict in 'libusb-config' script by removing $libdir variable entirely.
|
||||
|
||||
http://fedoraproject.org/wiki/PackagingDrafts/MultilibTricks#Multiarch.2C_binaries_and_compilation_scripts
|
||||
|
||||
Author: Jan Vcelak <jvcelak@redhat.com>
|
||||
Date: 2011-06-22
|
||||
|
||||
diff -uNPrp libusb-compat-0.1.3/libusb-config.in libusb-compat-0.1.3.multilib/libusb-config.in
|
||||
--- libusb-compat-0.1.3/libusb-config.in 2009-06-23 23:45:33.000000000 +0200
|
||||
+++ libusb-compat-0.1.3.multilib/libusb-config.in 2011-06-22 09:55:59.810188470 +0200
|
||||
@@ -3,7 +3,6 @@
|
||||
prefix=@prefix@
|
||||
exec_prefix=@exec_prefix@
|
||||
includedir=@includedir@
|
||||
-libdir=@libdir@
|
||||
exec_prefix_set=no
|
||||
|
||||
usage()
|
||||
@@ -77,5 +76,5 @@ if test "$echo_cflags" = "yes"; then
|
||||
echo $includes
|
||||
fi
|
||||
if test "$echo_libs" = "yes"; then
|
||||
- echo -L$libdir -lusb
|
||||
+ echo -lusb
|
||||
fi
|
||||
5
plans/integration.fmf
Normal file
5
plans/integration.fmf
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
summary: Tests for libusb-compat-0.1
|
||||
discover:
|
||||
how: fmf
|
||||
execute:
|
||||
how: tmt
|
||||
1
sources
Normal file
1
sources
Normal file
|
|
@ -0,0 +1 @@
|
|||
SHA512 (libusb-compat-0.1.8.tar.bz2) = 817a16a2c7268e0d73add97c06ec3f6e4fc4b8697bd3129bb6f907f138c2a5dccb662096c4cd0385341053b216afd398b21dfef14676777b906972c9e3af4e3e
|
||||
6
tests/integration/main.fmf
Normal file
6
tests/integration/main.fmf
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
summary: Integration test of libusb-compat-0.1
|
||||
require:
|
||||
- libusb1-devel
|
||||
- libusb-compat-0.1-tests-examples
|
||||
test: bash ./run.sh
|
||||
|
||||
7
tests/integration/run.sh
Normal file
7
tests/integration/run.sh
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
#!/bin/sh
|
||||
|
||||
set -e
|
||||
|
||||
ldd /usr/bin/libusb-compat-0.1-lsusb
|
||||
/usr/bin/libusb-compat-0.1-lsusb
|
||||
/usr/bin/libusb-compat-0.1-testlibusb
|
||||
Loading…
Add table
Add a link
Reference in a new issue