summaryrefslogtreecommitdiff
path: root/sysutils
diff options
context:
space:
mode:
Diffstat (limited to 'sysutils')
-rw-r--r--sysutils/netbt-hcidump/DESCR4
-rw-r--r--sysutils/netbt-hcidump/Makefile22
-rw-r--r--sysutils/netbt-hcidump/distinfo40
-rw-r--r--sysutils/netbt-hcidump/patches/patch-aa6
-rw-r--r--sysutils/netbt-hcidump/patches/patch-ab23
-rw-r--r--sysutils/netbt-hcidump/patches/patch-ac12
-rw-r--r--sysutils/netbt-hcidump/patches/patch-ad12
-rw-r--r--sysutils/netbt-hcidump/patches/patch-ae8
-rw-r--r--sysutils/netbt-hcidump/patches/patch-af10
-rw-r--r--sysutils/netbt-hcidump/patches/patch-ah6
-rw-r--r--sysutils/netbt-hcidump/patches/patch-ai4
-rw-r--r--sysutils/netbt-hcidump/patches/patch-aj8
-rw-r--r--sysutils/netbt-hcidump/patches/patch-ak12
-rw-r--r--sysutils/netbt-hcidump/patches/patch-al17
-rw-r--r--sysutils/netbt-hcidump/patches/patch-am19
-rw-r--r--sysutils/netbt-hcidump/patches/patch-an4
-rw-r--r--sysutils/netbt-hcidump/patches/patch-ao32
-rw-r--r--sysutils/netbt-hcidump/patches/patch-lib_Makefile15
18 files changed, 117 insertions, 137 deletions
diff --git a/sysutils/netbt-hcidump/DESCR b/sysutils/netbt-hcidump/DESCR
index aa98e54d3b8..b4c1b53fcdb 100644
--- a/sysutils/netbt-hcidump/DESCR
+++ b/sysutils/netbt-hcidump/DESCR
@@ -3,5 +3,5 @@ prints to screen commands, events and data in a human-readable form.
Optionally, the dump can be written to a file rather than parsed, and the dump
file can be parsed in a subsequent moment.
-This is a patched standalone version not requiring bluez-libs, suitable
-for use with the netbt Bluetooth stack [originating] in NetBSD.
+This is a patched version, suitable for use with the "netbt" Bluetooth
+stack [originating] in NetBSD.
diff --git a/sysutils/netbt-hcidump/Makefile b/sysutils/netbt-hcidump/Makefile
index 633a0d62763..8c6d9519e13 100644
--- a/sysutils/netbt-hcidump/Makefile
+++ b/sysutils/netbt-hcidump/Makefile
@@ -1,11 +1,9 @@
-# $NetBSD: Makefile,v 1.4 2011/06/19 13:02:35 plunky Exp $
+# $NetBSD: Makefile,v 1.5 2012/02/15 09:30:23 plunky Exp $
-DISTNAME= netbt-hcidump-2.1
-PKGREVISION= 1
+DISTNAME= netbt-hcidump-2.2
CATEGORIES= sysutils
MASTER_SITES= http://www.kernel.org/pub/linux/bluetooth/
-DISTFILES= bluez-hcidump-2.1.tar.gz \
- bluez-4.94.tar.gz
+DISTFILES= bluez-hcidump-2.2.tar.gz
MAINTAINER= plunky@rya-online.net
HOMEPAGE= http://www.bluez.org/
@@ -17,22 +15,12 @@ CONFLICTS+= hcidump-[0-9]* bluez-hcidump-[0-9]*
INSTALLATION_DIRS= sbin ${PKGMANDIR}/cat8 ${PKGMANDIR}/man8
-WRKSRC= ${WRKDIR}/bluez-hcidump-2.1
-LIBSRC= ${WRKDIR}/bluez-4.94
+WRKSRC= ${WRKDIR}/bluez-hcidump-2.2
PKG_DESTDIR_SUPPORT= user-destdir
-CPPFLAGS+= -DVERSION=\""2.1-netbt"\"
+CPPFLAGS+= -DVERSION=\""2.2-netbt"\"
USE_BSD_MAKEFILE= yes
-post-extract:
- mkdir ${WRKSRC}/bluetooth
- cp ${LIBSRC}/lib/bluetooth.h ${WRKSRC}/bluetooth
- cp ${LIBSRC}/lib/hci.h ${WRKSRC}/bluetooth
- cp ${LIBSRC}/lib/hci_lib.h ${WRKSRC}/bluetooth
- cp ${LIBSRC}/lib/l2cap.h ${WRKSRC}/bluetooth
- cp ${LIBSRC}/lib/bluetooth.c ${WRKSRC}/src/bt_lib.c
- cp ${LIBSRC}/lib/hci.c ${WRKSRC}/src/hci_lib.c
-
.include "../../mk/bsd.pkg.mk"
diff --git a/sysutils/netbt-hcidump/distinfo b/sysutils/netbt-hcidump/distinfo
index b5522593260..37fbdc5b7db 100644
--- a/sysutils/netbt-hcidump/distinfo
+++ b/sysutils/netbt-hcidump/distinfo
@@ -1,22 +1,20 @@
-$NetBSD: distinfo,v 1.5 2011/06/19 13:02:35 plunky Exp $
+$NetBSD: distinfo,v 1.6 2012/02/15 09:30:23 plunky Exp $
-SHA1 (bluez-4.94.tar.gz) = 5a6ac6dfe6074e002a517f6e841623f0ded66e41
-RMD160 (bluez-4.94.tar.gz) = 20010e0db361fce9e08c0342d092f8397e478551
-Size (bluez-4.94.tar.gz) = 1152526 bytes
-SHA1 (bluez-hcidump-2.1.tar.gz) = d797000ac0f840803abecdae5e44db88c5e5dbe8
-RMD160 (bluez-hcidump-2.1.tar.gz) = cf26c5ea4f68abc6dee1135a0a9b35cac45ebb7f
-Size (bluez-hcidump-2.1.tar.gz) = 154630 bytes
-SHA1 (patch-aa) = 6e30f3bd8e06e152bd2b65b32e173de039320787
-SHA1 (patch-ab) = e313255f11be98686f40af27c6a18550656759ea
-SHA1 (patch-ac) = adbc1e33996e61ccc5c016154bee3c4af72d784d
-SHA1 (patch-ad) = b7007a6c55011ac6a1da2fd1883f953532d75ea5
-SHA1 (patch-ae) = e59424e971879f368c09adae894088952612f1be
-SHA1 (patch-af) = 7748d6d83ce118eff90b9d8158badd0664faa308
-SHA1 (patch-ah) = b5a190251ccb9e55d2ac8460a436df3026d6be3d
-SHA1 (patch-ai) = 46239a7931f8fecee9216b13f98227711c69c54d
-SHA1 (patch-aj) = 3ef708a26e82ea209ef66c556889ba0cb9c9dd86
-SHA1 (patch-ak) = bbdb271ca8ff39b57082659ceceb9435273ab5ac
-SHA1 (patch-al) = 0a7330fbc9b38c13797aae1a46ecc07b2eca8643
-SHA1 (patch-am) = 7de396188d6c519e4d7b95eb5134cb1464dfb865
-SHA1 (patch-an) = 35d9fd1b0d82addf0688e2997fdf589fbc89d921
-SHA1 (patch-ao) = 9572764ecba59a92f69996f5601fe14d4ebe3b23
+SHA1 (bluez-hcidump-2.2.tar.gz) = 4d36b9265e23bfdbc824f00f6f6a1c3fd794559a
+RMD160 (bluez-hcidump-2.2.tar.gz) = 5ec584f7b3c0818452ba1e874d8b17bb01efe621
+Size (bluez-hcidump-2.2.tar.gz) = 190096 bytes
+SHA1 (patch-aa) = 3a856deba9518923321b3ddffe863d7817a021e1
+SHA1 (patch-ab) = ad50cee12679bd302475f7a62391a3833343f51b
+SHA1 (patch-ac) = 42a0bfc63a64243db201973c1973b914bee92192
+SHA1 (patch-ad) = 65f5e76b20489907838d2eff47c6fdaea251a7e0
+SHA1 (patch-ae) = a5ce4c703d491472421138bbe7ebb0133832992c
+SHA1 (patch-af) = d32b7ac6add15c95fce071d1f64ad7e1f655c99f
+SHA1 (patch-ah) = 911e4c7d76b18681413a021df6cbf264cb13555e
+SHA1 (patch-ai) = 44800df5e4b4b729cd73478eda0c330024235e81
+SHA1 (patch-aj) = 27b2298a968ca4306072950f5d49bb5c5204777a
+SHA1 (patch-ak) = a9528e81fe86c4b7cac0e82f883e3490d0c092ce
+SHA1 (patch-al) = 2d62a0a4203c1ecce7b71fd16fe909f0f4356d2c
+SHA1 (patch-am) = d1e1fd830bf3d064dccabbbe2ddd5e302b2e28aa
+SHA1 (patch-an) = f9889b24e5ec399ef6fb40055c5df5a560d20f92
+SHA1 (patch-ao) = 070fc923cfb303ba9e3f9fd843b3ccd253db0698
+SHA1 (patch-lib_Makefile) = 027fc649ecb277b9402062a605d75122404ab595
diff --git a/sysutils/netbt-hcidump/patches/patch-aa b/sysutils/netbt-hcidump/patches/patch-aa
index def004fbcc4..26f874733a5 100644
--- a/sysutils/netbt-hcidump/patches/patch-aa
+++ b/sysutils/netbt-hcidump/patches/patch-aa
@@ -1,9 +1,9 @@
-$NetBSD: patch-aa,v 1.1.1.1 2010/12/19 20:20:42 plunky Exp $
+$NetBSD: patch-aa,v 1.2 2012/02/15 09:30:23 plunky Exp $
---- Makefile.orig 2009-11-30 19:29:18.000000000 +0000
+--- Makefile.orig 2012-02-15 08:56:20.000000000 +0000
+++ Makefile
@@ -0,0 +1,4 @@
+
-+SUBDIR+= src
++SUBDIR= lib .WAIT src
+
+.include <bsd.subdir.mk>
diff --git a/sysutils/netbt-hcidump/patches/patch-ab b/sysutils/netbt-hcidump/patches/patch-ab
index d7c4d006a8a..f5a3541a84d 100644
--- a/sysutils/netbt-hcidump/patches/patch-ab
+++ b/sysutils/netbt-hcidump/patches/patch-ab
@@ -1,7 +1,7 @@
-$NetBSD: patch-ab,v 1.3 2011/06/19 13:02:35 plunky Exp $
+$NetBSD: patch-ab,v 1.4 2012/02/15 09:30:23 plunky Exp $
---- bluetooth/bluetooth.h.orig 2011-06-19 12:38:18.000000000 +0000
-+++ bluetooth/bluetooth.h
+--- lib/bluetooth.h.orig 2011-12-22 00:18:58.000000000 +0000
++++ lib/bluetooth.h
@@ -30,6 +30,7 @@
extern "C" {
#endif
@@ -10,7 +10,7 @@ $NetBSD: patch-ab,v 1.3 2011/06/19 13:02:35 plunky Exp $
#include <stdio.h>
#include <stdint.h>
#include <string.h>
-@@ -103,6 +104,17 @@ enum {
+@@ -107,6 +108,20 @@ enum {
#else
#error "Unknown byte order"
#endif
@@ -24,19 +24,22 @@ $NetBSD: patch-ab,v 1.3 2011/06/19 13:02:35 plunky Exp $
+#define htobl(d) htole32(d)
+#define btohs(d) le16toh(d)
+#define btohl(d) le32toh(d)
++#define bswap_64(v) bswap64(v)
++#define bswap_32(v) bswap32(v)
++#define bswap_16(v) bswap16(v)
+#endif
/* Bluetooth unaligned access */
#define bt_get_unaligned(ptr) \
-@@ -121,6 +133,7 @@ do { \
- __p->__v = (val); \
- } while(0)
+@@ -189,6 +204,7 @@ static inline uint16_t bt_get_be16(void
+ #error "Unknown byte order"
+ #endif
+#if 0
/* BD Address */
typedef struct {
uint8_t b[6];
-@@ -129,6 +142,7 @@ typedef struct {
+@@ -197,6 +213,7 @@ typedef struct {
#define BDADDR_ANY (&(bdaddr_t) {{0, 0, 0, 0, 0, 0}})
#define BDADDR_ALL (&(bdaddr_t) {{0xff, 0xff, 0xff, 0xff, 0xff, 0xff}})
#define BDADDR_LOCAL (&(bdaddr_t) {{0, 0, 0, 0xff, 0xff, 0xff}})
@@ -44,7 +47,7 @@ $NetBSD: patch-ab,v 1.3 2011/06/19 13:02:35 plunky Exp $
/* Copy, swap, convert BD Address */
static inline int bacmp(const bdaddr_t *ba1, const bdaddr_t *ba2)
-@@ -141,9 +155,12 @@ static inline void bacpy(bdaddr_t *dst,
+@@ -209,9 +226,12 @@ static inline void bacpy(bdaddr_t *dst,
}
void baswap(bdaddr_t *dst, const bdaddr_t *src);
@@ -57,7 +60,7 @@ $NetBSD: patch-ab,v 1.3 2011/06/19 13:02:35 plunky Exp $
int str2ba(const char *str, bdaddr_t *ba);
int ba2oui(const bdaddr_t *ba, char *oui);
int bachk(const char *str);
-@@ -152,11 +169,14 @@ int baprintf(const char *format, ...);
+@@ -220,11 +240,14 @@ int baprintf(const char *format, ...);
int bafprintf(FILE *stream, const char *format, ...);
int basprintf(char *str, const char *format, ...);
int basnprintf(char *str, size_t size, const char *format, ...);
diff --git a/sysutils/netbt-hcidump/patches/patch-ac b/sysutils/netbt-hcidump/patches/patch-ac
index 2988c856661..04ef6a169f1 100644
--- a/sysutils/netbt-hcidump/patches/patch-ac
+++ b/sysutils/netbt-hcidump/patches/patch-ac
@@ -1,7 +1,7 @@
-$NetBSD: patch-ac,v 1.1.1.1 2010/12/19 20:20:42 plunky Exp $
+$NetBSD: patch-ac,v 1.2 2012/02/15 09:30:23 plunky Exp $
---- bluetooth/hci.h.orig 2010-09-30 08:53:08.000000000 +0000
-+++ bluetooth/hci.h
+--- lib/hci.h.orig 2011-12-22 00:18:58.000000000 +0000
++++ lib/hci.h
@@ -39,6 +39,7 @@ extern "C" {
#define HCI_MAX_EVENT_SIZE 260
#define HCI_MAX_FRAME_SIZE (HCI_MAX_ACL_SIZE + 4)
@@ -10,7 +10,7 @@ $NetBSD: patch-ac,v 1.1.1.1 2010/12/19 20:20:42 plunky Exp $
/* HCI dev events */
#define HCI_DEV_REG 1
#define HCI_DEV_UNREG 2
-@@ -101,6 +102,7 @@ enum {
+@@ -107,6 +108,7 @@ enum {
#define HCIUNBLOCKADDR _IOW('H', 231, int)
#define HCIINQUIRY _IOR('H', 240, int)
@@ -18,7 +18,7 @@ $NetBSD: patch-ac,v 1.1.1.1 2010/12/19 20:20:42 plunky Exp $
#ifndef __NO_HCI_DEFS
-@@ -2232,6 +2234,7 @@ typedef struct {
+@@ -2252,6 +2254,7 @@ typedef struct {
#endif /* _NO_HCI_DEFS */
@@ -26,7 +26,7 @@ $NetBSD: patch-ac,v 1.1.1.1 2010/12/19 20:20:42 plunky Exp $
/* HCI Socket options */
#define HCI_DATA_DIR 1
#define HCI_FILTER 2
-@@ -2339,6 +2342,12 @@ struct hci_inquiry_req {
+@@ -2363,6 +2366,12 @@ struct hci_inquiry_req {
uint8_t num_rsp;
};
#define IREQ_CACHE_FLUSH 0x0001
diff --git a/sysutils/netbt-hcidump/patches/patch-ad b/sysutils/netbt-hcidump/patches/patch-ad
index cbc87747457..41ad4b5bab5 100644
--- a/sysutils/netbt-hcidump/patches/patch-ad
+++ b/sysutils/netbt-hcidump/patches/patch-ad
@@ -1,7 +1,7 @@
-$NetBSD: patch-ad,v 1.1.1.1 2010/12/19 20:20:43 plunky Exp $
+$NetBSD: patch-ad,v 1.2 2012/02/15 09:30:23 plunky Exp $
---- bluetooth/hci_lib.h.orig 2010-09-30 08:53:08.000000000 +0000
-+++ bluetooth/hci_lib.h
+--- lib/hci_lib.h.orig 2011-12-22 00:18:58.000000000 +0000
++++ lib/hci_lib.h
@@ -30,6 +30,7 @@
extern "C" {
#endif
@@ -10,7 +10,7 @@ $NetBSD: patch-ad,v 1.1.1.1 2010/12/19 20:20:43 plunky Exp $
struct hci_request {
uint16_t ogf;
uint16_t ocf;
-@@ -135,11 +136,15 @@ char *hci_bustostr(int bus);
+@@ -142,11 +143,15 @@ char *hci_bustostr(int bus);
char *hci_typetostr(int type);
char *hci_dtypetostr(int type);
char *hci_dflagstostr(uint32_t flags);
@@ -26,7 +26,7 @@ $NetBSD: patch-ad,v 1.1.1.1 2010/12/19 20:20:43 plunky Exp $
int hci_strtolp(char *str, unsigned int *val);
char *hci_lmtostr(unsigned int ptype);
int hci_strtolm(char *str, unsigned int *val);
-@@ -147,9 +152,13 @@ int hci_strtolm(char *str, unsigned int
+@@ -154,9 +159,13 @@ int hci_strtolm(char *str, unsigned int
char *hci_cmdtostr(unsigned int cmd);
char *hci_commandstostr(uint8_t *commands, char *pref, int width);
@@ -40,7 +40,7 @@ $NetBSD: patch-ad,v 1.1.1.1 2010/12/19 20:20:43 plunky Exp $
int lmp_strtover(char *str, unsigned int *ver);
char *lmp_featurestostr(uint8_t *features, char *pref, int width);
-@@ -218,6 +227,7 @@ static inline int hci_filter_test_opcode
+@@ -225,6 +234,7 @@ static inline int hci_filter_test_opcode
{
return (f->opcode == opcode);
}
diff --git a/sysutils/netbt-hcidump/patches/patch-ae b/sysutils/netbt-hcidump/patches/patch-ae
index 7aad6cac9f0..964f9a98016 100644
--- a/sysutils/netbt-hcidump/patches/patch-ae
+++ b/sysutils/netbt-hcidump/patches/patch-ae
@@ -1,7 +1,7 @@
-$NetBSD: patch-ae,v 1.1.1.1 2010/12/19 20:20:43 plunky Exp $
+$NetBSD: patch-ae,v 1.2 2012/02/15 09:30:23 plunky Exp $
---- bluetooth/l2cap.h.orig 2009-11-30 19:29:17.000000000 +0000
-+++ bluetooth/l2cap.h
+--- lib/l2cap.h.orig 2011-12-22 00:18:58.000000000 +0000
++++ lib/l2cap.h
@@ -30,6 +30,7 @@
extern "C" {
#endif
@@ -10,7 +10,7 @@ $NetBSD: patch-ae,v 1.1.1.1 2010/12/19 20:20:43 plunky Exp $
#include <sys/socket.h>
/* L2CAP defaults */
-@@ -66,6 +67,7 @@ struct l2cap_conninfo {
+@@ -69,6 +70,7 @@ struct l2cap_conninfo {
#define L2CAP_LM_TRUSTED 0x0008
#define L2CAP_LM_RELIABLE 0x0010
#define L2CAP_LM_SECURE 0x0020
diff --git a/sysutils/netbt-hcidump/patches/patch-af b/sysutils/netbt-hcidump/patches/patch-af
index 5a28f8f8858..7b1f4d3ed0d 100644
--- a/sysutils/netbt-hcidump/patches/patch-af
+++ b/sysutils/netbt-hcidump/patches/patch-af
@@ -1,13 +1,13 @@
-$NetBSD: patch-af,v 1.1.1.1 2010/12/19 20:20:43 plunky Exp $
+$NetBSD: patch-af,v 1.2 2012/02/15 09:30:23 plunky Exp $
---- parser/bnep.c.orig 2007-02-18 03:39:02.000000000 +0000
+--- parser/bnep.c.orig 2011-12-22 00:18:58.000000000 +0000
+++ parser/bnep.c
-@@ -33,7 +33,7 @@
+@@ -32,7 +32,7 @@
+ #include <stdlib.h>
#include <string.h>
- #include <sys/types.h>
-#include <net/ethernet.h>
+#include <net/ethertypes.h>
- #include "parser.h"
+ #include "parser/parser.h"
diff --git a/sysutils/netbt-hcidump/patches/patch-ah b/sysutils/netbt-hcidump/patches/patch-ah
index 778fa9e4e39..ac536c32fc3 100644
--- a/sysutils/netbt-hcidump/patches/patch-ah
+++ b/sysutils/netbt-hcidump/patches/patch-ah
@@ -1,8 +1,8 @@
-$NetBSD: patch-ah,v 1.1.1.1 2010/12/19 20:20:43 plunky Exp $
+$NetBSD: patch-ah,v 1.2 2012/02/15 09:30:23 plunky Exp $
---- parser/parser.h.orig 2007-02-18 03:39:02.000000000 +0000
+--- parser/parser.h.orig 2011-12-22 00:18:58.000000000 +0000
+++ parser/parser.h
-@@ -35,7 +35,7 @@ struct frame {
+@@ -36,7 +36,7 @@ struct frame {
uint32_t data_len;
void *ptr;
uint32_t len;
diff --git a/sysutils/netbt-hcidump/patches/patch-ai b/sysutils/netbt-hcidump/patches/patch-ai
index b877c78e894..fd59ac54c7e 100644
--- a/sysutils/netbt-hcidump/patches/patch-ai
+++ b/sysutils/netbt-hcidump/patches/patch-ai
@@ -1,6 +1,6 @@
-$NetBSD: patch-ai,v 1.1.1.1 2010/12/19 20:20:43 plunky Exp $
+$NetBSD: patch-ai,v 1.2 2012/02/15 09:30:23 plunky Exp $
---- parser/rfcomm.h.orig 2007-02-18 03:39:02.000000000 +0000
+--- parser/rfcomm.h.orig 2011-01-27 04:11:41.000000000 +0000
+++ parser/rfcomm.h
@@ -25,7 +25,9 @@
#ifndef __RFCOMM_H
diff --git a/sysutils/netbt-hcidump/patches/patch-aj b/sysutils/netbt-hcidump/patches/patch-aj
index 6e27fed5a5a..0bf9b7dd315 100644
--- a/sysutils/netbt-hcidump/patches/patch-aj
+++ b/sysutils/netbt-hcidump/patches/patch-aj
@@ -1,10 +1,10 @@
-$NetBSD: patch-aj,v 1.1.1.1 2010/12/19 20:20:43 plunky Exp $
+$NetBSD: patch-aj,v 1.2 2012/02/15 09:30:23 plunky Exp $
---- parser/tcpip.c.orig 2007-02-18 03:39:02.000000000 +0000
+--- parser/tcpip.c.orig 2011-12-22 00:18:58.000000000 +0000
+++ parser/tcpip.c
-@@ -32,8 +32,9 @@
+@@ -31,8 +31,9 @@
+ #include <stdlib.h>
#include <string.h>
- #include <sys/types.h>
-#include <net/ethernet.h>
+#include <net/if.h>
diff --git a/sysutils/netbt-hcidump/patches/patch-ak b/sysutils/netbt-hcidump/patches/patch-ak
index b6cd5bbf5e4..f49e23e23c2 100644
--- a/sysutils/netbt-hcidump/patches/patch-ak
+++ b/sysutils/netbt-hcidump/patches/patch-ak
@@ -1,6 +1,6 @@
-$NetBSD: patch-ak,v 1.2 2011/06/19 13:02:35 plunky Exp $
+$NetBSD: patch-ak,v 1.3 2012/02/15 09:30:23 plunky Exp $
---- src/Makefile.orig 2011-06-19 12:48:50.000000000 +0000
+--- src/Makefile.orig 2012-02-15 08:56:20.000000000 +0000
+++ src/Makefile
@@ -0,0 +1,16 @@
+.PATH: ../parser
@@ -10,12 +10,12 @@ $NetBSD: patch-ak,v 1.2 2011/06/19 13:02:35 plunky Exp $
+
+BINDIR= ${PREFIX}/sbin
+
-+SRCS= hcidump.c bt_lib.c hci_lib.c \
-+ att.c avctp.c avdtp.c bnep.c bpa.c capi.c cmtp.c csr.c \
-+ ericsson.c hci.c hcrp.c hidp.c l2cap.c lmp.c obex.c \
++SRCS= hcidump.c \
++ att.c avctp.c avdtp.c avrcp.c bnep.c bpa.c capi.c cmtp.c \
++ csr.c ericsson.c hci.c hcrp.c hidp.c l2cap.c lmp.c obex.c \
+ parser.c ppp.c rfcomm.c sdp.c smp.c tcpip.c
+
+CPPFLAGS+= -I..
-+LDADD+= -lbluetooth
++LDADD+= ../lib/libbluez.a -lbluetooth
+
+.include <bsd.prog.mk>
diff --git a/sysutils/netbt-hcidump/patches/patch-al b/sysutils/netbt-hcidump/patches/patch-al
index 3f7839cde4d..fecf5698533 100644
--- a/sysutils/netbt-hcidump/patches/patch-al
+++ b/sysutils/netbt-hcidump/patches/patch-al
@@ -1,18 +1,7 @@
-$NetBSD: patch-al,v 1.2 2011/06/19 13:02:35 plunky Exp $
+$NetBSD: patch-al,v 1.3 2012/02/15 09:30:23 plunky Exp $
---- src/bt_lib.c.orig 2011-06-19 12:38:18.000000000 +0000
-+++ src/bt_lib.c
-@@ -35,8 +35,8 @@
- #include <string.h>
- #include <sys/socket.h>
-
--#include "bluetooth.h"
--#include "hci.h"
-+#include <bluetooth/bluetooth.h>
-+#include <bluetooth/hci.h>
-
- void baswap(bdaddr_t *dst, const bdaddr_t *src)
- {
+--- lib/bluetooth.c.orig 2011-12-22 00:18:58.000000000 +0000
++++ lib/bluetooth.c
@@ -48,6 +48,7 @@ void baswap(bdaddr_t *dst, const bdaddr_
d[i] = s[5-i];
}
diff --git a/sysutils/netbt-hcidump/patches/patch-am b/sysutils/netbt-hcidump/patches/patch-am
index aea9af6c3b8..750fd72a3d4 100644
--- a/sysutils/netbt-hcidump/patches/patch-am
+++ b/sysutils/netbt-hcidump/patches/patch-am
@@ -1,20 +1,7 @@
-$NetBSD: patch-am,v 1.2 2011/06/19 13:02:35 plunky Exp $
+$NetBSD: patch-am,v 1.3 2012/02/15 09:30:23 plunky Exp $
---- src/hci_lib.c.orig 2011-06-19 12:48:50.000000000 +0000
-+++ src/hci_lib.c
-@@ -41,9 +41,9 @@
- #include <sys/ioctl.h>
- #include <sys/socket.h>
-
--#include "bluetooth.h"
--#include "hci.h"
--#include "hci_lib.h"
-+#include <bluetooth/bluetooth.h>
-+#include <bluetooth/hci.h>
-+#include <bluetooth/hci_lib.h>
-
- #ifndef MIN
- #define MIN(x, y) ((x) < (y) ? (x) : (y))
+--- lib/hci.c.orig 2011-12-22 00:18:58.000000000 +0000
++++ lib/hci.c
@@ -71,6 +71,7 @@ static char *hci_bit2str(hci_map *m, uns
return str;
}
diff --git a/sysutils/netbt-hcidump/patches/patch-an b/sysutils/netbt-hcidump/patches/patch-an
index ce626aec199..9ddd5a3e4ea 100644
--- a/sysutils/netbt-hcidump/patches/patch-an
+++ b/sysutils/netbt-hcidump/patches/patch-an
@@ -1,6 +1,6 @@
-$NetBSD: patch-an,v 1.1.1.1 2010/12/19 20:20:43 plunky Exp $
+$NetBSD: patch-an,v 1.2 2012/02/15 09:30:23 plunky Exp $
---- src/hcidump.8.orig 2007-07-26 08:34:58.000000000 +0100
+--- src/hcidump.8.orig 2011-01-27 03:33:33.000000000 +0000
+++ src/hcidump.8
@@ -28,7 +28,7 @@ which must be the name of an installed B
and if
diff --git a/sysutils/netbt-hcidump/patches/patch-ao b/sysutils/netbt-hcidump/patches/patch-ao
index 7f95b03b3e4..a1240611a43 100644
--- a/sysutils/netbt-hcidump/patches/patch-ao
+++ b/sysutils/netbt-hcidump/patches/patch-ao
@@ -1,19 +1,19 @@
-$NetBSD: patch-ao,v 1.4 2011/06/19 13:02:35 plunky Exp $
+$NetBSD: patch-ao,v 1.5 2012/02/15 09:30:23 plunky Exp $
---- src/hcidump.c.orig 2011-06-13 01:54:33.000000000 +0000
+--- src/hcidump.c.orig 2011-12-22 00:18:58.000000000 +0000
+++ src/hcidump.c
-@@ -50,6 +50,10 @@
- #include "parser/parser.h"
- #include "parser/sdp.h"
+@@ -48,6 +48,10 @@
+ #include "lib/hci.h"
+ #include "lib/hci_lib.h"
+#ifndef AI_ADDRCONFIG
+#define AI_ADDRCONFIG 0
+#endif
+
- #define SNAP_LEN HCI_MAX_FRAME_SIZE
- #define DEFAULT_PORT "10839";
+ #define SNAP_LEN HCI_MAX_FRAME_SIZE
+ #define DEFAULT_PORT "10839"
-@@ -146,7 +150,7 @@ static inline int write_n(int fd, char *
+@@ -144,7 +148,7 @@ static inline int write_n(int fd, char *
return t;
}
@@ -22,7 +22,7 @@ $NetBSD: patch-ao,v 1.4 2011/06/19 13:02:35 plunky Exp $
{
struct cmsghdr *cmsg;
struct msghdr msg;
-@@ -188,7 +192,7 @@ static int process_frames(int dev, int s
+@@ -186,7 +190,7 @@ static int process_frames(int dev, int s
if (dev == HCI_DEV_NONE)
printf("system: ");
else
@@ -31,7 +31,7 @@ $NetBSD: patch-ao,v 1.4 2011/06/19 13:02:35 plunky Exp $
printf("snap_len: %d filter: 0x%lx\n", snap_len, parser.filter);
-@@ -530,10 +534,13 @@ static int open_file(char *file, int mod
+@@ -528,10 +532,13 @@ static int open_file(char *file, int mod
return fd;
}
@@ -47,7 +47,7 @@ $NetBSD: patch-ao,v 1.4 2011/06/19 13:02:35 plunky Exp $
struct hci_dev_info di;
int sk, dd, opt;
-@@ -559,6 +566,7 @@ static int open_socket(int dev, unsigned
+@@ -557,6 +564,7 @@ static int open_socket(int dev, unsigned
hci_close_dev(dd);
}
@@ -55,7 +55,7 @@ $NetBSD: patch-ao,v 1.4 2011/06/19 13:02:35 plunky Exp $
/* Create HCI socket */
sk = socket(AF_BLUETOOTH, SOCK_RAW, BTPROTO_HCI);
-@@ -574,12 +582,13 @@ static int open_socket(int dev, unsigned
+@@ -572,12 +580,13 @@ static int open_socket(int dev, unsigned
}
opt = 1;
@@ -70,7 +70,7 @@ $NetBSD: patch-ao,v 1.4 2011/06/19 13:02:35 plunky Exp $
hci_filter_clear(&flt);
hci_filter_all_ptypes(&flt);
hci_filter_all_events(&flt);
-@@ -587,13 +596,34 @@ static int open_socket(int dev, unsigned
+@@ -585,13 +594,34 @@ static int open_socket(int dev, unsigned
perror("Can't set filter");
return -1;
}
@@ -106,7 +106,7 @@ $NetBSD: patch-ao,v 1.4 2011/06/19 13:02:35 plunky Exp $
dev, strerror(errno), errno);
return -1;
}
-@@ -770,7 +800,7 @@ static int wait_connection(char *addr, c
+@@ -768,7 +798,7 @@ static int wait_connection(char *addr, c
return -1;
}
@@ -115,7 +115,7 @@ $NetBSD: patch-ao,v 1.4 2011/06/19 13:02:35 plunky Exp $
{
while (1) {
int dd, sk;
-@@ -902,7 +932,7 @@ int main(int argc, char *argv[])
+@@ -900,7 +930,7 @@ int main(int argc, char *argv[])
{
unsigned long flags = 0;
unsigned long filter = 0;
@@ -124,7 +124,7 @@ $NetBSD: patch-ao,v 1.4 2011/06/19 13:02:35 plunky Exp $
int defpsm = 0;
int defcompid = DEFAULT_COMPID;
int opt, pppdump_fd = -1, audio_fd = -1;
-@@ -911,7 +941,7 @@ int main(int argc, char *argv[])
+@@ -909,7 +939,7 @@ int main(int argc, char *argv[])
switch(opt) {
case 'i':
if (strcasecmp(optarg, "none") && strcasecmp(optarg, "system"))
diff --git a/sysutils/netbt-hcidump/patches/patch-lib_Makefile b/sysutils/netbt-hcidump/patches/patch-lib_Makefile
new file mode 100644
index 00000000000..c31cb418f9f
--- /dev/null
+++ b/sysutils/netbt-hcidump/patches/patch-lib_Makefile
@@ -0,0 +1,15 @@
+$NetBSD: patch-lib_Makefile,v 1.2 2012/02/15 09:30:23 plunky Exp $
+
+--- lib/Makefile.orig 2012-02-15 08:56:20.000000000 +0000
++++ lib/Makefile
+@@ -0,0 +1,10 @@
++MKLINT=no
++
++LIB= bluez
++LIBISPRIVATE=yes
++
++SRCS= bluetooth.c hci.c
++
++CPPFLAGS+= -I..
++
++.include <bsd.lib.mk>