aboutsummaryrefslogtreecommitdiffstats
path: root/android/build
diff options
context:
space:
mode:
authorDavid 'Digit' Turner <digit@android.com>2011-06-29 13:16:16 +0200
committerDavid 'Digit' Turner <digit@android.com>2011-07-05 23:32:43 +0200
commit42fc4496541acdcaf49bcdf3fcffe247be985fe0 (patch)
tree5fcf6de41dd6b6ea1d6d829b0f0add93dd4fc127 /android/build
parent83c8f4e018e6a5e149c7836a388854255b81617f (diff)
downloadexternal_qemu-42fc4496541acdcaf49bcdf3fcffe247be985fe0.zip
external_qemu-42fc4496541acdcaf49bcdf3fcffe247be985fe0.tar.gz
external_qemu-42fc4496541acdcaf49bcdf3fcffe247be985fe0.tar.bz2
hw-config-defs.h: Remove from source tree + auto-generate
This patch modifies the emulator's build system to place the auto-generated file android/avd/hw-config-defs.h into the build directory. Before that, the file was placed in the source tree. + Fix the standalone build system to properly deal with generated source file dependencies + LOCAL_C_INCLUDES Change-Id: I4e77cd20bf4ca21f79d5dd19f27724bd8be53a79
Diffstat (limited to 'android/build')
-rw-r--r--android/build/binary.make5
-rw-r--r--android/build/definitions.make13
2 files changed, 18 insertions, 0 deletions
diff --git a/android/build/binary.make b/android/build/binary.make
index f6542dc..3bc4fe9 100644
--- a/android/build/binary.make
+++ b/android/build/binary.make
@@ -25,6 +25,8 @@ LOCAL_GENERATED_C_SOURCES := $(filter %.c,$(LOCAL_GENERATED_SOURCES))
LOCAL_CXX_SOURCES := $(filter %$(LOCAL_CPP_EXTENSION),$(LOCAL_SRC_FILES) $(LOCAL_GENERATED_SOURCES))
LOCAL_OBJC_SOURCES := $(filter %.m,$(LOCAL_SRC_FILES) $(LOCAL_GENERATED_SOURCES))
+LOCAL_CFLAGS := $(strip $(patsubst %,-I%,$(LOCAL_C_INCLUDES)) $(LOCAL_CFLAGS))
+
$(foreach src,$(LOCAL_C_SOURCES), \
$(eval $(call compile-c-source,$(src))) \
)
@@ -41,4 +43,7 @@ $(foreach src,$(LOCAL_OBJC_SOURCES), \
$(eval $(call compile-objc-source,$(src))) \
)
+# Ensure that we build all generated sources before the objects
+$(LOCAL_OBJECTS): | $(LOCAL_GENERATED_SOURCES)
+
CLEAN_OBJS_DIRS += $(LOCAL_OBJS_DIR)
diff --git a/android/build/definitions.make b/android/build/definitions.make
index e31131b..ddf9150 100644
--- a/android/build/definitions.make
+++ b/android/build/definitions.make
@@ -13,6 +13,19 @@
# limitations under the License.
#
+# this turns off the suffix rules built into make
+.SUFFIXES:
+
+# this turns off the RCS / SCCS implicit rules of GNU Make
+% : RCS/%,v
+% : RCS/%
+% : %,v
+% : s.%
+% : SCCS/s.%
+
+# If a rule fails, delete $@.
+.DELETE_ON_ERROR:
+
# shared definitions
ifeq ($(strip $(SHOW)),)
define pretty