Add -z to valid multi-word linker flags
Art uses -z muldefs, allow it to be passed as a property. Change-Id: Ief3b252d4b84762dbd49766ecdbebe00b333f523
This commit is contained in:
@@ -74,7 +74,14 @@ func CheckBadLinkerFlags(ctx BaseModuleContext, prop string, flags []string) {
|
||||
} else if strings.HasPrefix(flag, "-Wl,--version-script") {
|
||||
ctx.PropertyErrorf(prop, "Bad flag: `%s`, use version_script instead", flag)
|
||||
} else if strings.Contains(flag, " ") {
|
||||
ctx.PropertyErrorf(prop, "Bad flag: `%s` is not an allowed multi-word flag. Should it be split into multiple flags?", flag)
|
||||
args := strings.Split(flag, " ")
|
||||
if args[0] == "-z" {
|
||||
if len(args) > 2 {
|
||||
ctx.PropertyErrorf(prop, "`-z` only takes one argument: `%s`", flag)
|
||||
}
|
||||
} else {
|
||||
ctx.PropertyErrorf(prop, "Bad flag: `%s` is not an allowed multi-word flag. Should it be split into multiple flags?", flag)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user