Merge "Revert^2 "Cache Java codegen'd flags in static member variables."" into main
diff --git a/core/config.mk b/core/config.mk
index a26ad67..90cc33c 100644
--- a/core/config.mk
+++ b/core/config.mk
@@ -813,7 +813,11 @@
requirements :=
# Set default value of KEEP_VNDK.
-KEEP_VNDK ?= true
+ifeq ($(RELEASE_DEPRECATE_VNDK),true)
+ KEEP_VNDK ?= false
+else
+ KEEP_VNDK ?= true
+endif
# BOARD_PROPERTY_OVERRIDES_SPLIT_ENABLED can be true only if early-mount of
# partitions is supported. But the early-mount must be supported for full
diff --git a/core/rbe.mk b/core/rbe.mk
index 001a549..0f90ddd 100644
--- a/core/rbe.mk
+++ b/core/rbe.mk
@@ -64,7 +64,7 @@
d8_exec_strategy := remote_local_fallback
endif
- platform := container-image=docker://gcr.io/androidbuild-re-dockerimage/android-build-remoteexec-image@sha256:953fed4a6b2501256a0d17f055dc17884ff71b024e50ade773e0b348a6c303e6
+ platform := container-image=docker://gcr.io/androidbuild-re-dockerimage/android-build-remoteexec-image@sha256:1eb7f64b9e17102b970bd7a1af7daaebdb01c3fb777715899ef462d6c6d01a45
cxx_platform := $(platform),Pool=$(cxx_pool)
java_r8_d8_platform := $(platform),Pool=$(java_pool)
diff --git a/rbesetup.sh b/rbesetup.sh
index 9e246ff..0da7a57 100644
--- a/rbesetup.sh
+++ b/rbesetup.sh
@@ -34,7 +34,7 @@
# for the build to be executed with RBE.
function use_rbe() {
local RBE_BINARIES_DIR="prebuilts/remoteexecution-client/latest"
- local DOCKER_IMAGE="gcr.io/androidbuild-re-dockerimage/android-build-remoteexec-image@sha256:953fed4a6b2501256a0d17f055dc17884ff71b024e50ade773e0b348a6c303e6"
+ local DOCKER_IMAGE="gcr.io/androidbuild-re-dockerimage/android-build-remoteexec-image@sha256:1eb7f64b9e17102b970bd7a1af7daaebdb01c3fb777715899ef462d6c6d01a45"
# Do not set an invocation-ID and let reproxy auto-generate one.
USE_RBE="true" \
diff --git a/tools/metadata/OWNERS b/tools/metadata/OWNERS
new file mode 100644
index 0000000..03bcdf1
--- /dev/null
+++ b/tools/metadata/OWNERS
@@ -0,0 +1,4 @@
+dariofreni@google.com
+joeo@google.com
+ronish@google.com
+caditya@google.com
diff --git a/tools/metadata/generator.go b/tools/metadata/generator.go
index 8e82f7f..eb87755 100644
--- a/tools/metadata/generator.go
+++ b/tools/metadata/generator.go
@@ -73,7 +73,7 @@
return string(data)
}
-func processProtobuf(
+func processTestSpecProtobuf(
filePath string, ownershipMetadataMap *sync.Map, keyLocks *keyToLocksMap,
errCh chan error, wg *sync.WaitGroup,
) {
@@ -130,10 +130,11 @@
func main() {
inputFile := flag.String("inputFile", "", "Input file path")
outputFile := flag.String("outputFile", "", "Output file path")
+ rule := flag.String("rule", "", "Metadata rule (Hint: test_spec or code_metadata)")
flag.Parse()
- if *inputFile == "" || *outputFile == "" {
- fmt.Println("Usage: metadata -inputFile <input file path> -outputFile <output file path>")
+ if *inputFile == "" || *outputFile == "" || *rule == "" {
+ fmt.Println("Usage: metadata -rule <rule> -inputFile <input file path> -outputFile <output file path>")
os.Exit(1)
}
@@ -144,26 +145,33 @@
errCh := make(chan error, len(filePaths))
var wg sync.WaitGroup
- for _, filePath := range filePaths {
- wg.Add(1)
- go processProtobuf(filePath, ownershipMetadataMap, keyLocks, errCh, &wg)
+ switch *rule {
+ case "test_spec":
+ for _, filePath := range filePaths {
+ wg.Add(1)
+ go processTestSpecProtobuf(filePath, ownershipMetadataMap, keyLocks, errCh, &wg)
+ }
+
+ wg.Wait()
+ close(errCh)
+
+ for err := range errCh {
+ log.Fatal(err)
+ }
+
+ allKeys := getSortedKeys(ownershipMetadataMap)
+ var allMetadata []*test_spec_proto.TestSpec_OwnershipMetadata
+
+ for _, key := range allKeys {
+ value, _ := ownershipMetadataMap.Load(key)
+ metadataList := value.([]*test_spec_proto.TestSpec_OwnershipMetadata)
+ allMetadata = append(allMetadata, metadataList...)
+ }
+
+ writeOutput(*outputFile, allMetadata)
+ break
+ case "code_metadata":
+ default:
+ log.Fatalf("No specific processing implemented for rule '%s'.\n", *rule)
}
-
- wg.Wait()
- close(errCh)
-
- for err := range errCh {
- log.Fatal(err)
- }
-
- allKeys := getSortedKeys(ownershipMetadataMap)
- var allMetadata []*test_spec_proto.TestSpec_OwnershipMetadata
-
- for _, key := range allKeys {
- value, _ := ownershipMetadataMap.Load(key)
- metadataList := value.([]*test_spec_proto.TestSpec_OwnershipMetadata)
- allMetadata = append(allMetadata, metadataList...)
- }
-
- writeOutput(*outputFile, allMetadata)
}
diff --git a/tools/metadata/testdata/metadata_test.go b/tools/metadata/testdata/metadata_test.go
index 0cb80c3..03c4f29 100644
--- a/tools/metadata/testdata/metadata_test.go
+++ b/tools/metadata/testdata/metadata_test.go
@@ -10,7 +10,7 @@
func TestMetadata(t *testing.T) {
cmd := exec.Command(
- "metadata", "-inputFile", "./inputFiles.txt", "-outputFile",
+ "metadata", "-rule", "test_spec", "-inputFile", "./inputFiles.txt", "-outputFile",
"./generatedOutputFile.txt",
)
stderr, err := cmd.CombinedOutput()
@@ -40,7 +40,7 @@
func TestMetadataNegativeCase(t *testing.T) {
cmd := exec.Command(
- "metadata", "-inputFile", "./inputFilesNegativeCase.txt", "-outputFile",
+ "metadata", "-rule", "test_spec", "-inputFile", "./inputFilesNegativeCase.txt", "-outputFile",
"./generatedOutputFileNegativeCase.txt",
)
stderr, err := cmd.CombinedOutput()