diff options
author | hlopko <hlopko@google.com> | 2017-08-04 15:56:54 +0200 |
---|---|---|
committer | Dmitry Lomov <dslomov@google.com> | 2017-08-04 17:19:12 +0200 |
commit | 2079a5ca8b3adc645a6df1968f1bd616eab010ca (patch) | |
tree | 13be6bfe163123051d70a14f9e1604656588cfe7 /src/test/java/com/google/devtools/build/lib/packages/util/MOCK_OSX_CROSSTOOL | |
parent | fe9ba893c0ebec19228086356af5fa8d81f2809b (diff) |
Make sure copts is the last feature in osx crosstools
Change https://github.com/bazelbuild/bazel/commit/646cfd81793fc3b87979089aab873310d14e95e6 moved copts to the build variable and in order to keep the
ordering of the flags as before the copts feature needs to be the last feature
in the toolchain. Osx crosstool generator sometimes appended additional
features, that broke this assumption. This cl makes sure copts is the last
feature. In addition, flags directly from action_config will be added first, not
last as they were before.
RELNOTES: Flags from action_config get added first to the command line first,
before the flags from features.
PiperOrigin-RevId: 164257469
Diffstat (limited to 'src/test/java/com/google/devtools/build/lib/packages/util/MOCK_OSX_CROSSTOOL')
-rw-r--r-- | src/test/java/com/google/devtools/build/lib/packages/util/MOCK_OSX_CROSSTOOL | 614 |
1 files changed, 358 insertions, 256 deletions
diff --git a/src/test/java/com/google/devtools/build/lib/packages/util/MOCK_OSX_CROSSTOOL b/src/test/java/com/google/devtools/build/lib/packages/util/MOCK_OSX_CROSSTOOL index fb072bda32..ecf8053fb1 100644 --- a/src/test/java/com/google/devtools/build/lib/packages/util/MOCK_OSX_CROSSTOOL +++ b/src/test/java/com/google/devtools/build/lib/packages/util/MOCK_OSX_CROSSTOOL @@ -1111,23 +1111,14 @@ toolchain { provides: "profile" } feature { - name: "copts" + name: "cpp_linker_flags" flag_set { - action: "assemble" - action: "preprocess-assemble" - action: "c-compile" - action: "c++-compile" - action: "c++-header-parsing" - action: "c++-header-preprocessing" - action: "c++-module-compile" - action: "c++-module-codegen" - action: "objc-compile" - action: "objc++-compile" + action: "c++-link-executable" + action: "c++-link-dynamic-library" flag_group { - flag: "%{copts}" - iterate_over: "copts" + flag: "-undefined" + flag: "dynamic_lookup" } - expand_if_all_available: "copts" } } feature { @@ -1151,14 +1142,35 @@ toolchain { } } feature { - name: "cpp_linker_flags" + name: "apply_simulator_compiler_flags" + } + feature { + name: "unfiltered_cxx_flags" + } + feature { + name: "bitcode_embedded_markers" + } + feature { + name: "bitcode_embedded" + } + feature { + name: "copts" flag_set { - action: "c++-link-executable" - action: "c++-link-dynamic-library" + action: "assemble" + action: "preprocess-assemble" + action: "c-compile" + action: "c++-compile" + action: "c++-header-parsing" + action: "c++-header-preprocessing" + action: "c++-module-compile" + action: "c++-module-codegen" + action: "objc-compile" + action: "objc++-compile" flag_group { - flag: "-undefined" - flag: "dynamic_lookup" + flag: "%{copts}" + iterate_over: "copts" } + expand_if_all_available: "copts" } } feature { @@ -2732,23 +2744,14 @@ toolchain { provides: "profile" } feature { - name: "copts" + name: "cpp_linker_flags" flag_set { - action: "assemble" - action: "preprocess-assemble" - action: "c-compile" - action: "c++-compile" - action: "c++-header-parsing" - action: "c++-header-preprocessing" - action: "c++-module-compile" - action: "c++-module-codegen" - action: "objc-compile" - action: "objc++-compile" + action: "c++-link-executable" + action: "c++-link-dynamic-library" flag_group { - flag: "%{copts}" - iterate_over: "copts" + flag: "-undefined" + flag: "dynamic_lookup" } - expand_if_all_available: "copts" } } feature { @@ -2772,14 +2775,35 @@ toolchain { } } feature { - name: "cpp_linker_flags" + name: "apply_simulator_compiler_flags" + } + feature { + name: "unfiltered_cxx_flags" + } + feature { + name: "bitcode_embedded_markers" + } + feature { + name: "bitcode_embedded" + } + feature { + name: "copts" flag_set { - action: "c++-link-executable" - action: "c++-link-dynamic-library" + action: "assemble" + action: "preprocess-assemble" + action: "c-compile" + action: "c++-compile" + action: "c++-header-parsing" + action: "c++-header-preprocessing" + action: "c++-module-compile" + action: "c++-module-codegen" + action: "objc-compile" + action: "objc++-compile" flag_group { - flag: "-undefined" - flag: "dynamic_lookup" + flag: "%{copts}" + iterate_over: "copts" } + expand_if_all_available: "copts" } } feature { @@ -4357,23 +4381,14 @@ toolchain { provides: "profile" } feature { - name: "copts" + name: "cpp_linker_flags" flag_set { - action: "assemble" - action: "preprocess-assemble" - action: "c-compile" - action: "c++-compile" - action: "c++-header-parsing" - action: "c++-header-preprocessing" - action: "c++-module-compile" - action: "c++-module-codegen" - action: "objc-compile" - action: "objc++-compile" + action: "c++-link-executable" + action: "c++-link-dynamic-library" flag_group { - flag: "%{copts}" - iterate_over: "copts" + flag: "-undefined" + flag: "dynamic_lookup" } - expand_if_all_available: "copts" } } feature { @@ -4388,6 +4403,9 @@ toolchain { } } feature { + name: "link_cocoa" + } + feature { name: "apply_simulator_compiler_flags" flag_set { action: "objc-compile" @@ -4401,14 +4419,32 @@ toolchain { } } feature { - name: "cpp_linker_flags" + name: "unfiltered_cxx_flags" + } + feature { + name: "bitcode_embedded_markers" + } + feature { + name: "bitcode_embedded" + } + feature { + name: "copts" flag_set { - action: "c++-link-executable" - action: "c++-link-dynamic-library" + action: "assemble" + action: "preprocess-assemble" + action: "c-compile" + action: "c++-compile" + action: "c++-header-parsing" + action: "c++-header-preprocessing" + action: "c++-module-compile" + action: "c++-module-codegen" + action: "objc-compile" + action: "objc++-compile" flag_group { - flag: "-undefined" - flag: "dynamic_lookup" + flag: "%{copts}" + iterate_over: "copts" } + expand_if_all_available: "copts" } } feature { @@ -5990,23 +6026,14 @@ toolchain { provides: "profile" } feature { - name: "copts" + name: "cpp_linker_flags" flag_set { - action: "assemble" - action: "preprocess-assemble" - action: "c-compile" - action: "c++-compile" - action: "c++-header-parsing" - action: "c++-header-preprocessing" - action: "c++-module-compile" - action: "c++-module-codegen" - action: "objc-compile" - action: "objc++-compile" + action: "c++-link-executable" + action: "c++-link-dynamic-library" flag_group { - flag: "%{copts}" - iterate_over: "copts" + flag: "-undefined" + flag: "dynamic_lookup" } - expand_if_all_available: "copts" } } feature { @@ -6021,6 +6048,9 @@ toolchain { } } feature { + name: "link_cocoa" + } + feature { name: "apply_simulator_compiler_flags" flag_set { action: "objc-compile" @@ -6034,14 +6064,32 @@ toolchain { } } feature { - name: "cpp_linker_flags" + name: "unfiltered_cxx_flags" + } + feature { + name: "bitcode_embedded_markers" + } + feature { + name: "bitcode_embedded" + } + feature { + name: "copts" flag_set { - action: "c++-link-executable" - action: "c++-link-dynamic-library" + action: "assemble" + action: "preprocess-assemble" + action: "c-compile" + action: "c++-compile" + action: "c++-header-parsing" + action: "c++-header-preprocessing" + action: "c++-module-compile" + action: "c++-module-codegen" + action: "objc-compile" + action: "objc++-compile" flag_group { - flag: "-undefined" - flag: "dynamic_lookup" + flag: "%{copts}" + iterate_over: "copts" } + expand_if_all_available: "copts" } } feature { @@ -7622,26 +7670,6 @@ toolchain { provides: "profile" } feature { - name: "copts" - flag_set { - action: "assemble" - action: "preprocess-assemble" - action: "c-compile" - action: "c++-compile" - action: "c++-header-parsing" - action: "c++-header-preprocessing" - action: "c++-module-compile" - action: "c++-module-codegen" - action: "objc-compile" - action: "objc++-compile" - flag_group { - flag: "%{copts}" - iterate_over: "copts" - } - expand_if_all_available: "copts" - } - } - feature { name: "cpp_linker_flags" flag_set { action: "c++-link-executable" @@ -7678,6 +7706,9 @@ toolchain { } } feature { + name: "link_cocoa" + } + feature { name: "apply_simulator_compiler_flags" flag_set { action: "objc-compile" @@ -7691,44 +7722,70 @@ toolchain { } } feature { - name: "dbg_only_flag" + name: "unfiltered_cxx_flags" flag_set { + action: "c-compile" + action: "c++-compile" + action: "c++-module-compile" + action: "c++-header-parsing" + action: "assemble" + action: "preprocess-assemble" + flag_group { + flag: "-no-canonical-prefixes" + flag: "-pthread" + } + } + } + feature { + name: "bitcode_embedded_markers" + } + feature { + name: "bitcode_embedded" + } + feature { + name: "copts" + flag_set { + action: "assemble" + action: "preprocess-assemble" + action: "c-compile" + action: "c++-compile" + action: "c++-header-parsing" + action: "c++-header-preprocessing" + action: "c++-module-compile" + action: "c++-module-codegen" action: "objc-compile" + action: "objc++-compile" flag_group { - flag: "--DBG_ONLY_FLAG" + flag: "%{copts}" + iterate_over: "copts" } + expand_if_all_available: "copts" } } feature { - name: "fastbuild_only_flag" + name: "dbg_only_flag" flag_set { action: "objc-compile" flag_group { - flag: "--FASTBUILD_ONLY_FLAG" + flag: "--DBG_ONLY_FLAG" } } } feature { - name: "opt_only_flag" + name: "fastbuild_only_flag" flag_set { action: "objc-compile" flag_group { - flag: "--OPT_ONLY_FLAG" + flag: "--FASTBUILD_ONLY_FLAG" } } } feature { - name: "unfiltered_cxx_flags" + name: "opt_only_flag" flag_set { - action: "c-compile" - action: "c++-compile" - action: "c++-module-compile" - action: "c++-header-parsing" - action: "assemble" - action: "preprocess-assemble" + action: "objc-compile" flag_group { - flag: "-no-canonical-prefixes" - flag: "-pthread" + flag: "--OPT_ONLY_FLAG" } } } @@ -9289,23 +9346,14 @@ toolchain { provides: "profile" } feature { - name: "copts" + name: "cpp_linker_flags" flag_set { - action: "assemble" - action: "preprocess-assemble" - action: "c-compile" - action: "c++-compile" - action: "c++-header-parsing" - action: "c++-header-preprocessing" - action: "c++-module-compile" - action: "c++-module-codegen" - action: "objc-compile" - action: "objc++-compile" + action: "c++-link-executable" + action: "c++-link-dynamic-library" flag_group { - flag: "%{copts}" - iterate_over: "copts" + flag: "-undefined" + flag: "dynamic_lookup" } - expand_if_all_available: "copts" } } feature { @@ -9320,6 +9368,9 @@ toolchain { } } feature { + name: "link_cocoa" + } + feature { name: "apply_simulator_compiler_flags" flag_set { action: "objc-compile" @@ -9333,14 +9384,32 @@ toolchain { } } feature { - name: "cpp_linker_flags" + name: "unfiltered_cxx_flags" + } + feature { + name: "bitcode_embedded_markers" + } + feature { + name: "bitcode_embedded" + } + feature { + name: "copts" flag_set { - action: "c++-link-executable" - action: "c++-link-dynamic-library" + action: "assemble" + action: "preprocess-assemble" + action: "c-compile" + action: "c++-compile" + action: "c++-header-parsing" + action: "c++-header-preprocessing" + action: "c++-module-compile" + action: "c++-module-codegen" + action: "objc-compile" + action: "objc++-compile" flag_group { - flag: "-undefined" - flag: "dynamic_lookup" + flag: "%{copts}" + iterate_over: "copts" } + expand_if_all_available: "copts" } } feature { @@ -10920,23 +10989,14 @@ toolchain { provides: "profile" } feature { - name: "copts" + name: "cpp_linker_flags" flag_set { - action: "assemble" - action: "preprocess-assemble" - action: "c-compile" - action: "c++-compile" - action: "c++-header-parsing" - action: "c++-header-preprocessing" - action: "c++-module-compile" - action: "c++-module-codegen" - action: "objc-compile" - action: "objc++-compile" + action: "c++-link-executable" + action: "c++-link-dynamic-library" flag_group { - flag: "%{copts}" - iterate_over: "copts" + flag: "-undefined" + flag: "dynamic_lookup" } - expand_if_all_available: "copts" } } feature { @@ -10951,6 +11011,27 @@ toolchain { } } feature { + name: "link_cocoa" + } + feature { + name: "apply_simulator_compiler_flags" + } + feature { + name: "unfiltered_cxx_flags" + } + feature { + name: "bitcode_embedded_markers" + flag_set { + action: "objc-compile" + action: "objc++-compile" + action: "objc-executable" + action: "objc++-executable" + flag_group { + flag: "-fembed-bitcode-marker" + } + } + } + feature { name: "bitcode_embedded" flag_set { action: "objc-compile" @@ -10977,26 +11058,23 @@ toolchain { } } feature { - name: "bitcode_embedded_markers" + name: "copts" flag_set { + action: "assemble" + action: "preprocess-assemble" + action: "c-compile" + action: "c++-compile" + action: "c++-header-parsing" + action: "c++-header-preprocessing" + action: "c++-module-compile" + action: "c++-module-codegen" action: "objc-compile" action: "objc++-compile" - action: "objc-executable" - action: "objc++-executable" - flag_group { - flag: "-fembed-bitcode-marker" - } - } - } - feature { - name: "cpp_linker_flags" - flag_set { - action: "c++-link-executable" - action: "c++-link-dynamic-library" flag_group { - flag: "-undefined" - flag: "dynamic_lookup" + flag: "%{copts}" + iterate_over: "copts" } + expand_if_all_available: "copts" } } feature { @@ -12576,23 +12654,14 @@ toolchain { provides: "profile" } feature { - name: "copts" + name: "cpp_linker_flags" flag_set { - action: "assemble" - action: "preprocess-assemble" - action: "c-compile" - action: "c++-compile" - action: "c++-header-parsing" - action: "c++-header-preprocessing" - action: "c++-module-compile" - action: "c++-module-codegen" - action: "objc-compile" - action: "objc++-compile" + action: "c++-link-executable" + action: "c++-link-dynamic-library" flag_group { - flag: "%{copts}" - iterate_over: "copts" + flag: "-undefined" + flag: "dynamic_lookup" } - expand_if_all_available: "copts" } } feature { @@ -12607,6 +12676,27 @@ toolchain { } } feature { + name: "link_cocoa" + } + feature { + name: "apply_simulator_compiler_flags" + } + feature { + name: "unfiltered_cxx_flags" + } + feature { + name: "bitcode_embedded_markers" + flag_set { + action: "objc-compile" + action: "objc++-compile" + action: "objc-executable" + action: "objc++-executable" + flag_group { + flag: "-fembed-bitcode-marker" + } + } + } + feature { name: "bitcode_embedded" flag_set { action: "objc-compile" @@ -12633,26 +12723,23 @@ toolchain { } } feature { - name: "bitcode_embedded_markers" + name: "copts" flag_set { + action: "assemble" + action: "preprocess-assemble" + action: "c-compile" + action: "c++-compile" + action: "c++-header-parsing" + action: "c++-header-preprocessing" + action: "c++-module-compile" + action: "c++-module-codegen" action: "objc-compile" action: "objc++-compile" - action: "objc-executable" - action: "objc++-executable" flag_group { - flag: "-fembed-bitcode-marker" - } - } - } - feature { - name: "cpp_linker_flags" - flag_set { - action: "c++-link-executable" - action: "c++-link-dynamic-library" - flag_group { - flag: "-undefined" - flag: "dynamic_lookup" + flag: "%{copts}" + iterate_over: "copts" } + expand_if_all_available: "copts" } } feature { @@ -14231,26 +14318,6 @@ toolchain { provides: "profile" } feature { - name: "copts" - flag_set { - action: "assemble" - action: "preprocess-assemble" - action: "c-compile" - action: "c++-compile" - action: "c++-header-parsing" - action: "c++-header-preprocessing" - action: "c++-module-compile" - action: "c++-module-codegen" - action: "objc-compile" - action: "objc++-compile" - flag_group { - flag: "%{copts}" - iterate_over: "copts" - } - expand_if_all_available: "copts" - } - } - feature { name: "cpp_linker_flags" flag_set { action: "c++-link-executable" @@ -14287,6 +14354,39 @@ toolchain { } } feature { + name: "link_cocoa" + } + feature { + name: "apply_simulator_compiler_flags" + } + feature { + name: "unfiltered_cxx_flags" + flag_set { + action: "c-compile" + action: "c++-compile" + action: "c++-module-compile" + action: "c++-header-parsing" + action: "assemble" + action: "preprocess-assemble" + flag_group { + flag: "-no-canonical-prefixes" + flag: "-pthread" + } + } + } + feature { + name: "bitcode_embedded_markers" + flag_set { + action: "objc-compile" + action: "objc++-compile" + action: "objc-executable" + action: "objc++-executable" + flag_group { + flag: "-fembed-bitcode-marker" + } + } + } + feature { name: "bitcode_embedded" flag_set { action: "objc-compile" @@ -14313,15 +14413,23 @@ toolchain { } } feature { - name: "bitcode_embedded_markers" + name: "copts" flag_set { + action: "assemble" + action: "preprocess-assemble" + action: "c-compile" + action: "c++-compile" + action: "c++-header-parsing" + action: "c++-header-preprocessing" + action: "c++-module-compile" + action: "c++-module-codegen" action: "objc-compile" action: "objc++-compile" - action: "objc-executable" - action: "objc++-executable" flag_group { - flag: "-fembed-bitcode-marker" + flag: "%{copts}" + iterate_over: "copts" } + expand_if_all_available: "copts" } } feature { @@ -14351,21 +14459,6 @@ toolchain { } } } - feature { - name: "unfiltered_cxx_flags" - flag_set { - action: "c-compile" - action: "c++-compile" - action: "c++-module-compile" - action: "c++-header-parsing" - action: "assemble" - action: "preprocess-assemble" - flag_group { - flag: "-no-canonical-prefixes" - flag: "-pthread" - } - } - } action_config { config_name: "strip" action_name: "strip" @@ -15921,23 +16014,14 @@ toolchain { provides: "profile" } feature { - name: "copts" + name: "cpp_linker_flags" flag_set { - action: "assemble" - action: "preprocess-assemble" - action: "c-compile" - action: "c++-compile" - action: "c++-header-parsing" - action: "c++-header-preprocessing" - action: "c++-module-compile" - action: "c++-module-codegen" - action: "objc-compile" - action: "objc++-compile" + action: "c++-link-executable" + action: "c++-link-dynamic-library" flag_group { - flag: "%{copts}" - iterate_over: "copts" + flag: "-undefined" + flag: "dynamic_lookup" } - expand_if_all_available: "copts" } } feature { @@ -15952,6 +16036,27 @@ toolchain { } } feature { + name: "link_cocoa" + } + feature { + name: "apply_simulator_compiler_flags" + } + feature { + name: "unfiltered_cxx_flags" + } + feature { + name: "bitcode_embedded_markers" + flag_set { + action: "objc-compile" + action: "objc++-compile" + action: "objc-executable" + action: "objc++-executable" + flag_group { + flag: "-fembed-bitcode-marker" + } + } + } + feature { name: "bitcode_embedded" flag_set { action: "objc-compile" @@ -15978,26 +16083,23 @@ toolchain { } } feature { - name: "bitcode_embedded_markers" + name: "copts" flag_set { + action: "assemble" + action: "preprocess-assemble" + action: "c-compile" + action: "c++-compile" + action: "c++-header-parsing" + action: "c++-header-preprocessing" + action: "c++-module-compile" + action: "c++-module-codegen" action: "objc-compile" action: "objc++-compile" - action: "objc-executable" - action: "objc++-executable" flag_group { - flag: "-fembed-bitcode-marker" - } - } - } - feature { - name: "cpp_linker_flags" - flag_set { - action: "c++-link-executable" - action: "c++-link-dynamic-library" - flag_group { - flag: "-undefined" - flag: "dynamic_lookup" + flag: "%{copts}" + iterate_over: "copts" } + expand_if_all_available: "copts" } } feature { |