Skip to content

Commit

Permalink
Restyled by gn
Browse files Browse the repository at this point in the history
  • Loading branch information
restyled-commits authored and marius-alex-tache committed Sep 16, 2024
1 parent c9e7034 commit cf9bed9
Show file tree
Hide file tree
Showing 7 changed files with 47 additions and 33 deletions.
10 changes: 6 additions & 4 deletions examples/contact-sensor-app/nxp/k32w1/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ assert(target_os == "freertos")

example_platform_dir = "${chip_root}/examples/platform/nxp/${nxp_platform}"
common_example_dir = "${chip_root}/examples/platform/nxp/common"
support_common_platform_dir = "${nxp_sdk_matter_support_root}/examples/platform/common"
support_common_platform_dir =
"${nxp_sdk_matter_support_root}/examples/platform/common"

mcxw71_k32w1_sdk("sdk") {
defines = []
Expand Down Expand Up @@ -73,7 +74,7 @@ mcxw71_k32w1_sdk("sdk") {
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/board_extflash.c",
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/board_lp.c",
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/hardware_init.c",
"${support_common_platform_dir}/ble/ble_function_mux.c"
"${support_common_platform_dir}/ble/ble_function_mux.c",
]

if (is_debug) {
Expand Down Expand Up @@ -155,7 +156,8 @@ mcxw71_k32w1_executable("contact_sensor_app") {
}

if (chip_with_factory_data == 1) {
include_dirs += [ "${chip_root}/src/platform/nxp/common/factory_data/legacy" ]
include_dirs +=
[ "${chip_root}/src/platform/nxp/common/factory_data/legacy" ]
deps += [ "${chip_root}/src/platform/nxp:nxp_factory_data" ]
}

Expand All @@ -169,7 +171,7 @@ mcxw71_k32w1_executable("contact_sensor_app") {

include_dirs += [
"${common_example_dir}/ota_requestor/include",
"${chip_root}/src/platform/nxp/common/ota"
"${chip_root}/src/platform/nxp/common/ota",
]
sources += [ "${common_example_dir}/ota_requestor/source/OTARequestorInitiatorMultiImage.cpp" ]
deps += [ "${chip_root}/src/platform/nxp:nxp_ota" ]
Expand Down
15 changes: 9 additions & 6 deletions examples/contact-sensor-app/nxp/mcxw71/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ assert(target_os == "freertos")

example_platform_dir = "${chip_root}/examples/platform/nxp/${nxp_platform}"
common_example_dir = "${chip_root}/examples/platform/nxp/common"
support_common_platform_dir = "${nxp_sdk_matter_support_root}/examples/platform/common"
support_common_platform_dir =
"${nxp_sdk_matter_support_root}/examples/platform/common"

mcxw71_k32w1_sdk("sdk") {
defines = []
Expand Down Expand Up @@ -72,7 +73,7 @@ mcxw71_k32w1_sdk("sdk") {
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/board_extflash.c",
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/board_lp.c",
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/hardware_init.c",
"${support_common_platform_dir}/ble/ble_function_mux.c"
"${support_common_platform_dir}/ble/ble_function_mux.c",
]

if (is_debug) {
Expand Down Expand Up @@ -108,7 +109,7 @@ mcxw71_k32w1_executable("contact_sensor_app") {
"CONFIG_NETWORK_LAYER_BLE=1",
"CONFIG_THREAD_DEVICE_TYPE=kThreadDeviceType_SleepyEndDevice",
"CONFIG_OPERATIONAL_KEYSTORE=1",
"EXTERNAL_FACTORY_DATA_PROVIDER_HEADER=\"platform/nxp/common/factory_data/legacy/FactoryDataProvider.h\""
"EXTERNAL_FACTORY_DATA_PROVIDER_HEADER=\"platform/nxp/common/factory_data/legacy/FactoryDataProvider.h\"",
]

if (chip_with_diag_logs_demo) {
Expand Down Expand Up @@ -146,28 +147,30 @@ mcxw71_k32w1_executable("contact_sensor_app") {
"${common_example_dir}/device_callbacks/source/CommonDeviceCallbacks.cpp",
"${common_example_dir}/device_manager/source/CHIPDeviceManager.cpp",
"${common_example_dir}/operational_keystore/source/OperationalKeystoreS200.cpp",
"${example_platform_dir}/factory_data/source/AppFactoryDataExample.cpp"
"${example_platform_dir}/factory_data/source/AppFactoryDataExample.cpp",
]

if (chip_with_low_power == 1) {
sources += [ "${common_example_dir}/low_power/source/LowPower.cpp" ]
}

if (chip_with_factory_data == 1) {
include_dirs += [ "${chip_root}/src/platform/nxp/common/factory_data/legacy" ]
include_dirs +=
[ "${chip_root}/src/platform/nxp/common/factory_data/legacy" ]
deps += [ "${chip_root}/src/platform/nxp:nxp_factory_data" ]
}

if (chip_enable_ota_requestor) {
defines += [
"CONFIG_CHIP_OTA_IMAGE_PROCESSOR_HEADER=\"platform/nxp/common/ota/OTAImageProcessorImpl.h\"",

# The status LED and the external flash CS pin are wired together. The OTA image writing may fail if used together.
"LED_MANAGER_ENABLE_STATUS_LED=0",
]

include_dirs += [
"${common_example_dir}/ota_requestor/include",
"${chip_root}/src/platform/nxp/common/ota"
"${chip_root}/src/platform/nxp/common/ota",
]
sources += [ "${common_example_dir}/ota_requestor/source/OTARequestorInitiatorMultiImage.cpp" ]
deps += [ "${chip_root}/src/platform/nxp:nxp_ota" ]
Expand Down
12 changes: 6 additions & 6 deletions examples/lighting-app/nxp/k32w1/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@ assert(target_os == "freertos")

example_platform_dir = "${chip_root}/examples/platform/nxp/${nxp_platform}"
common_example_dir = "${chip_root}/examples/platform/nxp/common"
support_common_platform_dir = "${nxp_sdk_matter_support_root}/examples/platform/common"
support_common_platform_dir =
"${nxp_sdk_matter_support_root}/examples/platform/common"

mcxw71_k32w1_sdk("sdk") {
defines = []
Expand Down Expand Up @@ -78,7 +79,7 @@ mcxw71_k32w1_sdk("sdk") {
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/board_extflash.c",
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/board_lp.c",
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/hardware_init.c",
"${support_common_platform_dir}/ble/ble_function_mux.c"
"${support_common_platform_dir}/ble/ble_function_mux.c",
]

if (is_debug) {
Expand Down Expand Up @@ -165,9 +166,7 @@ mcxw71_k32w1_executable("light_app") {
"LED_MANAGER_ENABLE_STATUS_LED=0",
]

include_dirs += [
"${common_example_dir}/ota_requestor/include",
]
include_dirs += [ "${common_example_dir}/ota_requestor/include" ]
sources += [ "${common_example_dir}/ota_requestor/source/OTARequestorInitiatorMultiImage.cpp" ]
deps += [ "${chip_root}/src/platform/nxp:nxp_ota" ]
}
Expand All @@ -193,7 +192,8 @@ mcxw71_k32w1_executable("light_app") {
}

if (chip_with_factory_data == 1) {
include_dirs += [ "${chip_root}/src/platform/nxp/common/factory_data/legacy" ]
include_dirs +=
[ "${chip_root}/src/platform/nxp/common/factory_data/legacy" ]
deps += [ "${chip_root}/src/platform/nxp:nxp_factory_data" ]
}

Expand Down
13 changes: 8 additions & 5 deletions examples/lighting-app/nxp/mcxw71/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@ assert(target_os == "freertos")

example_platform_dir = "${chip_root}/examples/platform/nxp/${nxp_platform}"
common_example_dir = "${chip_root}/examples/platform/nxp/common"
support_common_platform_dir = "${nxp_sdk_matter_support_root}/examples/platform/common"
support_common_platform_dir =
"${nxp_sdk_matter_support_root}/examples/platform/common"

mcxw71_k32w1_sdk("sdk") {
defines = []
Expand Down Expand Up @@ -78,7 +79,7 @@ mcxw71_k32w1_sdk("sdk") {
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/board_extflash.c",
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/board_lp.c",
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/hardware_init.c",
"${support_common_platform_dir}/ble/ble_function_mux.c"
"${support_common_platform_dir}/ble/ble_function_mux.c",
]

if (is_debug) {
Expand Down Expand Up @@ -130,7 +131,7 @@ mcxw71_k32w1_executable("light_app") {
"CONFIG_OPERATIONAL_KEYSTORE=1",
"CONFIG_ENABLE_FEEDBACK=1",
"APP_QUEUE_TICKS_TO_WAIT=pdMS_TO_TICKS(10)",
"EXTERNAL_FACTORY_DATA_PROVIDER_HEADER=\"platform/nxp/common/factory_data/legacy/FactoryDataProvider.h\""
"EXTERNAL_FACTORY_DATA_PROVIDER_HEADER=\"platform/nxp/common/factory_data/legacy/FactoryDataProvider.h\"",
]

# App common files
Expand Down Expand Up @@ -160,13 +161,14 @@ mcxw71_k32w1_executable("light_app") {
if (chip_enable_ota_requestor) {
defines += [
"CONFIG_CHIP_OTA_IMAGE_PROCESSOR_HEADER=\"platform/nxp/common/ota/OTAImageProcessorImpl.h\"",

# The status LED and the external flash CS pin are wired together. The OTA image writing may fail if used together.
"LED_MANAGER_ENABLE_STATUS_LED=0",
]

include_dirs += [
"${common_example_dir}/ota_requestor/include",
"${chip_root}/src/platform/nxp/common/ota"
"${chip_root}/src/platform/nxp/common/ota",
]
sources += [ "${common_example_dir}/ota_requestor/source/OTARequestorInitiatorMultiImage.cpp" ]
deps += [ "${chip_root}/src/platform/nxp:nxp_ota" ]
Expand All @@ -193,7 +195,8 @@ mcxw71_k32w1_executable("light_app") {
}

if (chip_with_factory_data == 1) {
include_dirs += [ "${chip_root}/src/platform/nxp/common/factory_data/legacy" ]
include_dirs +=
[ "${chip_root}/src/platform/nxp/common/factory_data/legacy" ]
deps += [ "${chip_root}/src/platform/nxp:nxp_factory_data" ]
}

Expand Down
11 changes: 7 additions & 4 deletions examples/lock-app/nxp/k32w1/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ assert(target_os == "freertos")

example_platform_dir = "${chip_root}/examples/platform/nxp/${nxp_platform}"
common_example_dir = "${chip_root}/examples/platform/nxp/common"
support_common_platform_dir = "${nxp_sdk_matter_support_root}/examples/platform/common"
support_common_platform_dir =
"${nxp_sdk_matter_support_root}/examples/platform/common"

mcxw71_k32w1_sdk("sdk") {
defines = []
Expand Down Expand Up @@ -71,7 +72,7 @@ mcxw71_k32w1_sdk("sdk") {
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/board_extflash.c",
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/board_lp.c",
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/hardware_init.c",
"${support_common_platform_dir}/ble/ble_function_mux.c"
"${support_common_platform_dir}/ble/ble_function_mux.c",
]

if (is_debug) {
Expand Down Expand Up @@ -148,8 +149,8 @@ mcxw71_k32w1_executable("lock_app") {
#"${common_example_dir}/clusters/source/ZclCallbacks.cpp",
"${common_example_dir}/device_callbacks/source/CommonDeviceCallbacks.cpp",
"${common_example_dir}/device_manager/source/CHIPDeviceManager.cpp",
"${common_example_dir}/operational_keystore/source/OperationalKeystoreS200.cpp",
"${common_example_dir}/icd/source/ICDUtil.cpp",
"${common_example_dir}/operational_keystore/source/OperationalKeystoreS200.cpp",
"${example_platform_dir}/factory_data/source/AppFactoryDataExample.cpp",
]

Expand All @@ -158,7 +159,8 @@ mcxw71_k32w1_executable("lock_app") {
}

if (chip_with_factory_data == 1) {
include_dirs += [ "${chip_root}/src/platform/nxp/common/factory_data/legacy" ]
include_dirs +=
[ "${chip_root}/src/platform/nxp/common/factory_data/legacy" ]
deps += [ "${chip_root}/src/platform/nxp:nxp_factory_data" ]
}

Expand All @@ -177,6 +179,7 @@ mcxw71_k32w1_executable("lock_app") {
if (chip_enable_ota_requestor) {
defines += [
"CONFIG_CHIP_OTA_IMAGE_PROCESSOR_HEADER=\"platform/nxp/common/ota/OTAImageProcessorImpl.h\"",

# The status LED and the external flash CS pin are wired together. The OTA image writing may fail if used together.
"LED_MANAGER_ENABLE_STATUS_LED=0",
]
Expand Down
11 changes: 7 additions & 4 deletions examples/lock-app/nxp/mcxw71/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ assert(target_os == "freertos")

example_platform_dir = "${chip_root}/examples/platform/nxp/${nxp_platform}"
common_example_dir = "${chip_root}/examples/platform/nxp/common"
support_common_platform_dir = "${nxp_sdk_matter_support_root}/examples/platform/common"
support_common_platform_dir =
"${nxp_sdk_matter_support_root}/examples/platform/common"

mcxw71_k32w1_sdk("sdk") {
defines = []
Expand Down Expand Up @@ -71,7 +72,7 @@ mcxw71_k32w1_sdk("sdk") {
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/board_extflash.c",
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/board_lp.c",
"${nxp_sdk_root}/middleware/wireless/framework/boards/kw45_k32w1/hardware_init.c",
"${support_common_platform_dir}/ble/ble_function_mux.c"
"${support_common_platform_dir}/ble/ble_function_mux.c",
]

if (is_debug) {
Expand Down Expand Up @@ -148,8 +149,8 @@ mcxw71_k32w1_executable("lock_app") {
#"${common_example_dir}/clusters/source/ZclCallbacks.cpp",
"${common_example_dir}/device_callbacks/source/CommonDeviceCallbacks.cpp",
"${common_example_dir}/device_manager/source/CHIPDeviceManager.cpp",
"${common_example_dir}/operational_keystore/source/OperationalKeystoreS200.cpp",
"${common_example_dir}/icd/source/ICDUtil.cpp",
"${common_example_dir}/operational_keystore/source/OperationalKeystoreS200.cpp",
"${example_platform_dir}/factory_data/source/AppFactoryDataExample.cpp",
]

Expand All @@ -158,7 +159,8 @@ mcxw71_k32w1_executable("lock_app") {
}

if (chip_with_factory_data == 1) {
include_dirs += [ "${chip_root}/src/platform/nxp/common/factory_data/legacy" ]
include_dirs +=
[ "${chip_root}/src/platform/nxp/common/factory_data/legacy" ]
deps += [ "${chip_root}/src/platform/nxp:nxp_factory_data" ]
}

Expand All @@ -177,6 +179,7 @@ mcxw71_k32w1_executable("lock_app") {
if (chip_enable_ota_requestor) {
defines += [
"CONFIG_CHIP_OTA_IMAGE_PROCESSOR_HEADER=\"platform/nxp/common/ota/OTAImageProcessorImpl.h\"",

# The status LED and the external flash CS pin are wired together. The OTA image writing may fail if used together.
"LED_MANAGER_ENABLE_STATUS_LED=0",
]
Expand Down
8 changes: 4 additions & 4 deletions src/platform/nxp/mcxw71_k32w1/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ assert(chip_with_low_power == 0 ||
source_set("nxp_factory_data") {
sources = [
"../common/factory_data/legacy/FactoryDataDriver.cpp",
"../common/factory_data/legacy/FactoryDataProvider.cpp",
"../common/factory_data/legacy/FactoryDataDriverImpl.cpp",
"../common/factory_data/legacy/FactoryDataProvider.cpp",
"../common/factory_data/legacy/FactoryDataProviderImpl.cpp",
]

Expand All @@ -55,13 +55,13 @@ source_set("nxp_ota") {
public = [ "../common/ota/OTAImageProcessorImpl.h" ]

sources = [
"../common/ota/OTAFirmwareProcessor.cpp",
"../common/ota/OTAFirmwareProcessor.h",
"../common/ota/OTAHooks.cpp",
"../common/ota/OTAImageProcessorImpl.cpp",
"../common/ota/OTAImageProcessorImpl.h",
"../common/ota/OTATlvProcessor.cpp",
"../common/ota/OTATlvProcessor.h",
"../common/ota/OTAFirmwareProcessor.cpp",
"../common/ota/OTAFirmwareProcessor.h",
"../common/ota/OTAHooks.cpp",
]

if (chip_with_factory_data == 1 &&
Expand Down

0 comments on commit cf9bed9

Please sign in to comment.