Only call make_recovery_patch when BUILDING_SYSTEM_IMAGE.

The recovery patch gets put in the SYSTEM directory. Placing the
recovery patch here doesn't make sense when not building the system
image, as is the case for merged (system + vendor) builds.

Bug: 128838154
Test: Running make droid dist for a device target that sets PRODUCT_BUILD_SYSTEM_IMAGE to false.
Change-Id: Ib5ce8c8490024199f82d0c093e9a7ae2de5f71f5
diff --git a/core/Makefile b/core/Makefile
index 1c53459..7e62ad4 100644
--- a/core/Makefile
+++ b/core/Makefile
@@ -4016,8 +4016,10 @@
 endif
 	$(call generate-userimage-prop-dictionary, $(zip_root)/META/misc_info.txt)
 ifneq ($(INSTALLED_RECOVERYIMAGE_TARGET),)
+ifdef BUILDING_SYSTEM_IMAGE
 	$(hide) PATH=$(foreach p,$(INTERNAL_USERIMAGES_BINARY_PATHS),$(p):)$$PATH MKBOOTIMG=$(MKBOOTIMG) \
 	    build/make/tools/releasetools/make_recovery_patch $(zip_root) $(zip_root)
+endif # BUILDING_SYSTEM_IMAGE
 endif
 ifeq ($(AB_OTA_UPDATER),true)
 	@# When using the A/B updater, include the updater config files in the zip.