Skip to content

Commit

Permalink
core: Allow overriding device/model/name properties
Browse files Browse the repository at this point in the history
Change-Id: I84c4ecb4d20fe6954551e4f07f739e04bfffd647
  • Loading branch information
luk1337 authored and travarilo committed Dec 1, 2022
1 parent e384076 commit d34a528
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions core/sysprop.mk
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ POST_PROCESS_PROPS := $(HOST_OUT_EXECUTABLES)/post_process_props$(HOST_EXECUTABL
# $(1): Partition name
# $(2): Output file name
define generate-common-build-props
bash -c '\
$(or $(PRODUCT_BUILD_PROP_OVERRIDES),:);\
echo "####################################" >> $(2);\
echo "# from generate-common-build-props" >> $(2);\
echo "# These properties identify this partition image." >> $(2);\
Expand All @@ -42,10 +44,10 @@ define generate-common-build-props
echo "ro.product.$(1).name=$(PRODUCT_SYSTEM_NAME)" >> $(2);\
,\
echo "ro.product.$(1).brand=$(PRODUCT_BRAND)" >> $(2);\
echo "ro.product.$(1).device=$(TARGET_DEVICE)" >> $(2);\
echo "ro.product.$(1).device=$${TARGET_DEVICE:-$(TARGET_DEVICE)}" >> $(2);\
echo "ro.product.$(1).manufacturer=$(PRODUCT_MANUFACTURER)" >> $(2);\
echo "ro.product.$(1).model=$(PRODUCT_MODEL)" >> $(2);\
echo "ro.product.$(1).name=$(TARGET_PRODUCT)" >> $(2);\
echo "ro.product.$(1).model=$${PRODUCT_MODEL:-$(PRODUCT_MODEL)}" >> $(2);\
echo "ro.product.$(1).name=$${TARGET_PRODUCT:-$(TARGET_PRODUCT)}" >> $(2);\
)\
$(if $(filter true,$(ZYGOTE_FORCE_64)),\
$(if $(filter vendor,$(1)),\
Expand All @@ -70,6 +72,7 @@ define generate-common-build-props
echo "ro.$(1).build.version.release=$(PLATFORM_VERSION_LAST_STABLE)" >> $(2);\
echo "ro.$(1).build.version.release_or_codename=$(PLATFORM_VERSION)" >> $(2);\
echo "ro.$(1).build.version.sdk=$(PLATFORM_SDK_VERSION)" >> $(2);\
';\
endef

Expand Down

0 comments on commit d34a528

Please sign in to comment.