libftdi Archives

Subject: Re: Re: [RFC][PATCH] explicitly include libusb-1.0

From: Thomas Jarosch <thomas.jarosch@xxxxxxxxxxxxx>
To: libftdi@xxxxxxxxxxxxxxxxxxxxxxx
Date: Tue, 15 Jan 2013 17:48:20 +0100
On Sunday, 13. January 2013 16:29:24 Anders Larsen wrote:
> IMHO it would be better to not include <libusb.h> at all when compiling
> your application (unless the application needs it directly).
> 
> The attached patch removes said include from the exposed header ftdi.h
> and instead includes libusb.h in the libftdi sources where needed -
> ftdi.h itself did not need the declarations from libusb.h.
> (Caveat: Only compile-tested, and only on Linux)

Yes, this idea sounds good. Applied.

One question about the patch:

You also removed the explicit linking of libusb from the pkconfig file.
Since libusb 1.0 supports pkgconfig and we have it in
the "Requires:" section, that should be fine.

pkgconfig documentation:
http://people.freedesktop.org/~dbn/pkg-config-guide.html

I just wanted to explicitly mention it on the mailinglist,
in case someone thinks it's a bad idea for whatever reason :)

Thomas


--
libftdi - see http://www.intra2net.com/en/developer/libftdi for details.
To unsubscribe send a mail to libftdi+unsubscribe@xxxxxxxxxxxxxxxxxxxxxxx   

Current Thread