From 3923e84a4981a331b618a9633b4d7b325234a419 Mon Sep 17 00:00:00 2001 From: Josh Gao Date: Thu, 29 Sep 2016 14:22:54 -0700 Subject: [PATCH] Allow -lobjc and -framework IOKit in darwin host_ldlibs. Bug: http://b/31321337 Test: mma of external/libusb on darwin Change-Id: I1023a2a7ff1fdf809ac47104bca7b4171861abef --- cc/config/x86_darwin_host.go | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/cc/config/x86_darwin_host.go b/cc/config/x86_darwin_host.go index 1a4972ebe..09418c7f0 100644 --- a/cc/config/x86_darwin_host.go +++ b/cc/config/x86_darwin_host.go @@ -91,14 +91,19 @@ var ( "10.11", } - darwinAvailableLibraries = append(addPrefix([]string{ - "c", - "dl", - "m", - "ncurses", - "pthread", - "z", - }, "-l"), "-framework CoreFoundation") + darwinAvailableLibraries = append( + addPrefix([]string{ + "c", + "dl", + "m", + "ncurses", + "objc", + "pthread", + "z", + }, "-l"), + "-framework CoreFoundation", + "-framework IOKit", + ) ) const (