8000 [NXP][cmake][common] Provide a way to customize the toolchain in the NXP freertos cmake abstraction by dinabenamar · Pull Request #38904 · project-chip/connectedhomeip · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

[NXP][cmake][common] Provide a way to customize the toolchain in the NXP freertos cmake abstraction #38904

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 14, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions config/nxp/chip-cmake-freertos/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,10 @@ endif()
# Enable map file generation by default
matter_add_gn_arg_bool("chip_generate_link_map_file" true)

matter_add_gn_arg_string("nxp_ar" ${CMAKE_AR})
matter_add_gn_arg_string("nxp_cc" ${CMAKE_C_COMPILER})
matter_add_gn_arg_string("nxp_cxx" ${CMAKE_CXX_COMPILER})

matter_common_gn_args(
DEBUG CONFIG_DEBUG
LIB_SHELL CONFIG_CHIP_LIB_SHELL
Expand Down
3 changes: 3 additions & 0 deletions config/nxp/chip-gn-freertos/args.gni
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,6 @@ chip_ble_project_config_include = ""

# mbedtls is built as part of the NXP SDK build process
mbedtls_target = "${nxp_sdk_build_root}:nxp_mbedtls"

custom_toolchain =
"${chip_root}/config/nxp/chip-gn-freertos/toolchain:nxpFreeRTOS"
34 changes: 34 additions & 0 deletions config/nxp/chip-gn-freertos/toolchain/BUILD.gn
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Copyright (c) 2025 Project CHIP Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

import("//build_overrides/build.gni")

import("${build_root}/toolchain/arm_gcc/arm_toolchain.gni")

declare_args() {
nxp_ar = ""
nxp_cc = ""
nxp_cxx = ""
}

gcc_toolchain("nxpFreeRTOS") {
ar = nxp_ar
cc = nxp_cc
cxx = nxp_cxx

toolchain_args = {
current_os = "freertos"
is_clang = false
}
}
Loading
0