| Index: build/config/compiler/BUILD.gn
|
| diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
|
| index 2ded34ed00ec0fb571e7c3005d624b7acc180473..6c5b973fd5cff090cac407c2b7168893a25eca45 100644
|
| --- a/build/config/compiler/BUILD.gn
|
| +++ b/build/config/compiler/BUILD.gn
|
| @@ -2,6 +2,8 @@
|
| # Use of this source code is governed by a BSD-style license that can be
|
| # found in the LICENSE file.
|
|
|
| +import("//build/config/linux/sysroot.gni")
|
| +
|
| # Base compiler configuration.
|
| config("compiler") {
|
| include_dirs = [ "//", root_gen_dir ]
|
| @@ -45,10 +47,7 @@ config("compiler") {
|
|
|
| # These flags are shared between the C compiler and linker.
|
| common_mac_flags = [
|
| - # Set which SDK to use.
|
| - # TODO(brettw) this needs to be configurable somehow.
|
| - "-isysroot", "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk",
|
| -
|
| + "-isysroot", sysroot,
|
| "-mmacosx-version-min=10.6",
|
| ]
|
|
|
| @@ -123,6 +122,11 @@ config("compiler") {
|
| ]
|
| }
|
|
|
| + if (sysroot != "") {
|
| + cflags += "--sysroot=" + sysroot
|
| + ldflags += "--sysroot=" + sysroot
|
| + }
|
| +
|
| ldflags += [
|
| "-fPIC",
|
| "-pthread",
|
|
|