mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-01-26 21:35:16 +00:00
redirect log_* into hci_dump.pklg
This commit is contained in:
parent
a1d7dd1f6f
commit
808722c4b2
@ -42,7 +42,7 @@ libBTstack.a: $(libBTstack_SOURCES:.c=.o) $(libBTstack_SOURCES:.m=.o)
|
||||
ranlib $@
|
||||
|
||||
BTdaemon: $(BTdaemon_SOURCES)
|
||||
$(CC) $(CPPFLAGS) -o $@ $(BTdaemon_SOURCES) $(LDFLAGS)
|
||||
$(CC) $(CPPFLAGS) -DHAVE_HCI_DUMP -o $@ $(BTdaemon_SOURCES) $(LDFLAGS)
|
||||
@USE_LDID@ export CODESIGN_ALLOCATE=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/codesign_allocate ; ldid -S $@
|
||||
|
||||
clean:
|
||||
|
13
src/debug.h
13
src/debug.h
@ -36,23 +36,36 @@
|
||||
*/
|
||||
|
||||
#include "config.h"
|
||||
#include "hci_dump.h"
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#ifdef ENABLE_LOG_DEBUG
|
||||
#ifdef HAVE_HCI_DUMP
|
||||
#define log_debug(format, ...) hci_dump_log(format, ## __VA_ARGS__)
|
||||
#else
|
||||
#define log_debug(format, ...) printf(format, ## __VA_ARGS__)
|
||||
#endif
|
||||
#else
|
||||
#define log_debug(...)
|
||||
#endif
|
||||
|
||||
#ifdef ENABLE_LOG_INFO
|
||||
#ifdef HAVE_HCI_DUMP
|
||||
#define log_info(format, ...) hci_dump_log(format, ## __VA_ARGS__)
|
||||
#else
|
||||
#define log_info(format, ...) printf(format, ## __VA_ARGS__)
|
||||
#endif
|
||||
#else
|
||||
#define log_info(...)
|
||||
#endif
|
||||
|
||||
#ifdef ENABLE_LOG_ERROR
|
||||
#ifdef HAVE_HCI_DUMP
|
||||
#define log_error(format, ...) hci_dump_log(format, ## __VA_ARGS__)
|
||||
#else
|
||||
#define log_error(format, ...) printf(format, ## __VA_ARGS__)
|
||||
#endif
|
||||
#else
|
||||
#define log_error(...)
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user