summaryrefslogtreecommitdiff
path: root/Android.mk
diff options
context:
space:
mode:
authorDan Fandrich <dan@coneharvesters.com>2010-07-09 16:11:36 -0700
committerDan Fandrich <dan@coneharvesters.com>2010-07-09 16:11:36 -0700
commit1dbb9a0ba49a927c5e840d81459fdadc8d3edb27 (patch)
tree450f3e6e541a708d1dd81c388f99ea0cce08af66 /Android.mk
parente7743aa7b4862df945a9586c181dfc1429c02d8c (diff)
downloadcurl-1dbb9a0ba49a927c5e840d81459fdadc8d3edb27.tar.gz
Improved the Android build instructions
Diffstat (limited to 'Android.mk')
-rw-r--r--Android.mk26
1 files changed, 17 insertions, 9 deletions
diff --git a/Android.mk b/Android.mk
index b93481a85..f93f2b59c 100644
--- a/Android.mk
+++ b/Android.mk
@@ -12,15 +12,23 @@
# shown. Now, from the external/curl/ directory, run curl's normal configure
# command with flags that match what Android itself uses. This will mean
# putting the compiler directory into the PATH, putting the -I, -isystem and
-# -D options into CPPFLAGS, putting the -m, -f, -O and -nostdlib options into
-# CFLAGS, and putting the -Wl, -L and -l options into LIBS, along with the path
-# to the files libgcc.a, crtbegin_dynamic.o, and ccrtend_android.o. Remember
-# that the paths must be absolute since you will not be running configure from
-# the same directory as the Android make. The normal cross-compiler options
-# must also be set.
+# -D options into CPPFLAGS, putting the -W, -m, -f, -O and -nostdlib options
+# into CFLAGS, and putting the -Wl, -L and -l options into LIBS, along with the
+# path to the files libgcc.a, crtbegin_dynamic.o, and ccrtend_android.o.
+# Remember that the paths must be absolute since you will not be running
+# configure from the same directory as the Android make. The normal
+# cross-compiler options must also be set. Note that the -c, -o, -MD and
+# similar flags must not be set.
+#
+# To see all the LIBS options, you'll need to do the "showcommands" trick on an
+# executable that's already buildable and watch what flags Android uses to link
+# it (dhcpcd is a good choice to watch). You'll also want to add -L options to
+# LIBS that point to the out/.../obj/lib/ and out/.../obj/system/lib/
+# directories so that additional libraries can be found and used by curl.
#
# The end result will be a configure command that looks something like this
-# (the environment variable A is set to the Android root path):
+# (the environment variable A is set to the Android root path which makes the
+# command shorter):
#
# A=`realpath ../..` && \
# PATH="$A/prebuilt/linux-x86/toolchain/arm-eabi-X/bin:$PATH" \
@@ -34,7 +42,7 @@
# into the right place (see the note about this below).
#
# Dan Fandrich
-# May 2010
+# July 2010
LOCAL_PATH:= $(call my-dir)
@@ -91,7 +99,7 @@ LOCAL_SYSTEM_SHARED_LIBRARIES := libc
LOCAL_C_INCLUDES += $(LOCAL_PATH)/include $(LOCAL_PATH)/lib
# This will also need to include $(CURLX_ONES) in order to correctly link
-# against a dynamic library
+# if libcurl is changed to be a dynamic library
LOCAL_CFLAGS += $(common_CFLAGS)
include $(BUILD_EXECUTABLE)