1 # Google Android makefile for curl and libcurl
2 # Place the curl source (including this makefile) into external/curl/ in the
3 # Android source tree. Then build them with 'make curl' or just 'make libcurl'
4 # from the Android root.
6 # Note: you must first create a curl_config.h file by running configure in the
7 # Android environment. I haven't found an easy way to do this yet. If there is
8 # no easy way, a static config-android.h may need to be created and checked in
9 # to the libcurl source tree.
14 LOCAL_PATH:= $(call my-dir)
16 common_CFLAGS := -Wpointer-arith -Wwrite-strings -Wunused -Winline -Wnested-externs -Wmissing-declarations -Wmissing-prototypes -Wno-long-long -Wfloat-equal -Wno-multichar -Wsign-compare -Wno-format-nonliteral -Wendif-labels -Wstrict-prototypes -Wdeclaration-after-statement -Wno-system-headers -DHAVE_CONFIG_H
18 #########################
19 # Build the libcurl library
22 include $(LOCAL_PATH)/lib/Makefile.inc
23 LOCAL_SRC_FILES := $(addprefix lib/,$(CSOURCES))
24 LOCAL_C_INCLUDES += $(LOCAL_PATH)/include/
25 LOCAL_CFLAGS += $(common_CFLAGS)
27 LOCAL_MODULE:= libcurl
29 include $(BUILD_STATIC_LIBRARY)
32 #########################
33 # Build the curl binary
36 include $(LOCAL_PATH)/src/Makefile.inc
37 LOCAL_SRC_FILES := $(addprefix src/,$(CURL_SOURCES))
40 LOCAL_STATIC_LIBRARIES := libcurl
41 LOCAL_SYSTEM_SHARED_LIBRARIES := libc
43 LOCAL_C_INCLUDES += $(LOCAL_PATH)/include $(LOCAL_PATH)/lib
45 # This will also need to include $(CURLX_ONES) in order to correctly build
47 LOCAL_CFLAGS += $(common_CFLAGS)
49 include $(BUILD_EXECUTABLE)