Skip to content

Commit

Permalink
Switch --incompatible_disable_genrule_cc_toolchain_dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
guibou committed Jun 26, 2019
1 parent dd35364 commit d50d5a9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
2 changes: 0 additions & 2 deletions .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ test:windows --experimental_enable_runfiles

# WIP: bazel 0.27 fixs
build\
--incompatible_disable_genrule_cc_toolchain_dependency=false\
--incompatible_no_transitive_loads=false\
--incompatible_disable_deprecated_attr_params=false\
--incompatible_new_actions_api=false\
Expand All @@ -30,7 +29,6 @@ build\
--incompatible_depset_union=false\
--incompatible_use_python_toolchains=false
test\
--incompatible_disable_genrule_cc_toolchain_dependency=false\
--incompatible_no_transitive_loads=false\
--incompatible_disable_deprecated_attr_params=false\
--incompatible_new_actions_api=false\
Expand Down
7 changes: 6 additions & 1 deletion hazel/third_party/cabal2bazel/bzl/cabal_package.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ load(":bzl/cabal_paths.bzl", "cabal_paths")
load(":bzl/happy.bzl", "genhappy")
load("//templates:templates.bzl", "templates")
load("//tools:mangling.bzl", "hazel_cbits", "hazel_library")
load("@bazel_tools//tools/cpp:cc_flags_supplier.bzl", "cc_flags_supplier")

_conditions_default = "//conditions:default"

Expand Down Expand Up @@ -78,6 +79,7 @@ def _configure(desc):
for f in desc.extraTmpFiles
if f.split("/")[-1] not in _header_blacklist
]
cc_flags_supplier(name = "cc_flags")
native.genrule(
name = "run-configure",
cmd = "\n".join([
Expand All @@ -94,7 +96,10 @@ def _configure(desc):
for out in outputs
]),
tools = ["configure"],
toolchains = ["@bazel_tools//tools/cpp:current_cc_toolchain"],
toolchains = [
":cc_flags",
"@bazel_tools//tools/cpp:current_cc_toolchain",
],
srcs = native.glob(["**"], exclude = outputs),
outs = outputs,
)
Expand Down

0 comments on commit d50d5a9

Please sign in to comment.