Use BOARD_USES_VENDORIMAGE to detect vendor image presence - DO NOT MERGE

When building without vendor/... in the tree, we won't be creating a
vendorimage, so BOARD_VENDORIMAGE_FILE_SYSTEM_TYPE won't be defined. But
we still need to use the vendor image that will be present.

Bug: 31545062
Bug: 30040825
Change-Id: I756adc615aea11da60da4d3a4568caca9fed93ab
(cherry picked from commit 15366542057e7599d8514e9aee602d022c2ea14d)
diff --git a/ b/
index b3661e4..5d335b5 100644
--- a/
+++ b/
@@ -56,3 +56,4 @@
 $(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/EXECUTABLES/lmkd_intermediates/import_includes)
 $(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/SHARED_LIBRARIES/libsysutils_intermediates/import_includes)
 $(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/bin/grep $(PRODUCT_OUT)/system/bin/toolbox)
+$(call add-clean-step, rm -rf $(PRODUCT_OUT)/root/vendor)
diff --git a/rootdir/ b/rootdir/
index 94f5cb7..aa5a520 100644
--- a/rootdir/
+++ b/rootdir/
@@ -125,7 +125,7 @@
     ln -sf /system/etc $(TARGET_ROOT_OUT)/etc; \
     ln -sf /sys/kernel/debug $(TARGET_ROOT_OUT)/d; \
     ln -sf /storage/self/primary $(TARGET_ROOT_OUT)/sdcard
   LOCAL_POST_INSTALL_CMD += ; mkdir -p $(TARGET_ROOT_OUT)/vendor
   LOCAL_POST_INSTALL_CMD += ; ln -sf /system/vendor $(TARGET_ROOT_OUT)/vendor