Skip to content

Commit

Permalink
Do not add archiver_flags feature when crosstool already has one.
Browse files Browse the repository at this point in the history
This is needed for migrating one of the internal crosstools

RELNOTES: None.
PiperOrigin-RevId: 158176295
  • Loading branch information
hlopko authored and katre committed Jun 7, 2017
1 parent 7aacb77 commit 5f83d09
Showing 1 changed file with 21 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -255,28 +255,27 @@ public static String getCppLinkActionConfigs(
" }",
" }",
"}",
"feature {",
" name: 'archiver_flags'",
" flag_set {",
" expand_if_all_available: 'output_execpath'",
" action: 'c++-link-static-library'",
" action: 'c++-link-alwayslink-static-library'",
" action: 'c++-link-pic-static-library'",
" action: 'c++-link-alwayslink-pic-static-library'",
" flag_group {",
ifLinux(
platform,
" flag: 'rcsD'",
" flag: '%{output_execpath}'"),
ifMac(
platform,
" flag: '-static'",
" flag: '-s'",
" flag: '-o'",
" flag: '%{output_execpath}'"),
" }",
" }",
"}",
ifTrue(
!features.contains("archiver_flags"),
"feature {",
" name: 'archiver_flags'",
" flag_set {",
" expand_if_all_available: 'output_execpath'",
" action: 'c++-link-static-library'",
" action: 'c++-link-alwayslink-static-library'",
" action: 'c++-link-pic-static-library'",
" action: 'c++-link-alwayslink-pic-static-library'",
" flag_group {",
ifLinux(platform, " flag: 'rcsD'", " flag: '%{output_execpath}'"),
ifMac(
platform,
" flag: '-static'",
" flag: '-s'",
" flag: '-o'",
" flag: '%{output_execpath}'"),
" }",
" }",
"}"),
"feature {",
" name: 'libraries_to_link'",
" flag_set {",
Expand Down

0 comments on commit 5f83d09

Please sign in to comment.