Ensure SOONG_CONV_DATA is generated even no modules require conversion This change ensures that the `SOONG_CONV_DATA` file is always generated, even when there are no modules that require conversion from Make to Soong. Previously, if no Android.mk files were present in the source code, the `SOONG_CONV` variable would be empty, preventing the creation of `SOONG_CONV_DATA` and causing build failures. Bug: 382385324 Test: m $ANDROID_PRODUCT_OUT/obj/PACKAGING/soong_conversion_intermediates/soong_conv_data Change-Id: Ifd9ec50e1615765f0d440a767a35f87d31a251f0
diff --git a/core/Makefile b/core/Makefile index 642c5bf..45561af 100644 --- a/core/Makefile +++ b/core/Makefile
@@ -872,6 +872,7 @@ SOONG_CONV_DATA := $(call intermediates-dir-for,PACKAGING,soong_conversion)/soong_conv_data $(SOONG_CONV_DATA): @rm -f $@ + @touch $@ # This file must be present even if SOONG_CONV is empty. @$(foreach s,$(SOONG_CONV),echo "$(s),$(SOONG_CONV.$(s).TYPE),$(sort $(SOONG_CONV.$(s).PROBLEMS)),$(sort $(filter-out $(SOONG_ALREADY_CONV),$(SOONG_CONV.$(s).DEPS))),$(sort $(SOONG_CONV.$(s).MAKEFILES)),$(sort $(SOONG_CONV.$(s).INSTALLED))" >>$@;) $(call declare-1p-target,$(SOONG_CONV_DATA),build)