Merge change 6059 into donut

* changes:
  Also look in vendor/*/build for vendorsetup.sh
diff --git a/core/prelink-linux-arm.map b/core/prelink-linux-arm.map
index 8925e22..75c05e5 100644
--- a/core/prelink-linux-arm.map
+++ b/core/prelink-linux-arm.map
@@ -149,3 +149,4 @@
 librpc.so               0x9A400000
 libtrace_test.so        0x9A300000
 libsrec_jni.so          0x9A200000
+libcerttool_jni.so      0x9A100000
diff --git a/core/tasks/cts.mk b/core/tasks/cts.mk
index 33cdf93..eed9beb 100644
--- a/core/tasks/cts.mk
+++ b/core/tasks/cts.mk
@@ -25,6 +25,8 @@
 endif
 CTS_HOST_JAR := $(HOST_OUT_JAVA_LIBRARIES)/cts.jar
 
+junit_host_jar := $(HOST_OUT_JAVA_LIBRARIES)/junit.jar
+
 CTS_CORE_CASE_LIST := android.core.tests.annotation \
 	android.core.tests.archive \
 	android.core.tests.concurrent \
@@ -76,7 +78,9 @@
 
 DEFAULT_TEST_PLAN := $(PRIVATE_DIR)/resource/plans
 
-$(cts_dir)/all_cts_files_stamp: $(CTS_CASE_LIST) | $(ACP)
+$(cts_dir)/all_cts_files_stamp: PRIVATE_JUNIT_HOST_JAR := $(junit_host_jar)
+
+$(cts_dir)/all_cts_files_stamp: $(CTS_CASE_LIST) $(junit_host_jar) $(ACP)
 # Make necessary directory for CTS
 	@rm -rf $(PRIVATE_CTS_DIR)
 	@mkdir -p $(TMP_DIR)
@@ -87,6 +91,8 @@
 # Copy executable to CTS directory
 	$(hide) $(ACP) -fp $(CTS_HOST_JAR) $(PRIVATE_DIR)/tools
 	$(hide) $(ACP) -fp $(CTS_EXECUTABLE_PATH) $(PRIVATE_DIR)/tools
+# Copy junit jar
+	$(hide) $(ACP) -fp $(PRIVATE_JUNIT_HOST_JAR) $(PRIVATE_DIR)/tools
 # Change mode of the executables
 	$(hide) chmod ug+rwX $(PRIVATE_DIR)/tools/$(notdir $(CTS_EXECUTABLE_PATH))
 	$(foreach apk,$(CTS_CASE_LIST), \
diff --git a/tools/applypatch/applypatch.c b/tools/applypatch/applypatch.c
index 49ec97f..185d3de 100644
--- a/tools/applypatch/applypatch.c
+++ b/tools/applypatch/applypatch.c
@@ -541,14 +541,6 @@
 // TODO: make the interface more sensible for use as a library.
 
 int applypatch(int argc, char** argv) {
-
-  printf("applypatch  argc %d\n", argc);
-  int xx;
-  for (xx = 0; xx < argc; ++xx) {
-    printf("%d %p %s\n", xx, argv[xx], argv[xx]);
-    fflush(stdout);
-  }
-
   if (argc < 2) {
     return 2;
   }
diff --git a/tools/droiddoc/templates-pdk/customization.cs b/tools/droiddoc/templates-pdk/customization.cs
index 3740469..e2d6682 100644
--- a/tools/droiddoc/templates-pdk/customization.cs
+++ b/tools/droiddoc/templates-pdk/customization.cs
@@ -15,10 +15,10 @@
                   elif:community ?> <?cs
                   elif:publish ?> <?cs
                   elif:about ?> <?cs /if ?>">
-              <li id="guide-link"><a href="<?cs var:toroot ?>guide/index.html"
+              <!--<li id="guide-link"><a href="<?cs var:toroot ?>guide/index.html"
                                   onClick="return loadLast('guide)'"><span>Dev Guide</span></a></li>
               <li id="opensource-link"><a href="http://source.android.com/"
-				 onClick="return loadLast('open')"><span>Open Source</span></a></li>
+				 onClick="return loadLast('open')"><span>Open Source</span></a></li>-->
           </ul> 
       </div>
       <div id="headerRight">
diff --git a/tools/releasetools/ota_from_target_files b/tools/releasetools/ota_from_target_files
index 547c65c..ea4c752 100755
--- a/tools/releasetools/ota_from_target_files
+++ b/tools/releasetools/ota_from_target_files
@@ -580,7 +580,9 @@
     script.FormatPartition("userdata")
 
   script.Print("Removing unneeded files...")
-  script.DeleteFiles(["/"+i[0] for i in verbatim_targets])
+  script.DeleteFiles(["/"+i[0] for i in verbatim_targets] +
+                     ["/"+i for i in sorted(source_data)
+                            if i not in target_data])
 
   if updating_boot:
     # Produce the boot image by applying a patch to the current