soong_config: Add TARGET_NEEDS_PLATFORM_TEXT_RELOCATIONS
* Soong product variable 'needs_text_relocations'
Change-Id: Ia22c94922f37c49f0d66a67747efa0ee97b4e477
Signed-off-by: Adrian DC <radian.dc@gmail.com>
diff --git a/build/soong/android/variable.go b/build/soong/android/variable.go
index 11569a3..c56c36b 100644
--- a/build/soong/android/variable.go
+++ b/build/soong/android/variable.go
@@ -1,6 +1,10 @@
package android
type Product_variables struct {
+ Needs_text_relocations struct {
+ Cppflags []string
+ }
}
type ProductVariables struct {
+ Needs_text_relocations *bool `json:",omitempty"`
}
diff --git a/build/soong/soong_config.mk b/build/soong/soong_config.mk
index ac7e900..331f123 100644
--- a/build/soong/soong_config.mk
+++ b/build/soong/soong_config.mk
@@ -4,5 +4,6 @@
$(hide) (\
echo '{'; \
echo '"Lineage": {'; \
+ echo ' "Needs_text_relocations": $(if $(filter true,$(TARGET_NEEDS_PLATFORM_TEXT_RELOCATIONS)),true,false)'; \
echo '},'; \
echo '') > $(SOONG_VARIABLES_TMP)