summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2024-02-08 01:33:53 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2024-02-08 01:33:53 +0000
commitb6d7051450364c7e5a3a772c5d69e42101bb3002 (patch)
treee1d2f22bb0fba7be3e8136b89f2c416e3746479f
parentacadf7eee42b3f7112ea0429aea9ec07a15446f3 (diff)
parent5aff9775b1cf97be8b33df62a15c430d22b8b62f (diff)
downloaddevelopment-b6d7051450364c7e5a3a772c5d69e42101bb3002.tar.gz
Merge "Snap for 11421525 from 2487e59982b3ce524ca43d14d8ba92403e656d47 to simpleperf-release" into simpleperf-release
-rw-r--r--build/Android.mk2
-rw-r--r--samples/AconfigDemo/Android.bp8
-rw-r--r--samples/AconfigDemo/aconfig_demo_flags.aconfig1
-rw-r--r--samples/AconfigDemo/internal/Android.bp1
-rw-r--r--samples/AconfigDemo/internal/trunk_stable_workflow_test.aconfig1
-rw-r--r--sdk/build_tools_source.prop_template4
-rw-r--r--sdk/plat_tools_source.prop_template2
-rw-r--r--sdk/platform_source.prop_template2
-rw-r--r--tools/cargo_embargo/src/main.rs14
9 files changed, 25 insertions, 10 deletions
diff --git a/build/Android.mk b/build/Android.mk
index 9c1d7b5c1..b873c59d3 100644
--- a/build/Android.mk
+++ b/build/Android.mk
@@ -51,7 +51,7 @@ $(sample_props) : $(HOST_OUT)/development/samples/%_source.properties : $(TOPDIR
# ===== SDK jar file of stubs =====
# A.k.a the "current" version of the public SDK (android.jar inside the SDK package).
-full_target := $(call intermediates-dir-for,JAVA_LIBRARIES,$(ANDROID_PUBLIC_STUBS),,COMMON)/classes.jar
+full_target := $(call intermediates-dir-for,JAVA_LIBRARIES,$(ANDROID_PUBLIC_EXPORTABLE_STUBS),,COMMON)/classes.jar
full_src_target := $(call intermediates-dir-for,ETC,frameworks-base-api-current.srcjar)/frameworks-base-api-current.srcjar
# android.jar is what we put in the SDK package.
diff --git a/samples/AconfigDemo/Android.bp b/samples/AconfigDemo/Android.bp
index 7ce4e0172..628fe5b0e 100644
--- a/samples/AconfigDemo/Android.bp
+++ b/samples/AconfigDemo/Android.bp
@@ -6,7 +6,7 @@ android_app {
name: "AconfigDemoActivity",
manifest: "AndroidManifest.xml",
srcs: [
- "src/**/*.java"
+ "src/**/*.java",
],
platform_apis: true,
certificate: "platform",
@@ -28,6 +28,7 @@ android_app {
aconfig_declarations {
name: "aconfig_demo_flags",
package: "com.example.android.aconfig.demo.flags",
+ container: "system",
srcs: ["aconfig_demo_flags.aconfig"],
}
@@ -60,7 +61,6 @@ java_library {
],
}
-
cc_aconfig_library {
name: "aconfig_demo_flags_c_lib",
aconfig_declarations: "aconfig_demo_flags",
@@ -77,7 +77,7 @@ cc_library {
"-Wno-unused-parameter",
],
header_libs: [
- "jni_headers",
+ "jni_headers",
],
shared_libs: [
"server_configurable_flags",
@@ -101,7 +101,7 @@ rust_ffi_shared {
rustlibs: [
"libjni",
"libaconfig_demo_flags_rust",
- ]
+ ],
}
// Test setup
diff --git a/samples/AconfigDemo/aconfig_demo_flags.aconfig b/samples/AconfigDemo/aconfig_demo_flags.aconfig
index 2b685727b..80f4f6eac 100644
--- a/samples/AconfigDemo/aconfig_demo_flags.aconfig
+++ b/samples/AconfigDemo/aconfig_demo_flags.aconfig
@@ -1,4 +1,5 @@
package: "com.example.android.aconfig.demo.flags"
+container: "system"
flag {
name: "append_injected_content"
diff --git a/samples/AconfigDemo/internal/Android.bp b/samples/AconfigDemo/internal/Android.bp
index 49e7b75d8..a59cdfe75 100644
--- a/samples/AconfigDemo/internal/Android.bp
+++ b/samples/AconfigDemo/internal/Android.bp
@@ -5,5 +5,6 @@ package {
aconfig_declarations {
name: "trunk_stable_workflow_testing",
package: "com.android.trunk_stable_workflow_testing",
+ container: "system",
srcs: ["trunk_stable_workflow_test.aconfig"],
}
diff --git a/samples/AconfigDemo/internal/trunk_stable_workflow_test.aconfig b/samples/AconfigDemo/internal/trunk_stable_workflow_test.aconfig
index bba9f76dc..ecab3cc22 100644
--- a/samples/AconfigDemo/internal/trunk_stable_workflow_test.aconfig
+++ b/samples/AconfigDemo/internal/trunk_stable_workflow_test.aconfig
@@ -1,4 +1,5 @@
package: "com.android.trunk_stable_workflow_testing"
+container: "system"
flag {
name: "welcome_aboard"
diff --git a/sdk/build_tools_source.prop_template b/sdk/build_tools_source.prop_template
index 4fb49e3ed..2814cab1c 100644
--- a/sdk/build_tools_source.prop_template
+++ b/sdk/build_tools_source.prop_template
@@ -1,3 +1,3 @@
Pkg.UserSrc=false
-Pkg.Revision=${PLATFORM_SDK_VERSION}.0.0
-#Pkg.Revision=34.0.0 rc3
+#Pkg.Revision=${PLATFORM_SDK_VERSION}.0.0
+Pkg.Revision=35.0.0 rc1
diff --git a/sdk/plat_tools_source.prop_template b/sdk/plat_tools_source.prop_template
index 3087fc4c5..3c43ef261 100644
--- a/sdk/plat_tools_source.prop_template
+++ b/sdk/plat_tools_source.prop_template
@@ -1,2 +1,2 @@
Pkg.UserSrc=false
-Pkg.Revision=34.0.5
+Pkg.Revision=35.0.0
diff --git a/sdk/platform_source.prop_template b/sdk/platform_source.prop_template
index 34766b781..fa996c7e3 100644
--- a/sdk/platform_source.prop_template
+++ b/sdk/platform_source.prop_template
@@ -2,7 +2,7 @@ Pkg.Desc=Android SDK Platform ${PLATFORM_VERSION}
Pkg.UserSrc=false
Platform.Version=${PLATFORM_VERSION}
Platform.CodeName=
-Pkg.Revision=2
+Pkg.Revision=1
AndroidVersion.ApiLevel=${PLATFORM_SDK_VERSION}
AndroidVersion.CodeName=${PLATFORM_VERSION_CODENAME}
AndroidVersion.ExtensionLevel=${PLATFORM_SDK_EXTENSION_VERSION}
diff --git a/tools/cargo_embargo/src/main.rs b/tools/cargo_embargo/src/main.rs
index fab14040c..713bb8ced 100644
--- a/tools/cargo_embargo/src/main.rs
+++ b/tools/cargo_embargo/src/main.rs
@@ -288,7 +288,7 @@ fn make_crates(args: &Args, cfg: &VariantConfig) -> Result<Vec<Crate>> {
}
}
-/// Runs cargo_embargo with the given JSON configuration string.
+/// Runs cargo_embargo with the given JSON configuration file.
fn run_embargo(args: &Args, config_filename: &Path) -> Result<()> {
let cfg = Config::from_file(config_filename)?;
let crates = make_all_crates(args, &cfg)?;
@@ -319,6 +319,18 @@ fn run_embargo(args: &Args, config_filename: &Path) -> Result<()> {
}
}
+ // If we were configured to run cargo, check whether we could have got away without it.
+ if cfg.variants.iter().any(|variant| variant.run_cargo) && package_out_files.is_empty() {
+ let mut cfg_no_cargo = cfg.clone();
+ for variant in &mut cfg_no_cargo.variants {
+ variant.run_cargo = false;
+ }
+ let crates_no_cargo = make_all_crates(args, &cfg_no_cargo)?;
+ if crates_no_cargo == crates {
+ eprintln!("Running cargo appears to be unnecessary for this crate, consider adding `\"run_cargo\": false` to your cargo_embargo.json.");
+ }
+ }
+
write_all_bp(&cfg, crates, &package_out_files)
}