summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDiego Elio Pettenò <flameeyes@gentoo.org>2011-02-23 00:19:38 +0000
committerDiego Elio Pettenò <flameeyes@gentoo.org>2011-02-23 00:19:38 +0000
commit6700dd9fe27e1a2fc9e1e19993bf3911eda63171 (patch)
tree82c7c7254df15ffa546e15ec3369d6af37cc9aa0 /sys-apps
parentVersion bump. (diff)
downloadgentoo-2-6700dd9fe27e1a2fc9e1e19993bf3911eda63171.tar.gz
gentoo-2-6700dd9fe27e1a2fc9e1e19993bf3911eda63171.tar.bz2
gentoo-2-6700dd9fe27e1a2fc9e1e19993bf3911eda63171.zip
Version bump; upstream merged my patch and made a new release. Also drop .la file.
(Portage version: 2.2.0_alpha25/cvs/Linux x86_64)
Diffstat (limited to 'sys-apps')
-rw-r--r--sys-apps/pcsc-lite/ChangeLog10
-rw-r--r--sys-apps/pcsc-lite/files/pcsc-lite-1.6.6-libusb-multiinterface.patch174
-rw-r--r--sys-apps/pcsc-lite/pcsc-lite-1.6.7.ebuild (renamed from sys-apps/pcsc-lite/pcsc-lite-1.6.6-r1.ebuild)15
3 files changed, 13 insertions, 186 deletions
diff --git a/sys-apps/pcsc-lite/ChangeLog b/sys-apps/pcsc-lite/ChangeLog
index f846187d9b6f..5711a3acfd03 100644
--- a/sys-apps/pcsc-lite/ChangeLog
+++ b/sys-apps/pcsc-lite/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for sys-apps/pcsc-lite
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-apps/pcsc-lite/ChangeLog,v 1.104 2011/02/22 11:55:59 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/pcsc-lite/ChangeLog,v 1.105 2011/02/23 00:19:38 flameeyes Exp $
+
+*pcsc-lite-1.6.7 (23 Feb 2011)
+
+ 23 Feb 2011; Diego E. Pettenò <flameeyes@gentoo.org>
+ -pcsc-lite-1.6.6-r1.ebuild,
+ -files/pcsc-lite-1.6.6-libusb-multiinterface.patch, +pcsc-lite-1.6.7.ebuild:
+ Version bump; upstream merged my patch and made a new release. Also drop .la
+ file.
*pcsc-lite-1.6.6-r1 (22 Feb 2011)
diff --git a/sys-apps/pcsc-lite/files/pcsc-lite-1.6.6-libusb-multiinterface.patch b/sys-apps/pcsc-lite/files/pcsc-lite-1.6.6-libusb-multiinterface.patch
deleted file mode 100644
index 70fce453ca98..000000000000
--- a/sys-apps/pcsc-lite/files/pcsc-lite-1.6.6-libusb-multiinterface.patch
+++ /dev/null
@@ -1,174 +0,0 @@
-From 5b274f9da45174a444f9e1fe8917862680ea0c2c Mon Sep 17 00:00:00 2001
-From: rousseau <rousseau@0ce88b0d-b2fd-0310-8134-9614164e65ea>
-Date: Mon, 21 Feb 2011 15:05:38 +0000
-Subject: [PATCH] If a device has more than one CCID interface the "libhal:" naming scheme
- (with the interface number included) is used instead of "libusb:".
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-The new mechanism allows to use multi-interfaces devices like the
-Gemalto ProxDU also with hotplug_libusb. libhal is deprecated and may
-not be available everywhere.
-
-Thanks to Diego Elio Pettenò for the patch (for Gentoo)
-
-
-git-svn-id: svn://svn.debian.org/pcsclite/trunk/PCSC@5621 0ce88b0d-b2fd-0310-8134-9614164e65ea
----
- src/hotplug_libusb.c | 88 ++++++++++++++++++++++++++++++++++----------------
- 1 files changed, 60 insertions(+), 28 deletions(-)
-
-diff --git a/src/hotplug_libusb.c b/src/hotplug_libusb.c
-index f7625ba..772d9e0 100644
---- a/src/hotplug_libusb.c
-+++ b/src/hotplug_libusb.c
-@@ -47,8 +47,8 @@
- #undef DEBUG_HOTPLUG
- #define ADD_SERIAL_NUMBER
-
--/* format is "%d:%d", bus_number, device_address */
--#define BUS_DEVICE_STRSIZE 10+1+10+1
-+/* format is "%d:%d:%d", bus_number, device_address, interface */
-+#define BUS_DEVICE_STRSIZE 10+1+10+1+10+1
-
- #define READER_ABSENT 0
- #define READER_PRESENT 1
-@@ -98,7 +98,8 @@ static struct _readerTracker
-
- static LONG HPAddHotPluggable(struct libusb_device *dev,
- struct libusb_device_descriptor desc,
-- const char bus_device[], struct _driverTracker *driver);
-+ const char bus_device[], int interface,
-+ struct _driverTracker *driver);
- static LONG HPRemoveHotPluggable(int reader_index);
-
- static LONG HPReadBundleValues(void)
-@@ -276,6 +277,7 @@ static void HPRescanUsbBus(void)
- while ((dev = devs[cnt++]) != NULL)
- {
- struct libusb_device_descriptor desc;
-+ struct libusb_config_descriptor *config_desc;
- uint8_t bus_number = libusb_get_bus_number(dev);
- uint8_t device_address = libusb_get_device_address(dev);
-
-@@ -287,6 +289,14 @@ static void HPRescanUsbBus(void)
- continue;
- }
-
-+ r = libusb_get_active_config_descriptor(dev, &config_desc);
-+ if (r < 0)
-+ {
-+ Log3(PCSC_LOG_ERROR, "failed to get device config for %d/%d",
-+ bus_number, device_address);
-+ continue;
-+ }
-+
- /* check if the device is supported by one driver */
- for (i=0; i<driverSize; i++)
- {
-@@ -294,38 +304,53 @@ static void HPRescanUsbBus(void)
- desc.idVendor == driverTracker[i].manuID &&
- desc.idProduct == driverTracker[i].productID)
- {
-- int newreader;
-+ int interface;
-
-- /* A known device has been found */
-- snprintf(bus_device, BUS_DEVICE_STRSIZE, "%d:%d",
-- bus_number, device_address);
-- bus_device[BUS_DEVICE_STRSIZE - 1] = '\0';
- #ifdef DEBUG_HOTPLUG
-- Log2(PCSC_LOG_DEBUG, "Found matching USB device: %s",
-- bus_device);
-+ Log3(PCSC_LOG_DEBUG, "Found matching USB device: %d:%d",
-+ bus_number, device_address);
- #endif
-- newreader = TRUE;
-
-- /* Check if the reader is a new one */
-- for (j=0; j<PCSCLITE_MAX_READERS_CONTEXTS; j++)
-+ for (interface = 0; interface < config_desc->bNumInterfaces;
-+ interface++)
- {
-- if (strncmp(readerTracker[j].bus_device,
-- bus_device, BUS_DEVICE_STRSIZE) == 0)
-+ int newreader;
-+
-+ /* A known device has been found */
-+ snprintf(bus_device, BUS_DEVICE_STRSIZE, "%d:%d:%d",
-+ bus_number, device_address, interface);
-+ bus_device[BUS_DEVICE_STRSIZE - 1] = '\0';
-+ newreader = TRUE;
-+
-+ /* Check if the reader is a new one */
-+ for (j=0; j<PCSCLITE_MAX_READERS_CONTEXTS; j++)
- {
-- /* The reader is already known */
-- readerTracker[j].status = READER_PRESENT;
-- newreader = FALSE;
-+ if (strncmp(readerTracker[j].bus_device,
-+ bus_device, BUS_DEVICE_STRSIZE) == 0)
-+ {
-+ /* The reader is already known */
-+ readerTracker[j].status = READER_PRESENT;
-+ newreader = FALSE;
- #ifdef DEBUG_HOTPLUG
-- Log2(PCSC_LOG_DEBUG, "Refresh USB device: %s",
-- bus_device);
-+ Log2(PCSC_LOG_DEBUG, "Refresh USB device: %s",
-+ bus_device);
- #endif
-- break;
-+ break;
-+ }
- }
-- }
-
-- /* New reader found */
-- if (newreader)
-- HPAddHotPluggable(dev, desc, bus_device, &driverTracker[i]);
-+ /* New reader found */
-+ if (newreader)
-+ {
-+ printf("POUET %d\n", config_desc->bNumInterfaces);
-+ if (config_desc->bNumInterfaces > 1)
-+ HPAddHotPluggable(dev, desc, bus_device,
-+ interface, &driverTracker[i]);
-+ else
-+ HPAddHotPluggable(dev, desc, bus_device,
-+ -1, &driverTracker[i]);
-+ }
-+ }
- }
- }
- }
-@@ -470,15 +495,22 @@ LONG HPStopHotPluggables(void)
-
- static LONG HPAddHotPluggable(struct libusb_device *dev,
- struct libusb_device_descriptor desc,
-- const char bus_device[], struct _driverTracker *driver)
-+ const char bus_device[], int interface,
-+ struct _driverTracker *driver)
- {
- int i;
- char deviceName[MAX_DEVICENAME];
-
- Log2(PCSC_LOG_INFO, "Adding USB device: %s", bus_device);
-
-- snprintf(deviceName, sizeof(deviceName), "usb:%04x/%04x:libusb-1.0:%s",
-- desc.idVendor, desc.idProduct, bus_device);
-+ if (interface >= 0)
-+ snprintf(deviceName, sizeof(deviceName), "usb:%04x/%04x:libhal:/org/freedesktop/Hal/devices/usb_device_%04x_%04x_serialnotneeded_if%d",
-+ desc.idVendor, desc.idProduct, desc.idVendor, desc.idProduct,
-+ interface);
-+ else
-+ snprintf(deviceName, sizeof(deviceName), "usb:%04x/%04x:libusb-1.0:%s",
-+ desc.idVendor, desc.idProduct, bus_device);
-+
- deviceName[sizeof(deviceName) -1] = '\0';
-
- pthread_mutex_lock(&usbNotifierMutex);
---
-1.7.4.1
-
diff --git a/sys-apps/pcsc-lite/pcsc-lite-1.6.6-r1.ebuild b/sys-apps/pcsc-lite/pcsc-lite-1.6.7.ebuild
index 9bf8d6c4305f..24882d7bfbba 100644
--- a/sys-apps/pcsc-lite/pcsc-lite-1.6.6-r1.ebuild
+++ b/sys-apps/pcsc-lite/pcsc-lite-1.6.7.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-apps/pcsc-lite/pcsc-lite-1.6.6-r1.ebuild,v 1.1 2011/02/22 11:55:59 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/pcsc-lite/pcsc-lite-1.6.7.ebuild,v 1.1 2011/02/23 00:19:38 flameeyes Exp $
EAPI="3"
@@ -9,7 +9,7 @@ inherit multilib eutils
DESCRIPTION="PC/SC Architecture smartcard middleware library"
HOMEPAGE="http://pcsclite.alioth.debian.org/"
-STUPID_NUM="3479"
+STUPID_NUM="3516"
MY_P="${PN}-${PV/_/-}"
SRC_URI="http://alioth.debian.org/download.php/${STUPID_NUM}/${MY_P}.tar.bz2"
S="${WORKDIR}/${MY_P}"
@@ -30,15 +30,6 @@ pkg_setup() {
enewgroup pcscd
}
-src_prepare() {
- # upstream deprecates libusb in favour of libhal, but we don't want
- # libhal. Problem is that with 1.6.6 release, there is no way for
- # multi-interface devices to work without libhal. This patch was
- # written by me (Flameeyes) and edited by upstream to support such
- # device. I also have one to test.
- epatch "${FILESDIR}"/${P}-libusb-multiinterface.patch
-}
-
src_configure() {
econf \
--disable-maintainer-mode \
@@ -51,6 +42,8 @@ src_configure() {
src_install() {
emake DESTDIR="${D}" install || die "emake install failed"
+ find "${D}" -name '*.la' -delete
+
dodoc AUTHORS DRIVERS HELP README SECURITY ChangeLog || die
newinitd "${FILESDIR}/pcscd-init.3" pcscd || die