[54873] trunk/dports/devel
snc at macports.org
snc at macports.org
Mon Aug 3 05:34:07 PDT 2009
Revision: 54873
http://trac.macports.org/changeset/54873
Author: snc at macports.org
Date: 2009-08-03 05:34:07 -0700 (Mon, 03 Aug 2009)
Log Message:
-----------
created libusb-legacy, ticket #20423. taken as openmaintainer.
this is for gnu radio and others who have not updated their api calls
to either the new api or the compat api. emphasis on legacy.
Added Paths:
-----------
trunk/dports/devel/libusb-legacy/
trunk/dports/devel/libusb-legacy/Portfile
trunk/dports/devel/libusb-legacy/files/
trunk/dports/devel/libusb-legacy/files/patch-Makefile.in.diff
trunk/dports/devel/libusb-legacy/files/patch-darwin.c.diff
Added: trunk/dports/devel/libusb-legacy/Portfile
===================================================================
--- trunk/dports/devel/libusb-legacy/Portfile (rev 0)
+++ trunk/dports/devel/libusb-legacy/Portfile 2009-08-03 12:34:07 UTC (rev 54873)
@@ -0,0 +1,31 @@
+# -*- coding: utf-8; mode: tcl; tab-width: 4; truncate-lines: t; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:et:sw=4:ts=4:sts=4
+# $Id$
+
+PortSystem 1.0
+
+name libusb-legacy
+version 0.1.12
+categories devel
+maintainers snc openmaintainer
+description Library providing access to USB devices
+long_description A library originally developed under Linux to give \
+ userland programs an API to access to USB hardware.
+homepage http://libusb.org/
+
+platforms darwin
+
+distname libusb-${version}
+master_sites sourceforge:libusb
+checksums md5 caf182cbc7565dac0fd72155919672e6 \
+ sha1 599a5168590f66bc6f1f9a299579fd8500614807 \
+ rmd160 63848df717e00fff67ab30ba86a85466370d4e8e
+
+patchfiles patch-Makefile.in.diff patch-darwin.c.diff
+
+configure.args --disable-build-docs
+post-configure {
+ if {[variant_isset universal]} {
+ reinplace "s|CC -dynamiclib|CC -dynamiclib ${configure.universal_ldflags}|g" ${worksrcpath}/libtool
+ }
+}
+
Property changes on: trunk/dports/devel/libusb-legacy/Portfile
___________________________________________________________________
Added: svn:keywords
+ Id
Added: svn:eol-style
+ native
Added: trunk/dports/devel/libusb-legacy/files/patch-Makefile.in.diff
===================================================================
--- trunk/dports/devel/libusb-legacy/files/patch-Makefile.in.diff (rev 0)
+++ trunk/dports/devel/libusb-legacy/files/patch-Makefile.in.diff 2009-08-03 12:34:07 UTC (rev 54873)
@@ -0,0 +1,11 @@
+--- Makefile.in.orig 2009-07-01 14:51:39.000000000 -0700
++++ Makefile.in 2009-07-01 14:51:45.000000000 -0700
+@@ -257,7 +257,7 @@
+ # gnu strictness chokes on README being autogenerated
+ AUTOMAKE_OPTIONS = 1.4 foreign
+ SUBDIRS = . tests doc
+-AM_CFLAGS = -Werror $(AM_CFLAGS_EXT)
++AM_CFLAGS = $(AM_CFLAGS_EXT)
+ configincludedir = $(pkglibdir)/include
+ bin_SCRIPTS = libusb-config
+ EXTRA_DIST = LICENSE libusb.spec.in libusb.spec libusb-config.in README.in README \
Added: trunk/dports/devel/libusb-legacy/files/patch-darwin.c.diff
===================================================================
--- trunk/dports/devel/libusb-legacy/files/patch-darwin.c.diff (rev 0)
+++ trunk/dports/devel/libusb-legacy/files/patch-darwin.c.diff 2009-08-03 12:34:07 UTC (rev 54873)
@@ -0,0 +1,41 @@
+--- darwin.c.orig 2006-02-25 19:40:17.000000000 +0100
++++ darwin.c 2006-04-27 22:15:22.000000000 +0200
+@@ -189,6 +189,8 @@
+ return "invalid argument";
+ case kIOReturnAborted:
+ return "transaction aborted";
++ case kIOReturnNotResponding:
++ return "the device is not responding";
+ default:
+ return "unknown error";
+ }
+@@ -207,6 +209,7 @@
+ case kIOUSBNoAsyncPortErr:
+ return ENXIO;
+ case kIOReturnExclusiveAccess:
++ case kIOReturnNotResponding:
+ return EBUSY;
+ case kIOUSBPipeStalled:
+ return LUSBDARWINSTALL;
+@@ -838,19 +841,13 @@
+
+ if (result == kIOReturnSuccess) {
+ /* wait for write to complete */
+- if (CFRunLoopRunInMode(kCFRunLoopDefaultMode, (timeout+999)/1000, true) == kCFRunLoopRunTimedOut) {
+- (*(device->interface))->AbortPipe(device->interface, pipeRef);
+- CFRunLoopRunInMode(kCFRunLoopDefaultMode, 0, true); /* Pick up aborted callback */
+- if (usb_debug)
+- fprintf(stderr, "usb_bulk_read: input timed out\n");
+- }
++ CFRunLoopRun();
+ }
+
+ CFRunLoopRemoveSource(CFRunLoopGetCurrent(), cfSource, kCFRunLoopDefaultMode);
+
+ /* Check the return code of both the write and completion functions. */
+- if (result != kIOReturnSuccess || (rw_arg.result != kIOReturnSuccess &&
+- rw_arg.result != kIOReturnAborted) ) {
++ if (result != kIOReturnSuccess || rw_arg.result != kIOReturnSuccess) {
+ int error_code;
+ char *error_str;
+
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20090803/1866cdf0/attachment.html>
More information about the macports-changes
mailing list