Merge "Allow darwin targets to use -framework CoreFoundation."

This commit is contained in:
Josh Gao
2016-09-01 21:19:07 +00:00
committed by Gerrit Code Review
2 changed files with 4 additions and 4 deletions

View File

@@ -91,8 +91,8 @@ func CheckBadHostLdlibs(ctx ModuleContext, prop string, flags []string) {
flag = strings.TrimSpace(flag)
// TODO: Probably should just redo this property to prefix -l in Soong
if !strings.HasPrefix(flag, "-l") {
ctx.PropertyErrorf(prop, "Invalid flag: `%s`, must start with `-l`", flag)
if !strings.HasPrefix(flag, "-l") && !strings.HasPrefix(flag, "-framework") {
ctx.PropertyErrorf(prop, "Invalid flag: `%s`, must start with `-l` or `-framework`", flag)
} else if !inList(flag, allowed_ldlibs) {
ctx.PropertyErrorf(prop, "Host library `%s` not available", flag)
}

View File

@@ -91,14 +91,14 @@ var (
"10.11",
}
darwinAvailableLibraries = addPrefix([]string{
darwinAvailableLibraries = append(addPrefix([]string{
"c",
"dl",
"m",
"ncurses",
"pthread",
"z",
}, "-l")
}, "-l"), "-framework CoreFoundation")
)
const (