FreeBSD build support thanks to a patch from deetch

This commit is contained in:
Mike Ossmann
2011-10-22 22:12:49 +00:00
parent 67db82492d
commit 947149892a
2 changed files with 11 additions and 1 deletions
+7 -1
View File
@@ -18,7 +18,13 @@
# Boston, MA 02110-1301, USA.
CC = gcc
LIBUSB = usb-1.0
OS = $(shell uname)
ifeq ($(OS), FreeBSD)
LIBUSB = usb
CFLAGS += -DFREEBSD
else
LIBUSB = usb-1.0
endif
LIBBTBB = btbb
LDFLAGS += -l$(LIBUSB) -l$(LIBBTBB)
+4
View File
@@ -22,7 +22,11 @@
#ifndef __UBERTOOTH_H__
#define __UBERTOOTH_H__
#ifdef FREEBSD
#include <libusb.h>
#else
#include <libusb-1.0/libusb.h>
#endif
#define u8 uint8_t
#define u16 uint16_t