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

Side by Side Diff: build/config/mac/base_rules.gni

Issue 2160653002: [iOS/GN] Fix generation of .dSYM for fat binary builds. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
OLDNEW
1 # Copyright 2016 The Chromium Authors. All rights reserved. 1 # Copyright 2016 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 # This file contains rules that are shared between Mac and iOS. 5 # This file contains rules that are shared between Mac and iOS.
6 6
7 import("//build/toolchain/toolchain.gni") 7 import("//build/toolchain/toolchain.gni")
8 import("//build/config/mac/symbols.gni")
8 9
9 if (is_mac) { 10 if (is_mac) {
10 import("//build/config/mac/mac_sdk.gni") 11 import("//build/config/mac/mac_sdk.gni")
11 } else if (is_ios) { 12 } else if (is_ios) {
12 import("//build/config/ios/ios_sdk.gni") 13 import("//build/config/ios/ios_sdk.gni")
13 } 14 }
14 15
15 # Convert plist file to given format. 16 # Convert plist file to given format.
16 # 17 #
17 # Arguments 18 # Arguments
(...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after
307 output_name = _output_name 308 output_name = _output_name
308 output_prefix_override = true 309 output_prefix_override = true
309 output_extension = "" 310 output_extension = ""
310 output_dir = "$target_out_dir/$_link_shared_library_target" 311 output_dir = "$target_out_dir/$_link_shared_library_target"
311 } 312 }
312 313
313 if (_is_fat_build) { 314 if (_is_fat_build) {
314 action(_lipo_shared_library_target) { 315 action(_lipo_shared_library_target) {
315 forward_variables_from(invoker, [ "testonly" ]) 316 forward_variables_from(invoker, [ "testonly" ])
316 visibility = _lipo_shared_library_visibility 317 visibility = _lipo_shared_library_visibility
317 script = "//build/config/mac/xcrun.py" 318 script = "//build/toolchain/mac/linker_driver.py"
318 outputs = [ 319 outputs = [
319 "$target_out_dir/$_lipo_shared_library_target/$_output_name", 320 "$target_out_dir/$_lipo_shared_library_target/$_output_name",
320 ] 321 ]
321 inputs = [ 322 inputs = [
322 "$target_out_dir/$_link_shared_library_target/$_output_name", 323 "$target_out_dir/$_link_shared_library_target/$_output_name",
323 ] 324 ]
324 deps = [ 325 deps = [
325 ":$_link_shared_library_target", 326 ":$_link_shared_library_target",
326 ] 327 ]
327 foreach(_additional_toolchain, additional_toolchains) { 328 foreach(_additional_toolchain, additional_toolchains) {
328 _additional_toolchain_target = "$_target_name($_additional_toolchain)" 329 _additional_toolchain_target = "$_target_name($_additional_toolchain)"
329 deps += [ ":$_additional_toolchain_target" ] 330 deps += [ ":$_additional_toolchain_target" ]
330 inputs += [ get_label_info(_additional_toolchain_target, 331 inputs += [ get_label_info(_additional_toolchain_target,
331 "target_out_dir") + "/$_output_name" ] 332 "target_out_dir") + "/$_output_name" ]
332 } 333 }
333 args = [ 334 args = [
335 "xcrun",
334 "lipo", 336 "lipo",
335 "-create", 337 "-create",
336 "-output", 338 "-output",
337 rebase_path(outputs[0], root_build_dir), 339 rebase_path(outputs[0], root_build_dir),
338 ] + rebase_path(inputs, root_build_dir) 340 ] + rebase_path(inputs, root_build_dir)
341
342 if (enable_dsyms) {
343 outputs += [ "$root_out_dir/$_output_name.dSYM/" ]
344 args +=
345 [ "-Wcrl,dsym," + rebase_path("$root_out_dir/.", root_build_dir) ]
346 }
347 if (enable_stripping) {
348 args += [ "-Wcrl,strip,-x,-S" ]
Robert Sesek 2016/07/18 20:09:43 Does nothing on iOS need to control the strip args
sdefresne 2016/07/19 09:12:12 I've changed to check whether //build/config/mac:s
349 }
339 } 350 }
340 } 351 }
341 352
342 bundle_data(_shared_library_bundle_data) { 353 bundle_data(_shared_library_bundle_data) {
343 visibility = [ ":$_framework_target" ] 354 visibility = [ ":$_framework_target" ]
344 forward_variables_from(invoker, [ "testonly" ]) 355 forward_variables_from(invoker, [ "testonly" ])
345 outputs = [ 356 outputs = [
346 "{{bundle_executable_dir}}/$_output_name", 357 "{{bundle_executable_dir}}/$_output_name",
347 ] 358 ]
348 if (_is_fat_build) { 359 if (_is_fat_build) {
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
468 ] 479 ]
469 args = 480 args =
470 [ 481 [
471 "--input", 482 "--input",
472 "{{source}}", 483 "{{source}}",
473 "--output", 484 "--output",
474 rebase_path("$target_gen_dir/$target_name/{{source_name_part}}.nib"), 485 rebase_path("$target_gen_dir/$target_name/{{source_name_part}}.nib"),
475 ] + ibtool_flags 486 ] + ibtool_flags
476 } 487 }
477 } 488 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698