1# Copyright 2023 The Pigweed Authors 2# 3# Licensed under the Apache License, Version 2.0 (the "License"); you may not 4# use this file except in compliance with the License. You may obtain a copy of 5# the License at 6# 7# https://www.apache.org/licenses/LICENSE-2.0 8# 9# Unless required by applicable law or agreed to in writing, software 10# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12# License for the specific language governing permissions and limitations under 13# the License. 14 15# BUILD.bazel file for cmsis_device_xxx. 16 17# buildifier: disable=module-docstring 18# Should point to the corresponding cmsis_core library. Hidden behind a label 19# flag so that it can be overriden in projects that build for more than one 20# family of STM processors. 21label_flag( 22 name = "cmsis_core", 23 build_setting_default = "@cmsis_core", 24) 25 26cc_library( 27 name = "default_cmsis_init", 28 srcs = glob(["Source/Templates/system_*.c"]), 29 deps = [":cmsis_device"], 30) 31 32cc_library( 33 name = "cmsis_device", 34 hdrs = glob( 35 [ 36 "Include/*.h", 37 ], 38 ), 39 defines = [ 40 "__ARMCC_VERSION=0", 41 ], 42 includes = ["Include"], 43 deps = [ 44 ":cmsis_core", 45 ], 46) 47