Skip to content

Commit

Permalink
Add different constraints than the default for esp32 (#12904)
Browse files Browse the repository at this point in the history
* Add different constraints than the default for esp32

* Also fix amebad permissions in dockerfile

* Force constraints on all platform configs, so that order of building things does not interfere with others

* Update args to match relative paths for each platform

* Update args.gni for standaline linux examples

* Restyle fixes

* Ensure chip_root is available in args.gni for standalone builds

* Use chip_root based path for ios as well

* Another fix for mbed building
  • Loading branch information
andy31415 authored and pull[bot] committed Feb 16, 2024
1 parent 55465ec commit 1503906
Show file tree
Hide file tree
Showing 10 changed files with 30 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -66,3 +66,6 @@ RUN chown -R $USERNAME:$USERNAME /opt/ubuntu-21.04-aarch64-sysroot/usr/

# allow licenses to be accepted
RUN chown -R $USERNAME:$USERNAME /opt/android/sdk

# AmebaD requires access to change build_info.h
RUN chown -R $USERNAME:$USERNAME /opt/ameba/ambd_sdk_with_chip_non_NDA/
3 changes: 3 additions & 0 deletions config/ameba/args.gni
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,6 @@ chip_bypass_rendezvous = false
chip_config_network_layer_ble = true

custom_toolchain = "//third_party/connectedhomeip/config/ameba/toolchain:ameba"

pw_build_PIP_CONSTRAINTS =
[ "//third_party/connectedhomeip/scripts/constraints.txt" ]
8 changes: 8 additions & 0 deletions config/esp32/args.gni
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,11 @@ chip_inet_config_enable_tcp_endpoint = true
chip_inet_config_enable_udp_endpoint = true

custom_toolchain = "//third_party/connectedhomeip/config/esp32/toolchain:esp32"

# Avoid constraint forcing for ESP32:
# Esp32 is also building based on python and there are requirements
# conflicts (e.g. pyparsing at the time this was added)
# Matter already fixes python constraints, we use those instead of
# whatever pigweed ships with
pw_build_PIP_CONSTRAINTS =
[ "//third_party/connectedhomeip/scripts/constraints.txt" ]
2 changes: 2 additions & 0 deletions config/ios/args.gni
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,5 @@ chip_system_config_clock = "gettimeofday"
chip_device_platform = "darwin"

chip_project_config_include_dirs = [ "${chip_root}/config/ios" ]

pw_build_PIP_CONSTRAINTS = [ "${chip_root}/scripts/constraints.txt" ]
2 changes: 2 additions & 0 deletions config/mbed/chip-gn/args.gni
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,5 @@ chip_custom_build_cflags = []

custom_toolchain = "//toolchain:mbed"
mbedtls_target = "//mbedtls:mbedtls"

pw_build_PIP_CONSTRAINTS = [ "${chip_root}/scripts/constraints.txt" ]
2 changes: 2 additions & 0 deletions config/nrfconnect/chip-gn/args.gni
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,5 @@ chip_system_project_config_include = ""
chip_ble_project_config_include = ""

custom_toolchain = "${chip_root}/config/nrfconnect/chip-gn/toolchain:zephyr"

pw_build_PIP_CONSTRAINTS = [ "${chip_root}/scripts/constraints.txt" ]
2 changes: 2 additions & 0 deletions config/qpg/chip-gn/args.gni
Original file line number Diff line number Diff line change
Expand Up @@ -39,3 +39,5 @@ chip_system_project_config_include = "<CHIPProjectConfig.h>"
chip_ble_project_config_include = ""

custom_toolchain = "//config/qpg/chip-gn/toolchain:qpgtoolchain"

pw_build_PIP_CONSTRAINTS = [ "//scripts/constraints.txt" ]
4 changes: 4 additions & 0 deletions config/standalone/args.gni
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@
# See the License for the specific language governing permissions and
# limitations under the License.

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

# Options from standalone-chip.mk that differ from configure defaults. These
# options are used from examples/.
chip_build_tests = false

pw_build_PIP_CONSTRAINTS = [ "${chip_root}/scripts/constraints.txt" ]
2 changes: 2 additions & 0 deletions config/telink/chip-gn/args.gni
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,5 @@ chip_ble_project_config_include = ""
chip_config_network_layer_ble = false

custom_toolchain = "${chip_root}/config/telink/chip-gn/toolchain:zephyr"

pw_build_PIP_CONSTRAINTS = [ "${chip_root}/scripts/constraints.txt" ]
2 changes: 2 additions & 0 deletions config/tizen/chip-gn/args.gni
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,5 @@ chip_device_platform = "tizen"
chip_build_tests = false

chip_inet_config_enable_raw_endpoint = false

pw_build_PIP_CONSTRAINTS = [ "//scripts/constraints.txt" ]

0 comments on commit 1503906

Please sign in to comment.