Make mk2rbc output paths relative to android root

Previously, mk2rbc would output absolute paths in the load statements.
This caused issues with the new module resolution logic in rbcrun,
and is not something we'd want to check in anyways.

Bug: 280685526
Test: go test
Change-Id: Iae6e3f6be9cecc8e19b6e1fd33c5575ff6864654
This commit is contained in:
Cole Faust
2023-05-09 15:00:58 -07:00
parent 3e63067b11
commit c85d08f63b
3 changed files with 36 additions and 4 deletions

View File

@@ -42,8 +42,8 @@ func TestSoongVariables(t *testing.T) {
{"BUILD_ID", VarClassSoong, starlarkTypeString},
{"PLATFORM_SDK_VERSION", VarClassSoong, starlarkTypeInt},
{"DEVICE_PACKAGE_OVERLAYS", VarClassSoong, starlarkTypeList},
{"ENABLE_CFI", VarClassSoong, starlarkTypeBool},
{"ENABLE_PREOPT", VarClassSoong, starlarkTypeBool},
{"ENABLE_CFI", VarClassSoong, starlarkTypeString},
{"ENABLE_PREOPT", VarClassSoong, starlarkTypeString},
}}
if !reflect.DeepEqual(expected, actual) {
t.Errorf("\nExpected: %v\n Actual: %v", expected, actual)