summaryrefslogtreecommitdiff
path: root/cc/object.go
diff options
context:
space:
mode:
Diffstat (limited to 'cc/object.go')
-rw-r--r--cc/object.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/cc/object.go b/cc/object.go
index 14789081a..3cc089cb0 100644
--- a/cc/object.go
+++ b/cc/object.go
@@ -53,6 +53,11 @@ func (object *objectLinker) linkerProps() []interface{} {
func (*objectLinker) linkerInit(ctx BaseModuleContext) {}
func (object *objectLinker) linkerDeps(ctx DepsContext, deps Deps) Deps {
+ if !ctx.noDefaultCompilerFlags() && ctx.toolchain().Bionic() {
+ // Needed for VNDK builds where bionic headers aren't automatically added.
+ deps.LateSharedLibs = append(deps.LateSharedLibs, "libc")
+ }
+
deps.ObjFiles = append(deps.ObjFiles, object.Properties.Objs...)
return deps
}