droid-makefile 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. APP := lib$(PROJECT)_$(MARCH).$(EXT)
  2. CFLAGS := $(CFLAGS_LIB) -I./include -I../tinySAK/src -I../tinyNET/src -I../tinyHTTP/include -I../tinySDP/include
  3. LDFLAGS := $(LDFLAGS_LIB) -ltinySAK_$(MARCH) -ltinyNET_$(MARCH) -ltinyHTTP_$(MARCH) -ltinySDP_$(MARCH)
  4. all: $(APP)
  5. OBJS = \
  6. src/tmsrp.o\
  7. src/tmsrp_event.o\
  8. src/tmsrp_message.o\
  9. src/tmsrp_uri.o
  10. ### Headers
  11. OBJS += src/headers/tmsrp_header.o\
  12. src/headers/tmsrp_header_Authentication-Info.o\
  13. src/headers/tmsrp_header_Authorization.o\
  14. src/headers/tmsrp_header_Byte-Range.o\
  15. src/headers/tmsrp_header_Content-Type.o\
  16. src/headers/tmsrp_header_Dummy.o\
  17. src/headers/tmsrp_header_Expires.o\
  18. src/headers/tmsrp_header_Failure-Report.o\
  19. src/headers/tmsrp_header_From-Path.o\
  20. src/headers/tmsrp_header_Max-Expires.o\
  21. src/headers/tmsrp_header_Message-ID.o\
  22. src/headers/tmsrp_header_Min-Expires.o\
  23. src/headers/tmsrp_header_Status.o\
  24. src/headers/tmsrp_header_Success-Report.o\
  25. src/headers/tmsrp_header_To-Path.o\
  26. src/headers/tmsrp_header_Use-Path.o\
  27. src/headers/tmsrp_header_WWW-Authenticate.o
  28. ### parsers
  29. OBJS += src/parsers/tmsrp_parser_message.o\
  30. src/parsers/tmsrp_parser_uri.o
  31. ### session
  32. OBJS += src/session/tmsrp_config.o\
  33. src/session/tmsrp_data.o \
  34. src/session/tmsrp_receiver.o \
  35. src/session/tmsrp_sender.o
  36. $(APP): $(OBJS)
  37. ifeq ($(EXT), a)
  38. $(AR) rcs $@ $^
  39. else
  40. $(CC) $(LDFLAGS) -o $@ $^
  41. endif
  42. %.o: %.c
  43. $(CC) -c $(INCLUDE) $(CFLAGS) $< -o $@
  44. install: $(APP)
  45. $(ANDROID_SDK_ROOT)/tools/adb remount
  46. $(ANDROID_SDK_ROOT)/tools/adb push $(APP) $(LIB_DIR)/$(APP)
  47. $(ANDROID_SDK_ROOT)/tools/adb shell chmod 777 $(LIB_DIR)/$(APP)
  48. clean:
  49. @rm -f $(OBJS) $(APP)