Skip to content

Commit

Permalink
Add .github/workflows/build.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
kubamracek committed Dec 12, 2024
1 parent d6f88d3 commit 6db80df
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 0 deletions.
49 changes: 49 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: Build Matter Examples

on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
schedule:
# Build on Mondays at 9am PST every week
- cron: '0 17 * * 1'

jobs:
build:
runs-on: ubuntu-latest
container: espressif/esp-matter:latest

steps:
- name: Checkout repo
uses: actions/checkout@v4

- name: Install Swift & CMake
run: |
set -vex
SWIFT_TOOLCHAIN_VERSION=swift-DEVELOPMENT-SNAPSHOT-2024-08-01-a
wget https://download.swift.org/development/ubuntu2204/${SWIFT_TOOLCHAIN_VERSION}/${SWIFT_TOOLCHAIN_VERSION}-ubuntu22.04.tar.gz
tar xzf ${SWIFT_TOOLCHAIN_VERSION}-ubuntu22.04.tar.gz
export PATH="$PATH:`pwd`/${SWIFT_TOOLCHAIN_VERSION}-ubuntu22.04/usr/bin/"
swiftc --version
wget https://github.com/Kitware/CMake/releases/download/v3.30.2/cmake-3.30.2-linux-x86_64.tar.gz
tar xzf cmake-3.30.2-linux-x86_64.tar.gz
export PATH="`pwd`/cmake-3.30.2-linux-x86_64/bin:$PATH"
cmake --version
echo "PATH=$PATH" >> $GITHUB_ENV
- name: Build with idf.py
run: |
pwd
cd /opt/espressif/esp-idf
. ./export.sh
cd -
cd /opt/espressif/esp-matter
. ./export.sh
cd -
cd smart-light/
idf.py set-target esp32c6 &&
idf.py build
2 changes: 2 additions & 0 deletions smart-light/main/BridgingHeader.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@
//
// connectedhomeip/src/credentials/FabricTable.h:82:69: error: use of undeclared identifier 'strnlen'
extern "C" size_t strnlen(const char *s, size_t maxlen);
// esp-matter/components/esp_matter/esp_matter_client.h:57:26: error: use of undeclared identifier 'strdup'
extern "C" char *strdup(const char *s1);

#include <esp_matter.h>
#include <esp_matter_cluster.h>
Expand Down

0 comments on commit 6db80df

Please sign in to comment.