Skip to content

Commit

Permalink
Merge branch 'master' into attribute_list_sizes
Browse files Browse the repository at this point in the history
  • Loading branch information
andy31415 committed Jan 21, 2022
2 parents 4fd91c6 + cf1b254 commit 917e524
Show file tree
Hide file tree
Showing 121 changed files with 7,434 additions and 1,385 deletions.
1 change: 1 addition & 0 deletions .github/.wordlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -993,6 +993,7 @@ TLV
tmp
tngvndl
TODO
tokenized
toolchain
toolchains
topologies
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/examples-efr32.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ jobs:
timeout-minutes: 10
run: |
scripts/examples/gn_efr32_example.sh examples/lighting-app/efr32/ out/lighting_app_debug_rpc BRD4161A \
-args='import("//with_pw_rpc.gni")'
'import("//with_pw_rpc.gni")'
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py efr32 BRD4161A+rpc lighting-app \
out/lighting_app_debug_rpc/BRD4161A/chip-efr32-lighting-example.out /tmp/bloat_reports/
- name: Build example EFR32 Window Covering for BRD4161A
Expand Down
131 changes: 131 additions & 0 deletions .github/workflows/fuzzing-build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,131 @@
# Copyright (c) 2021 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.

name: Fuzzing Builds

on:
# For now, only manual triggers.
workflow_dispatch:

concurrency:
group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }}
cancel-in-progress: true

jobs:
build_linux_fuzzing:
name: Build on Linux
timeout-minutes: 90

runs-on: ubuntu-latest
if: github.actor != 'restyled-io[bot]'

container:
image: connectedhomeip/chip-build:0.5.48
volumes:
- "/tmp/log_output:/tmp/test_logs"

steps:
- name: Checkout
uses: actions/checkout@v2
with:
submodules: true
- run: apt-get update
- run: apt-get install --fix-missing llvm-10 clang-10
- name:
Try to ensure the objdir-clone dir exists
run: |
mkdir objdir-clone || true
- name: Bootstrap
timeout-minutes: 10
run: scripts/build/gn_bootstrap.sh
- name: Uploading bootstrap logs
uses: actions/upload-artifact@v2
if: ${{ always() }} && ${{ !env.ACT }}
with:
name: bootstrap-logs
path: |
.environment/gn_out/.ninja_log
.environment/pigweed-venv/*.log
- name: Build all-clusters-app
timeout-minutes: 20
run: |
./scripts/run_in_build_env.sh \
"./scripts/build/build_examples.py \
--target linux-x64-all-clusters-no-ble-libfuzzer-test-group \
build \
--copy-artifacts-to objdir-clone \
"
- name: Uploading binaries
uses: actions/upload-artifact@v2
if: ${{ !env.ACT }}
with:
name:
objdir-linux
path: objdir-clone/
# objdirs are big; don't hold on to them too long.
retention-days: 5

build_darwin_fuzzing:
name: Build on Darwin
timeout-minutes: 90
runs-on: macos-latest
if: github.actor != 'restyled-io[bot]'

steps:
- name: Checkout
uses: actions/checkout@v2
with:
submodules: true
- name: Setup Environment
run: brew install openssl pkg-config llvm
- name: Try to ensure the objdir-clone dir exists
run: |
mkdir objdir-clone || true
- name: Fix pkgconfig link
working-directory: /usr/local/lib/pkgconfig
run: |
pwd
ls -la /usr/local/Cellar/
ls -la /usr/local/Cellar/[email protected]
OPEN_SSL_VERSION=`ls -la /usr/local/Cellar/[email protected] | cat | tail -n1 | awk '{print $NF}'`
ln -s /usr/local/Cellar/[email protected]/$OPEN_SSL_VERSION/lib/pkgconfig/* .
- name: Bootstrap
timeout-minutes: 25
run: scripts/build/gn_bootstrap.sh
- name: Uploading bootstrap logs
uses: actions/upload-artifact@v2
if: ${{ always() }} && ${{ !env.ACT }}
with:
name: bootstrap-logs
path: |
.environment/gn_out/.ninja_log
.environment/pigweed-venv/*.log
- name: Build all-clusters-app
timeout-minutes: 20
run: |
./scripts/run_in_build_env.sh \
"./scripts/build/build_examples.py \
--target darwin-x64-all-clusters-no-ble-asan-libfuzzer \
build \
--copy-artifacts-to objdir-clone \
"
- name: Uploading binaries
uses: actions/upload-artifact@v2
if: ${{ !env.ACT }}
with:
name:
crash-darwin
path: objdir-clone/
# objdirs are big; don't hold on to them too long.
retention-days: 5
3 changes: 0 additions & 3 deletions build/config/compiler/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -307,9 +307,6 @@ declare_args() {
# enable undefined behavior sanitizer
is_ubsan = false

# enable libfuzzer
is_libfuzzer = false

# Exit on sanitize error. Generally standard libraries may get errors
# so not stopping on the first error is often useful
is_sanitize_fatal = true
Expand Down
3 changes: 3 additions & 0 deletions build/config/compiler/compiler.gni
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,7 @@ declare_args() {

# C++ standard level (value for -std flag).
cpp_standard = "gnu++14"

# enable libfuzzer
is_libfuzzer = false
}
6 changes: 6 additions & 0 deletions config/efr32/toolchain/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,9 @@ arm_toolchain("efr32_window_app") {
import("${chip_root}/examples/window-app/efr32/args.gni")
}
}
arm_toolchain("rs911x_lock_app") {
toolchain_args = {
current_os = "freertos"
import("${chip_root}/examples/lock-app/rs911x/args.gni")
}
}
1 change: 1 addition & 0 deletions config/esp32/components/chip/component.mk
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ ifeq ($(is_debug),false)
endif
if [[ "$(CONFIG_ENABLE_PW_RPC)" = "y" ]]; then \
echo "chip_build_pw_rpc_lib = true" >> $(OUTPUT_DIR)/args.gn ;\
echo "chip_build_pw_trace_lib = true" >> $(OUTPUT_DIR)/args.gn ;\
echo "remove_default_configs = [\"//third_party/connectedhomeip/third_party/pigweed/repo/pw_build:cpp17\"]" >> $(OUTPUT_DIR)/args.gn ;\
echo "pw_log_BACKEND = \"//third_party/connectedhomeip/third_party/pigweed/repo/pw_log_basic\"" >> $(OUTPUT_DIR)/args.gn ;\
echo "pw_assert_BACKEND = \"//third_party/connectedhomeip/third_party/pigweed/repo/pw_assert_log\"" >> $(OUTPUT_DIR)/args.gn ;\
Expand Down
1 change: 1 addition & 0 deletions examples/all-clusters-app/all-clusters-common/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,5 @@ chip_data_model("all-clusters-common") {
zap_pregenerated_dir =
"${chip_root}/zzz_generated/all-clusters-app/zap-generated"
is_server = true
use_default_client_callbacks = true
}
Loading

0 comments on commit 917e524

Please sign in to comment.