BLT_DIR  = $(shell dirname $(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST)))
BLT_OBJS = $(BLT_DIR)/.tmp/chan_bluetooth.o

ifeq ($(strip ${MAKEFILE_LIST}), Makefile)
thisshouldnotberun:
	@echo " --- Please read the README and INSTALL file!"
endif

$(BLT_DIR)/.tmp/chan_bluetooth.o: $(BLT_DIR)/chan_bluetooth.c
	$(CC) -c -I$(BLT_DIR) $(CFLAGS) -o $@ $<

chan_bluetooth.so: $(BLT_DIR)/.tmp $(BLT_OBJS)
	$(CC) $(SOLINK) -o $@ $(BLT_OBJS) -lbluetooth

$(BLT_DIR)/.tmp:
	mkdir -p $(BLT_DIR)/.tmp

