Merge "Ignore obsolete lines when converting makefiles" am: 8c1ae8f2ff
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1853833 Change-Id: I6966aad04ddd80cd2441ebe239c246bee84ea627
This commit is contained in:
@@ -639,6 +639,12 @@ func prebuiltModulePath(ctx variableAssignmentContext) error {
|
||||
if len(val.Variables) == 1 && varLiteralName(val.Variables[0]) != "" && len(val.Strings) == 2 && val.Strings[0] == "" {
|
||||
fixed = val.Strings[1]
|
||||
varname = val.Variables[0].Name.Strings[0]
|
||||
// TARGET_OUT_OPTIONAL_EXECUTABLES puts the artifact in xbin, which is
|
||||
// deprecated. TARGET_OUT_DATA_APPS install location will be handled
|
||||
// automatically by Soong
|
||||
if varname == "TARGET_OUT_OPTIONAL_EXECUTABLES" || varname == "TARGET_OUT_DATA_APPS" {
|
||||
return nil
|
||||
}
|
||||
} else if len(val.Variables) == 2 && varLiteralName(val.Variables[0]) == "PRODUCT_OUT" && varLiteralName(val.Variables[1]) == "TARGET_COPY_OUT_VENDOR" &&
|
||||
len(val.Strings) == 3 && val.Strings[0] == "" && val.Strings[1] == "/" {
|
||||
fixed = val.Strings[2]
|
||||
|
@@ -1516,7 +1516,23 @@ android_app {
|
||||
],
|
||||
}
|
||||
`,
|
||||
},
|
||||
}, {
|
||||
desc: "Obsolete LOCAL_MODULE_PATH",
|
||||
in: `
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := foo
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_DATA_APPS)
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_OPTIONAL_EXECUTABLES)
|
||||
LOCAL_CTS_TEST_PACKAGE := bar
|
||||
LOCAL_USE_AAPT2 := blah
|
||||
include $(BUILD_PACKAGE)
|
||||
`,
|
||||
expected: `
|
||||
android_app {
|
||||
name: "foo",
|
||||
|
||||
}
|
||||
`},
|
||||
}
|
||||
|
||||
func TestEndToEnd(t *testing.T) {
|
||||
|
Reference in New Issue
Block a user