From ea004dd75f53a2b0378ffb242b3956c08f3ea568 Mon Sep 17 00:00:00 2001 From: Risan Date: Mon, 27 Nov 2017 18:14:46 +0900 Subject: [Android.bp] Add ARC++ product variable Test: Compile Bug: 64500663 Change-Id: I92739eb46029f7c808e1f1a928947b3ec596a0b2 --- android/variable.go | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'android/variable.go') diff --git a/android/variable.go b/android/variable.go index c8a672e3..05e283ff 100644 --- a/android/variable.go +++ b/android/variable.go @@ -98,6 +98,11 @@ type variableProperties struct { Uml struct { Cppflags []string } + + Arc struct { + Exclude_srcs []string + Static_libs []string + } } `android:"arch_variant"` } @@ -157,6 +162,7 @@ type productVariables struct { Treble *bool `json:",omitempty"` Pdk *bool `json:",omitempty"` Uml *bool `json:",omitempty"` + Arc *bool `json:",omitempty"` MinimizeJavaDebugInfo *bool `json:",omitempty"` IntegerOverflowExcludePaths *[]string `json:",omitempty"` -- cgit v1.2.3 From 89913356666fd62ddfbabb7e3504b4e99ea279b2 Mon Sep 17 00:00:00 2001 From: Hirokazu Honda Date: Wed, 17 Jan 2018 14:00:33 +0900 Subject: [Android.bp] Add cflags, include_dirs, shared_libs ans srcs to ARC++ Product Test: Compile Bug: None Change-Id: I422f2194208ea14e976970de748d6d9238fe9f14 --- android/variable.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'android/variable.go') diff --git a/android/variable.go b/android/variable.go index dc64e704..baf6de32 100644 --- a/android/variable.go +++ b/android/variable.go @@ -103,8 +103,12 @@ type variableProperties struct { } Arc struct { + Cflags []string Exclude_srcs []string + Include_dirs []string + Shared_libs []string Static_libs []string + Srcs []string } } `android:"arch_variant"` } -- cgit v1.2.3 From 423e2db0f9dc6e359c8a59467a6c6d23da33764e Mon Sep 17 00:00:00 2001 From: Rajeev Kumar Date: Fri, 9 Mar 2018 18:16:35 -0800 Subject: Add product_variables.Use_lmkd_stats_log. Bug: 74443701 Test: Tested manually Merged-In: I512d1a4b5e796b459a7ecdd3649ffd147bcf4cbf Change-Id: I512d1a4b5e796b459a7ecdd3649ffd147bcf4cbf (cherry picked from commit 1e6056a380a4f4cafa853412460de834cfbfb58e) --- android/variable.go | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'android/variable.go') diff --git a/android/variable.go b/android/variable.go index e45cebdc..01a8122d 100644 --- a/android/variable.go +++ b/android/variable.go @@ -102,6 +102,10 @@ type variableProperties struct { Cppflags []string } + Use_lmkd_stats_log struct { + Cflags []string + } + Arc struct { Cflags []string Exclude_srcs []string @@ -179,6 +183,7 @@ type productVariables struct { Enforce_vintf_manifest *bool `json:",omitempty"` Pdk *bool `json:",omitempty"` Uml *bool `json:",omitempty"` + Use_lmkd_stats_log *bool `json:",omitempty"` Arc *bool `json:",omitempty"` MinimizeJavaDebugInfo *bool `json:",omitempty"` -- cgit v1.2.3 From d57ed550fd57c9c6c1093c1368480dfab17ef79a Mon Sep 17 00:00:00 2001 From: Dan Willemsen Date: Fri, 9 Mar 2018 21:22:06 -0800 Subject: Make Config.ProductVariables private All access to these should be going through the methods on Config / DeviceConfig. Bug: 76168832 Test: m blueprint_tools Change-Id: I47512dd58fb1a1a3f25838a9b1adaed2c41af8d3 Merged-In: I47512dd58fb1a1a3f25838a9b1adaed2c41af8d3 (cherry picked from commit 45133ac184b4e8b7071e7755ec3b98e217b54607) --- android/variable.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'android/variable.go') diff --git a/android/variable.go b/android/variable.go index 01a8122d..831c50a5 100644 --- a/android/variable.go +++ b/android/variable.go @@ -293,7 +293,7 @@ func variableMutator(mctx BottomUpMutatorContext) { property := "product_variables." + proptools.PropertyNameForField(name) // Check that the variable was set for the product - val := reflect.ValueOf(mctx.Config().ProductVariables).FieldByName(name) + val := reflect.ValueOf(mctx.Config().productVariables).FieldByName(name) if !val.IsValid() || val.Kind() != reflect.Ptr || val.IsNil() { continue } -- cgit v1.2.3 From 8328367c44085b948c003116c0ed74a047237a69 Mon Sep 17 00:00:00 2001 From: Dan Willemsen Date: Mon, 26 Mar 2018 12:41:18 -0700 Subject: Add VendorConfig for board-level Soong plugin configuration This allows Soong (Go) plugins to get custom configurations set in the current product's BoardConfig.mk. I'll have some more comprehensive documentation later, but the general concept is that you'd have one namespace per plugin, defined in the BoardConfig.mk (though they would work in the product.mk files too): SOONG_CONFIG_NAMESPACES += myPlugin Within that namespace you can set key-value pairs: SOONG_CONFIG_myPlugin := key1 key2 ... ... SOONG_CONFIG_myPlugin_key1 := value ... SOONG_CONFIG_myPlugin_key2 := true Then in your plugin, you can ask for your namespace: vars := ctx.Config().VendorConfig("myPlugin") And then use them: str := vars.String("key1") if vars.Bool("key2") { ... } if vars.IsSet("key3") { ... } Warning: It's not a good idea to fail on missing inputs, since an android tree may contain plugins from multiple owners, and we may configure your modules (but not build/install them) even if they're not meant for the currently configured product. Bug: 76168832 Test: define some variables, use them Test: m blueprint_tools Change-Id: I4c38f5a4344022c6f332de279d9bbef24502e741 Merged-In: I4c38f5a4344022c6f332de279d9bbef24502e741 (cherry picked from commit 0fe7866897b177f2bf7ec934c5615a2b48e48a23) --- android/variable.go | 2 ++ 1 file changed, 2 insertions(+) (limited to 'android/variable.go') diff --git a/android/variable.go b/android/variable.go index 831c50a5..a386b9df 100644 --- a/android/variable.go +++ b/android/variable.go @@ -226,6 +226,8 @@ type productVariables struct { NamespacesToExport []string `json:",omitempty"` PgoAdditionalProfileDirs []string `json:",omitempty"` + + VendorVars map[string]map[string]string `json:",omitempty"` } func boolPtr(v bool) *bool { -- cgit v1.2.3 From e20c1b19045c880e6dfe6bce7c00e7bce0c20318 Mon Sep 17 00:00:00 2001 From: Colin Cross Date: Wed, 18 Apr 2018 11:06:47 -0700 Subject: Fix aapt2 --min-sdk-version after finalized SDK aapt2 --min-sdk-version was using AppsDefaultVersionName(), which is OMR1 for a non-finalized SDK, but 8.1.0 after finalization. Add PlatformSdkCodename() for non-finalized SDKs, use it for DefaultAppTargetSdk(), and pass it for aapt2 --min-sdk-version. Bug: 78224641 Test: TestAppSdkVersion in app_test.go Change-Id: I622eaf92f8a940f79007c2a579536da325700b06 Merged-In: I622eaf92f8a940f79007c2a579536da325700b06 (cherry picked from commit d09b0b653b615c322266fa2a41ecf0f0066bc93d) --- android/variable.go | 1 + 1 file changed, 1 insertion(+) (limited to 'android/variable.go') diff --git a/android/variable.go b/android/variable.go index a386b9df..9d9830ea 100644 --- a/android/variable.go +++ b/android/variable.go @@ -128,6 +128,7 @@ type productVariables struct { DateFromFile *string `json:",omitempty"` Platform_sdk_version *int `json:",omitempty"` + Platform_sdk_codename *string `json:",omitempty"` Platform_sdk_final *bool `json:",omitempty"` Platform_version_active_codenames []string `json:",omitempty"` Platform_version_future_codenames []string `json:",omitempty"` -- cgit v1.2.3 From b691e24d899f3a773da88df0eecada5918a96a2c Mon Sep 17 00:00:00 2001 From: Colin Cross Date: Wed, 9 May 2018 11:11:35 -0700 Subject: Pass platform version name as --version-name for framework-res.apk framework-res.apk should get the platform version name ("9") as --version-name, not the SDK version ("28"). It will get copied to compileSdkVersionCodename in APKs compiled against it. Bug: 78324052 Test: aapt dump badging $OUT/system/framework/framework-res.apk | grep -i version Change-Id: I34a601cb2c14f66199066e7d598862108da0b950 --- android/variable.go | 1 + 1 file changed, 1 insertion(+) (limited to 'android/variable.go') diff --git a/android/variable.go b/android/variable.go index 9d9830ea..f4aaec7a 100644 --- a/android/variable.go +++ b/android/variable.go @@ -127,6 +127,7 @@ type productVariables struct { BuildNumberFromFile *string `json:",omitempty"` DateFromFile *string `json:",omitempty"` + Platform_version_name *string `json:",omitempty"` Platform_sdk_version *int `json:",omitempty"` Platform_sdk_codename *string `json:",omitempty"` Platform_sdk_final *bool `json:",omitempty"` -- cgit v1.2.3