Skip to content

Commit bf06897

Browse files
committed
CMake: unit-tests: Move mbed-headers-hal to the hal directory
Move the header-only mbed-headers-hal library the unit test stubs depend on into the hal component directory. This makes the events stubs more self-contained and improves the composition of the library.
1 parent 84bb4cc commit bf06897

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

UNITTESTS/stubs/CMakeLists.txt

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ add_library(mbed-headers-base INTERFACE)
77
add_library(mbed-headers-platform INTERFACE)
88
add_library(mbed-headers-connectivity INTERFACE)
99
add_library(mbed-headers-storage INTERFACE)
10-
add_library(mbed-headers-hal INTERFACE)
1110
add_library(mbed-headers-events INTERFACE)
1211

1312
target_link_libraries(mbed-headers
@@ -89,12 +88,6 @@ target_include_directories(mbed-headers-events
8988
${mbed-os_SOURCE_DIR}/events/include/events/internal
9089
)
9190

92-
target_include_directories(mbed-headers-hal
93-
INTERFACE
94-
${mbed-os_SOURCE_DIR}/hal
95-
${mbed-os_SOURCE_DIR}/hal/include
96-
)
97-
9891
target_include_directories(mbed-headers
9992
INTERFACE
10093
${mbed-os_SOURCE_DIR}/features

hal/tests/UNITTESTS/doubles/CMakeLists.txt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11
# Copyright (c) 2021 ARM Limited. All rights reserved.
22
# SPDX-License-Identifier: Apache-2.0
33

4+
add_library(mbed-headers-hal INTERFACE)
5+
6+
target_include_directories(mbed-headers-hal
7+
INTERFACE
8+
${mbed-os_SOURCE_DIR}/hal
9+
${mbed-os_SOURCE_DIR}/hal/include
10+
)
11+
412
add_library(mbed-stubs-hal)
513

614
target_compile_definitions(mbed-stubs-hal

0 commit comments

Comments
 (0)