Merge "docs: style tweaks to sidebox and qv classes"
diff --git a/core/base_rules.mk b/core/base_rules.mk
index c4e19b4..0ad797a 100644
--- a/core/base_rules.mk
+++ b/core/base_rules.mk
@@ -411,6 +411,7 @@
 $(LOCAL_INTERMEDIATE_TARGETS) : PRIVATE_AAPT_FLAGS:= $(LOCAL_AAPT_FLAGS)
 $(LOCAL_INTERMEDIATE_TARGETS) : PRIVATE_JAVA_LIBRARIES:= $(LOCAL_JAVA_LIBRARIES)
 $(LOCAL_INTERMEDIATE_TARGETS) : PRIVATE_MANIFEST_PACKAGE_NAME:= $(LOCAL_MANIFEST_PACKAGE_NAME)
+$(LOCAL_INTERMEDIATE_TARGETS) : PRIVATE_INSTRUMENTATION_FOR_PACKAGE_NAME:= $(LOCAL_INSTRUMENTATION_FOR_PACKAGE_NAME)
 
 $(LOCAL_INTERMEDIATE_TARGETS) : PRIVATE_ALL_JAVA_LIBRARIES:= $(full_java_libs)
 $(LOCAL_INTERMEDIATE_TARGETS) : PRIVATE_IS_HOST_MODULE := $(LOCAL_IS_HOST_MODULE)
diff --git a/core/definitions.mk b/core/definitions.mk
index 4b39d0b..5768c6d 100644
--- a/core/definitions.mk
+++ b/core/definitions.mk
@@ -1234,7 +1234,8 @@
     $(addprefix --target-sdk-version , $(DEFAULT_APP_TARGET_SDK)) \
     $(addprefix --version-code , $(PLATFORM_SDK_VERSION)) \
     $(addprefix --version-name , $(PLATFORM_VERSION)) \
-    $(addprefix --rename-manifest-package , $(PRIVATE_MANIFEST_PACKAGE_NAME))
+    $(addprefix --rename-manifest-package , $(PRIVATE_MANIFEST_PACKAGE_NAME)) \
+    $(addprefix --rename-instrumentation-target-package , $(PRIVATE_INSTRUMENTATION_FOR_PACKAGE_NAME))
 endef
 
 ifeq ($(HOST_OS),windows)
@@ -1378,6 +1379,7 @@
     $(addprefix --version-code , $(PLATFORM_SDK_VERSION)) \
     $(addprefix --version-name , $(PLATFORM_VERSION)) \
     $(addprefix --rename-manifest-package , $(PRIVATE_MANIFEST_PACKAGE_NAME)) \
+    $(addprefix --rename-instrumentation-target-package , $(PRIVATE_INSTRUMENTATION_FOR_PACKAGE_NAME)) \
     -F $@
 endef
 
@@ -1742,18 +1744,19 @@
 #  $(2): Old LOCAL_PACKAGE_NAME value.
 #  $(3): New LOCAL_PACKAGE_NAME value.
 #  $(4): New LOCALE_MANIFEST_PACKAGE_NAME value.
-#  $(5): New LOCAL_CERTIFICATE value.
+#  $(5): New LOCAL_INSTRUMENTATION_FOR_PACKAGE_NAME value.
+#  $(6): New LOCAL_CERTIFICATE value.
 #
 # Note that LOCAL_PACKAGE_OVERRIDES is NOT cleared in
 # clear_vars.mk.
 ###########################################################
 define inherit-package
-  $(eval $(call inherit-package-internal,$(1),$(2),$(3),$(4)))
+  $(eval $(call inherit-package-internal,$(1),$(2),$(3),$(4),$(5)))
 endef
 
 define inherit-package-internal
   LOCAL_PACKAGE_OVERRIDES \
-      := $(strip $(1))||$(strip $(2))||$(strip $(3))||$(strip $(4))||$(strip $(5)) $(LOCAL_PACKAGE_OVERRIDES)
+      := $(strip $(1))||$(strip $(2))||$(strip $(3))||$(strip $(4))||&&$(strip $(5))||$(strip $(6)) $(LOCAL_PACKAGE_OVERRIDES)
   include $(1)
   LOCAL_PACKAGE_OVERRIDES \
       := $(wordlist 1,$(words $(LOCAL_PACKAGE_OVERRIDES)), $(LOCAL_PACKAGE_OVERRIDES))
@@ -1775,7 +1778,8 @@
   $(if $(filter $(word 2,$(_n)),$(LOCAL_PACKAGE_NAME)), \
     $(eval LOCAL_PACKAGE_NAME := $(word 3,$(_o))) \
     $(eval LOCAL_MANIFEST_PACKAGE_NAME := $(word 4,$(_o))) \
-    $(call keep-or-override,LOCAL_CERTIFICATE,$(word 5,$(_o))) \
+    $(call keep-or-override,LOCAL_INSTRUMENTATION_FOR_PACKAGE_NAME,$(patsubst &&%,%,$(word 5,$(_o)))) \
+    $(call keep-or-override,LOCAL_CERTIFICATE,$(word 6,$(_o))) \
     $(eval LOCAL_OVERRIDES_PACKAGES := $(sort $(LOCAL_OVERRIDES_PACKAGES) $(word 2,$(_o)))) \
     true \
   ,)
diff --git a/core/main.mk b/core/main.mk
index 688ad9d..b1a5bff 100644
--- a/core/main.mk
+++ b/core/main.mk
@@ -689,6 +689,7 @@
 	$(INSTALLED_FILES_FILE) \
 	$(INSTALLED_BUILD_PROP_TARGET) \
 	$(BUILT_TARGET_FILES_PACKAGE) \
+	$(INSTALLED_ANDROID_INFO_TXT_TARGET) \
  )
 
 # Tests are installed in userdata.img.  If we're building the tests
diff --git a/envsetup.sh b/envsetup.sh
index 1c114d0..85465b1 100644
--- a/envsetup.sh
+++ b/envsetup.sh
@@ -1037,7 +1037,7 @@
 unset _xarray
 
 # Execute the contents of any vendorsetup.sh files we can find.
-for f in `/bin/ls vendor/*/vendorsetup.sh vendor/*/build/vendorsetup.sh 2> /dev/null`
+for f in `/bin/ls vendor/*/vendorsetup.sh vendor/*/build/vendorsetup.sh device/*/*/vendorsetup.sh 2> /dev/null`
 do
     echo "including $f"
     . $f
diff --git a/target/product/AndroidProducts.mk b/target/product/AndroidProducts.mk
index 94b0e24..2774968 100644
--- a/target/product/AndroidProducts.mk
+++ b/target/product/AndroidProducts.mk
@@ -28,5 +28,6 @@
 PRODUCT_MAKEFILES := \
     $(LOCAL_DIR)/core.mk \
     $(LOCAL_DIR)/generic.mk \
+    $(LOCAL_DIR)/full.mk \
     $(LOCAL_DIR)/sdk.mk \
     $(LOCAL_DIR)/sim.mk
diff --git a/target/product/full.mk b/target/product/full.mk
new file mode 100644
index 0000000..5b95daa
--- /dev/null
+++ b/target/product/full.mk
@@ -0,0 +1,51 @@
+#
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# This is a build configuration for a full-featured build of the
+# Open-Source part of the tree. It's geared toward a US-centric
+# build of the emulator, but all those aspects can be overridden
+# in inherited configurations.
+
+PRODUCT_PACKAGES := \
+    VoiceDialer
+
+# This is the list of locales included in AOSP builds
+PRODUCT_LOCALES := en_US en_GB fr_FR it_IT de_DE es_ES
+
+# Additional settings used in all AOSP builds
+PRODUCT_PROPERTY_OVERRIDES := \
+    keyguard.no_require_sim=true \
+    ro.com.android.dateformat=MM-dd-yyyy \
+    ro.com.android.dataroaming=true \
+    ro.ril.hsxpa=1 \
+    ro.ril.gprsclass=10
+
+PRODUCT_COPY_FILES := \
+    development/data/etc/apns-conf.xml:system/etc/apns-conf.xml \
+    development/data/etc/vold.conf:system/etc/vold.conf
+
+# Pick up some sounds - stick with the short list to save space
+# on smaller devices.
+$(call inherit-product, frameworks/base/data/sounds/OriginalAudio.mk)
+
+$(call inherit-product, build/target/product/generic.mk)
+
+# Overrides
+PRODUCT_NAME := full
+PRODUCT_BRAND := generic
+PRODUCT_DEVICE := generic
+PRODUCT_MODEL := Full Android
+
diff --git a/tools/merge-event-log-tags.py b/tools/merge-event-log-tags.py
index 25ac697..df9ebce 100755
--- a/tools/merge-event-log-tags.py
+++ b/tools/merge-event-log-tags.py
@@ -82,6 +82,12 @@
     if t.tagname in by_tagname:
       orig = by_tagname[t.tagname]
 
+      # Allow an explicit tag number to define an implicit tag number
+      if orig.tagnum is None:
+        orig.tagnum = t.tagnum
+      elif t.tagnum is None:
+        t.tagnum = orig.tagnum
+
       if (t.tagnum == orig.tagnum and
           t.description == orig.description):
         # if the name and description are identical, issue a warning
diff --git a/tools/releasetools/ota_from_target_files b/tools/releasetools/ota_from_target_files
index 0454d6f..ba29f9b 100755
--- a/tools/releasetools/ota_from_target_files
+++ b/tools/releasetools/ota_from_target_files
@@ -153,7 +153,7 @@
       suffix = { False: "", True: "/" }
       input = "".join(["%s%s\n" % (i.name, suffix[i.dir])
                        for i in cls.ITEMS.itervalues() if i.name])
-      output2, error = p.communicate(input)
+      output, error = p.communicate(input)
       assert not error
 
     for line in output.split("\n"):