mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-01-08 12:50:52 +00:00
55 lines
1.6 KiB
Makefile
55 lines
1.6 KiB
Makefile
NAME = BTdaemon
|
|
|
|
SRCDIR = src
|
|
VPATH = src
|
|
|
|
# These paths must be changed to match the compilation environment
|
|
SDK_PATH = /Developer/Platforms/iPhoneOS.platform/Developer
|
|
SDK_VERSION = 2.1
|
|
GCC_VERSION = 4.0.1
|
|
|
|
#
|
|
CXX = $(SDK_PATH)/usr/bin/arm-apple-darwin9-gcc-$(GCC_VERSION)
|
|
CXXFLAGS = -g0 -O2 -Wall -Werror -I. -Iinclude
|
|
LDFLAGS = \
|
|
-multiply_defined suppress \
|
|
-I$(SDK_PATH)/SDKs/iPhoneOS$(SDK_VERSION).sdk/usr/include \
|
|
-I$(SDK_PATH)/SDKs/iPhoneOS$(SDK_VERSION).sdk/usr/lib/gcc/arm-apple-darwin9/4.0.1/include \
|
|
-L$(SDK_PATH)/SDKs/iPhoneOS$(SDK_VERSION).sdk/usr/lib \
|
|
|
|
SRCS = \
|
|
bt_control_iphone.c \
|
|
hci.c \
|
|
hci_dump.c \
|
|
hci_transport_h4.c \
|
|
l2cap.c \
|
|
main.c \
|
|
run_loop.c \
|
|
socket_server.c \
|
|
|
|
HEADERS = \
|
|
bt_control.h \
|
|
bt_control_iphone.h \
|
|
hci.h \
|
|
hci_dump.h \
|
|
hci_transport.h \
|
|
hci_transport_h4.h \
|
|
l2cap.h \
|
|
run_loop.h \
|
|
socket_server.h \
|
|
|
|
all: $(NAME)
|
|
|
|
clean:
|
|
rm -fr $(NAME) *.o
|
|
|
|
$(SRCS): $(HEADERS)
|
|
|
|
$(NAME): $(SRCS)
|
|
$(CXX) $(CXXFLAGS) -o $(NAME) $(filter %.mm,$^) $(filter %.m,$^) $(filter %.c,$^) $(LDFLAGS)
|
|
export CODESIGN_ALLOCATE=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/codesign_allocate ; ldid -S $(NAME)
|
|
ssh root@192.168.3.102 rm -f BTdaemon
|
|
scp $(NAME) root@192.168.3.102:/var/mobile
|
|
|
|
.PHONY: all clean
|