Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(557)

Side by Side Diff: build/toolchain/mac/BUILD.gn

Issue 374213002: Replace deps with depsformat in GN tool defs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « build/toolchain/gcc_toolchain.gni ('k') | build/toolchain/nacl/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 # TODO(brettw) Use "gcc_toolchain.gni" like the Linux toolchains. This requires 5 # TODO(brettw) Use "gcc_toolchain.gni" like the Linux toolchains. This requires
6 # some enhancements since the commands on Mac are slightly different than on 6 # some enhancements since the commands on Mac are slightly different than on
7 # Linux. 7 # Linux.
8 8
9 import("../goma.gni") 9 import("../goma.gni")
10 10
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 ld = invoker.ld 52 ld = invoker.ld
53 53
54 # Make these apply to all tools below. 54 # Make these apply to all tools below.
55 lib_prefix = "-l" 55 lib_prefix = "-l"
56 lib_dir_prefix="-L" 56 lib_dir_prefix="-L"
57 57
58 tool("cc") { 58 tool("cc") {
59 command = "$cc -MMD -MF \$out.d \$defines \$includes \$cflags \$cflags_c \ $cflags_pch_c -c \$in -o \$out" 59 command = "$cc -MMD -MF \$out.d \$defines \$includes \$cflags \$cflags_c \ $cflags_pch_c -c \$in -o \$out"
60 description = "CC \$out" 60 description = "CC \$out"
61 depfile = "\$out.d" 61 depfile = "\$out.d"
62 deps = "gcc" 62 depsformat = "gcc"
63 } 63 }
64 tool("cxx") { 64 tool("cxx") {
65 command = "$cxx -MMD -MF \$out.d \$defines \$includes \$cflags \$cflags_cc \$cflags_pch_cc -c \$in -o \$out" 65 command = "$cxx -MMD -MF \$out.d \$defines \$includes \$cflags \$cflags_cc \$cflags_pch_cc -c \$in -o \$out"
66 description = "CXX \$out" 66 description = "CXX \$out"
67 depfile = "\$out.d" 67 depfile = "\$out.d"
68 deps = "gcc" 68 depsformat = "gcc"
69 } 69 }
70 tool("objc") { 70 tool("objc") {
71 command = "$cc -MMD -MF \$out.d \$defines \$includes \$cflags \$cflags_c \ $cflags_objc \$cflags_pch_objc -c \$in -o \$out" 71 command = "$cc -MMD -MF \$out.d \$defines \$includes \$cflags \$cflags_c \ $cflags_objc \$cflags_pch_objc -c \$in -o \$out"
72 description = "OBJC \$out" 72 description = "OBJC \$out"
73 depfile = "\$out.d" 73 depfile = "\$out.d"
74 deps = "gcc" 74 depsformat = "gcc"
75 } 75 }
76 tool("objcxx") { 76 tool("objcxx") {
77 command = "$cxx -MMD -MF \$out.d \$defines \$includes \$cflags \$cflags_cc \$cflags_objcc \$cflags_pch_objcc -c \$in -o \$out" 77 command = "$cxx -MMD -MF \$out.d \$defines \$includes \$cflags \$cflags_cc \$cflags_objcc \$cflags_pch_objcc -c \$in -o \$out"
78 description = "OBJCXX \$out" 78 description = "OBJCXX \$out"
79 depfile = "\$out.d" 79 depfile = "\$out.d"
80 deps = "gcc" 80 depsformat = "gcc"
81 } 81 }
82 tool("alink") { 82 tool("alink") {
83 command = "rm -f \$out && ./gyp-mac-tool filter-libtool libtool \$libtool_ flags -static -o \$out \$in \$postbuilds" 83 command = "rm -f \$out && ./gyp-mac-tool filter-libtool libtool \$libtool_ flags -static -o \$out \$in \$postbuilds"
84 description = "LIBTOOL-STATIC \$out" 84 description = "LIBTOOL-STATIC \$out"
85 } 85 }
86 tool("solink") { 86 tool("solink") {
87 command = "if [ ! -e \$lib -o ! -e \${lib}.TOC ] || otool -l \$lib | grep -q LC_REEXPORT_DYLIB ; then $ld -shared \$ldflags -o \$lib -Wl,-filelist,\$rspfi le \$solibs \$libs \$postbuilds && { otool -l \$lib | grep LC_ID_DYLIB -A 5; nm -gP \$lib | cut -f1-2 -d' ' | grep -v U\$\$; true; } > \${lib}.TOC; else $ld -sh ared \$ldflags -o \$lib \$in \$solibs \$libs \$postbuilds && { otool -l \$lib | grep LC_ID_DYLIB -A 5; nm -gP \$lib | cut -f1-2 -d' ' | grep -v U\$\$; true; } > \${lib}.tmp && if ! cmp -s \${lib}.tmp \${lib}.TOC; then mv \${lib}.tmp \${lib} .TOC ; fi; fi" 87 command = "if [ ! -e \$lib -o ! -e \${lib}.TOC ] || otool -l \$lib | grep -q LC_REEXPORT_DYLIB ; then $ld -shared \$ldflags -o \$lib -Wl,-filelist,\$rspfi le \$solibs \$libs \$postbuilds && { otool -l \$lib | grep LC_ID_DYLIB -A 5; nm -gP \$lib | cut -f1-2 -d' ' | grep -v U\$\$; true; } > \${lib}.TOC; else $ld -sh ared \$ldflags -o \$lib \$in \$solibs \$libs \$postbuilds && { otool -l \$lib | grep LC_ID_DYLIB -A 5; nm -gP \$lib | cut -f1-2 -d' ' | grep -v U\$\$; true; } > \${lib}.tmp && if ! cmp -s \${lib}.tmp \${lib}.TOC; then mv \${lib}.tmp \${lib} .TOC ; fi; fi"
88 description = "SOLINK \$lib" 88 description = "SOLINK \$lib"
89 rspfile = "\$out.rsp" 89 rspfile = "\$out.rsp"
90 rspfile_content = "\$in_newline" 90 rspfile_content = "\$in_newline"
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 # Toolchain representing the target build (either mac or iOS). 128 # Toolchain representing the target build (either mac or iOS).
129 mac_clang_toolchain("clang") { 129 mac_clang_toolchain("clang") {
130 toolchain_os = os 130 toolchain_os = os
131 } 131 }
132 132
133 # This toolchain provides a way for iOS target compiles to reference targets 133 # This toolchain provides a way for iOS target compiles to reference targets
134 # compiled for the host system. It just overrides the OS back to "mac". 134 # compiled for the host system. It just overrides the OS back to "mac".
135 mac_clang_toolchain("host_clang") { 135 mac_clang_toolchain("host_clang") {
136 toolchain_os = "mac" 136 toolchain_os = "mac"
137 } 137 }
OLDNEW
« no previous file with comments | « build/toolchain/gcc_toolchain.gni ('k') | build/toolchain/nacl/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698