Skip to content

Commit 149c5b1

Browse files
authored
Merge pull request #15195 from ATmobica/cypress_cm0p_sleep_disable
Add option to disable CM0P_SLEEP component for Cypress targets
2 parents 7a6262c + 6a5cc40 commit 149c5b1

File tree

8 files changed

+59
-15
lines changed

8 files changed

+59
-15
lines changed

targets/TARGET_Cypress/TARGET_PSOC6/CMakeLists.txt

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -46,14 +46,16 @@ target_sources(mbed-cm0p-secure
4646
psoc6cm0p/COMPONENT_CM0P_SECURE/psoc6_03_cm0p_secure.c
4747
)
4848

49-
add_library(mbed-cm0p-sleep INTERFACE)
50-
target_sources(mbed-cm0p-sleep
51-
INTERFACE
52-
psoc6cm0p/COMPONENT_CM0P_SLEEP/psoc6_01_cm0p_sleep.c
53-
psoc6cm0p/COMPONENT_CM0P_SLEEP/psoc6_02_cm0p_sleep.c
54-
psoc6cm0p/COMPONENT_CM0P_SLEEP/psoc6_03_cm0p_sleep.c
55-
psoc6cm0p/COMPONENT_CM0P_SLEEP/psoc6_04_cm0p_sleep.c
56-
)
49+
if("CM0P_SLEEP" IN_LIST MBED_TARGET_LABELS)
50+
add_library(mbed-cm0p-sleep INTERFACE)
51+
target_sources(mbed-cm0p-sleep
52+
INTERFACE
53+
psoc6cm0p/COMPONENT_CM0P_SLEEP/psoc6_01_cm0p_sleep.c
54+
psoc6cm0p/COMPONENT_CM0P_SLEEP/psoc6_02_cm0p_sleep.c
55+
psoc6cm0p/COMPONENT_CM0P_SLEEP/psoc6_03_cm0p_sleep.c
56+
psoc6cm0p/COMPONENT_CM0P_SLEEP/psoc6_04_cm0p_sleep.c
57+
)
58+
endif()
5759

5860
add_library(mbed-udb-sdio-p12 INTERFACE)
5961
target_include_directories(mbed-udb-sdio-p12

targets/TARGET_Cypress/TARGET_PSOC6/TARGET_CY8CKIT_062S2_43012/CMakeLists.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,16 @@ target_link_libraries(mbed-cy8ckit-062s2-43012
6363
mbed-cat1a
6464
mbed-cy8ckit-062s2-43012-cm4
6565
mbed-cy8ckit-062s2-43012-bsp-design-modus
66-
mbed-cm0p-sleep
6766
mbed-psoc6
6867
)
6968

69+
if("CM0P_SLEEP" IN_LIST MBED_TARGET_LABELS)
70+
target_link_libraries(mbed-cy8ckit-062s2-43012
71+
INTERFACE
72+
mbed-cm0p-sleep
73+
)
74+
endif()
75+
7076
if("WHD" IN_LIST MBED_TARGET_LABELS)
7177
target_link_libraries(mbed-cy8ckit-062s2-43012
7278
INTERFACE

targets/TARGET_Cypress/TARGET_PSOC6/TARGET_CY8CKIT_062_BLE/CMakeLists.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,16 @@ target_link_libraries(mbed-cy8ckit-062-ble
6363
mbed-cat1a
6464
mbed-cy8ckit-062-ble-cm4
6565
mbed-cy8ckit-062-ble-bsp-design-modus
66-
mbed-cm0p-sleep
6766
mbed-psoc6
6867
)
6968

69+
if("CM0P_SLEEP" IN_LIST MBED_TARGET_LABELS)
70+
target_link_libraries(mbed-cy8ckit-062-ble
71+
INTERFACE
72+
mbed-cm0p-sleep
73+
)
74+
endif()
75+
7076
target_compile_definitions(mbed-cy8ckit-062-ble
7177
INTERFACE
7278
"CY8C6347BZI_BLD53"

targets/TARGET_Cypress/TARGET_PSOC6/TARGET_CY8CKIT_062_WIFI_BT/CMakeLists.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,11 +63,17 @@ target_link_libraries(mbed-cy8ckit-062-wifi-bt
6363
mbed-cat1a
6464
mbed-cy8ckit-062-wifi-bt-cm4
6565
mbed-cy8ckit-062-wifi-bt-bsp-design-modus
66-
mbed-cm0p-sleep
6766
mbed-psoc6
6867
mbed-udb-sdio-p12
6968
)
7069

70+
if("CM0P_SLEEP" IN_LIST MBED_TARGET_LABELS)
71+
target_link_libraries(mbed-cy8ckit-062-wifi-bt
72+
INTERFACE
73+
mbed-cm0p-sleep
74+
)
75+
endif()
76+
7177
if("WHD" IN_LIST MBED_TARGET_LABELS)
7278
target_link_libraries(mbed-cy8ckit-062-wifi-bt
7379
INTERFACE

targets/TARGET_Cypress/TARGET_PSOC6/TARGET_CY8CPROTO_062S3_4343W/CMakeLists.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,11 +64,17 @@ target_link_libraries(mbed-cy8cproto-062s3-4343w
6464
mbed-cat1a
6565
mbed-cy8cproto-062s3-4343w-cm4
6666
mbed-cy8cproto-062s3-4343w-bsp-design-modus
67-
mbed-cm0p-sleep
6867
mbed-psoc6
6968
mbed-cy-external-wifi-fw
7069
)
7170

71+
if("CM0P_SLEEP" IN_LIST MBED_TARGET_LABELS)
72+
target_link_libraries(mbed-cy8cproto-062s3-4343w
73+
INTERFACE
74+
mbed-cm0p-sleep
75+
)
76+
endif()
77+
7278
if("WHD" IN_LIST MBED_TARGET_LABELS)
7379
target_link_libraries(mbed-cy8cproto-062s3-4343w
7480
INTERFACE

targets/TARGET_Cypress/TARGET_PSOC6/TARGET_CY8CPROTO_062_4343W/CMakeLists.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,10 +64,16 @@ target_link_libraries(mbed-cy8cproto-062-4343w
6464
mbed-cat1a
6565
mbed-cy8cproto-062-4343w-cm4
6666
mbed-cy8cproto-062-4343w-bsp-design-modus
67-
mbed-cm0p-sleep
6867
mbed-psoc6
6968
)
7069

70+
if("CM0P_SLEEP" IN_LIST MBED_TARGET_LABELS)
71+
target_link_libraries(mbed-cy8cproto-062-4343w
72+
INTERFACE
73+
mbed-cm0p-sleep
74+
)
75+
endif()
76+
7177
if("WHD" IN_LIST MBED_TARGET_LABELS)
7278
target_link_libraries(mbed-cy8cproto-062-4343w
7379
INTERFACE

targets/TARGET_Cypress/TARGET_PSOC6/TARGET_CYW9P62S1_43012EVB_01/CMakeLists.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,17 @@ target_link_libraries(mbed-cyw9p62s1-43012evb-01
6565
mbed-cat1a
6666
mbed-cyw9p62s1-43012evb-01-cm4
6767
mbed-cyw9p62s1-43012evb-01-bsp-design-modus
68-
mbed-cm0p-sleep
6968
mbed-psoc6
7069
mbed-udb-sdio-p12
7170
)
7271

72+
if("CM0P_SLEEP" IN_LIST MBED_TARGET_LABELS)
73+
target_link_libraries(mbed-cyw9p62s1-43012evb-01
74+
INTERFACE
75+
mbed-cm0p-sleep
76+
)
77+
endif()
78+
7379
if("WHD" IN_LIST MBED_TARGET_LABELS)
7480
target_link_libraries(mbed-cyw9p62s1-43012evb-01
7581
INTERFACE

targets/TARGET_Cypress/TARGET_PSOC6/TARGET_CYW9P62S1_43438EVB_01/CMakeLists.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,11 +64,17 @@ target_link_libraries(mbed-cyw9p62s1-43438evb-01
6464
mbed-cat1a
6565
mbed-cyw9p62s1-43438evb-01-cm4
6666
mbed-cyw9p62s1-43438evb-01-bsp-design-modus
67-
mbed-cm0p-sleep
6867
mbed-psoc6
6968
mbed-udb-sdio-p2
7069
)
7170

71+
if("CM0P_SLEEP" IN_LIST MBED_TARGET_LABELS)
72+
target_link_libraries(mbed-cyw9p62s1-43438evb-01
73+
INTERFACE
74+
mbed-cm0p-sleep
75+
)
76+
endif()
77+
7278
if("WHD" IN_LIST MBED_TARGET_LABELS)
7379
target_link_libraries(mbed-cyw9p62s1-43438evb-01
7480
INTERFACE

0 commit comments

Comments
 (0)