2
0
Fork 0
mirror of https://github.com/bazel-contrib/rules_foreign_cc synced 2024-11-28 08:43:26 +00:00
rules_foreign_cc/for_workspace/compilation_mode.bzl
irengrig 8dca26ac29
Pass the value of --compilation_mode dbg to the rule and to CMake (#96)
CMAKE_BUILD_TYPE=DEBUG (otherwise RELEASE)
Can be overriden by user passing CMAKE_BUILD_TYPE in cache_entries
2018-09-14 10:18:38 +02:00

10 lines
225 B
Python

def _compilation_mode(ctx):
return [config_common.FeatureFlagInfo(value = str(ctx.attr.is_debug))]
compilation_mode = rule(
attrs = {
"is_debug": attr.bool(),
},
implementation = _compilation_mode,
)