diff options
Diffstat (limited to 'pw_cpu_exception_cortex_m/BUILD.bazel')
-rw-r--r-- | pw_cpu_exception_cortex_m/BUILD.bazel | 44 |
1 files changed, 32 insertions, 12 deletions
diff --git a/pw_cpu_exception_cortex_m/BUILD.bazel b/pw_cpu_exception_cortex_m/BUILD.bazel index 102d5ebf8..3880193f6 100644 --- a/pw_cpu_exception_cortex_m/BUILD.bazel +++ b/pw_cpu_exception_cortex_m/BUILD.bazel @@ -12,18 +12,28 @@ # License for the specific language governing permissions and limitations under # the License. +load("@com_google_protobuf//:protobuf.bzl", "py_proto_library") load( "//pw_build:pigweed.bzl", "pw_cc_library", "pw_cc_test", ) -load("@com_google_protobuf//:protobuf.bzl", "py_proto_library") -load("//pw_protobuf_compiler:proto.bzl", "pw_proto_library") +load("//pw_protobuf_compiler:pw_proto_library.bzl", "pw_proto_library") package(default_visibility = ["//visibility:public"]) licenses(["notice"]) +constraint_value( + name = "entry_backend", + constraint_setting = "//pw_cpu_exception:entry_constraint_setting", +) + +constraint_value( + name = "support_backend", + constraint_setting = "//pw_cpu_exception:support_constraint_setting", +) + pw_cc_library( name = "config", hdrs = ["pw_cpu_exception_cortex_m_private/config.h"], @@ -68,6 +78,7 @@ pw_cc_library( ":cortex_m_constants", ":cpu_state", ":util", + "//pw_cpu_exception:support_facade", "//pw_log", "//pw_preprocessor", "//pw_preprocessor:cortex_m", @@ -110,27 +121,35 @@ pw_proto_library( pw_cc_library( name = "cpu_exception", - srcs = ["entry.cc"], hdrs = [ - "public/pw_cpu_exception_cortex_m/cpu_state.h", "public_overrides/pw_cpu_exception_backend/state.h", ], - includes = ["public"], + includes = [ + "public_overrides", + ], deps = [ - ":config", ":cpu_state", - ":cortex_m_constants", - ":proto_dump", - ":support", - ":util", - # TODO(b/242183021): Need to add support for facades/backends to Bazel. - # "//pw_cpu_exception", + "//pw_cpu_exception:entry_facade", "//pw_preprocessor", "//pw_preprocessor:cortex_m", ], ) pw_cc_library( + name = "cpu_exception_impl", + srcs = ["entry.cc"], + deps = [ + ":config", + ":cortex_m_constants", + ":cpu_state", + ":util", + # Depend on the full backends in the impl target. + "//pw_cpu_exception:entry", + "//pw_cpu_exception:handler", + ], +) + +pw_cc_library( name = "snapshot", srcs = ["snapshot.cc"], hdrs = ["public/pw_cpu_exception_cortex_m/snapshot.h"], @@ -165,6 +184,7 @@ pw_cc_test( ":config", ":cpu_exception", ":cpu_state", + "//pw_cpu_exception:handler", ], ) |