Support split /system and /vendor modules from Soong

Soong modules may be split into both /system and /vendor variants.
Ensure that Make libraries link against the correct version based on
whether LOCAL_USE_VNDK is set.

Bug: 36426473
Bug: 36079834
Test: build-aosp_arm64.ninja files are the same before/after
Test: attempt building with BOARD_VNDK_VERSION:=current
Change-Id: I229bc290373743406275f3ca16081eae04c27987
diff --git a/CleanSpec.mk b/CleanSpec.mk
index 791439b..88f9172 100644
--- a/CleanSpec.mk
+++ b/CleanSpec.mk
@@ -414,6 +414,9 @@
 $(call add-clean-step, rm -rf $(PRODUCT_OUT)/data/lib*)
 $(call add-clean-step, rm -rf $(PRODUCT_OUT)/data/vendor/lib*)
 
+# Soong module variant change, remove obsolete intermediates
+$(call add-clean-step, rm -rf $(OUT_DIR)/soong/.intermediates)
+
 # ************************************************
 # NEWER CLEAN STEPS MUST BE AT THE END OF THE LIST
 # ************************************************