Updated SS4S (#56) #148
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build Test | |
on: | |
push: | |
# Don't run for tags | |
tags-ignore: | |
- '**' | |
branches: | |
- '**' | |
env: | |
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.) | |
BUILD_TYPE: Release | |
jobs: | |
build-webos: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
submodules: recursive | |
- name: Download ares-cli-rs | |
uses: robinraju/[email protected] | |
with: | |
repository: "webosbrew/ares-cli-rs" | |
latest: true | |
fileName: "ares-package_*.deb" | |
out-file-path: "temp" | |
- name: Download Homebrew Toolbox | |
uses: robinraju/[email protected] | |
with: | |
repository: "webosbrew/dev-toolbox-cli" | |
latest: true | |
fileName: "webosbrew-toolbox-*.deb" | |
out-file-path: "temp" | |
- name: Install Tools | |
run: sudo apt-get install ./temp/*.deb | |
- name: Download webOS NDK | |
uses: robinraju/[email protected] | |
with: | |
repository: "openlgtv/buildroot-nc4" | |
latest: true | |
fileName: "arm-webos-linux-gnueabi_sdk-buildroot.tar.gz" | |
out-file-path: "/tmp" | |
- name: Extract webOS NDK | |
shell: bash | |
working-directory: /tmp | |
run: | | |
tar xzf arm-webos-linux-gnueabi_sdk-buildroot.tar.gz | |
./arm-webos-linux-gnueabi_sdk-buildroot/relocate-sdk.sh | |
- name: Build | |
env: | |
TOOLCHAIN_FILE: /tmp/arm-webos-linux-gnueabi_sdk-buildroot/usr/share/buildroot/toolchainfile.cmake | |
run: ./tools/webos/easy_build.sh -DCMAKE_BUILD_TYPE=$BUILD_TYPE | |
- name: Add Commit Hash Suffix | |
shell: bash | |
working-directory: dist | |
run: for file in *.ipk ; do mv $file ${file//_arm/-${GITHUB_SHA:0:8}_arm} ; done | |
- uses: actions/upload-artifact@v4 | |
with: | |
name: webos-snapshot | |
path: dist/*.ipk | |
- name: Compatibility Check | |
run: webosbrew-ipk-verify -f markdown -d -o $GITHUB_STEP_SUMMARY dist/*.ipk | |
build-raspi: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- name: Run apt-get update | |
shell: bash | |
run: sudo apt-get -y -qq update | |
- name: Prepare Sysroot | |
id: pi-sysroot | |
uses: mariotaku/[email protected] | |
with: | |
release: bullseye | |
packages: ${{github.workspace}}/deploy/raspbian/sysroot-packages.list | |
- name: Install Build Tools | |
shell: bash | |
# apt-get update was implicitly called, so we don't have to call it here | |
run: sudo apt-get -y -qq install crossbuild-essential-armhf cmake | |
- name: Create Build Environment | |
# Some projects don't allow in-source building, so create a separate build directory | |
# We'll use this as our working directory for all subsequent commands | |
run: cmake -E make_directory ${{github.workspace}}/build | |
- name: Configure CMake | |
# Use a bash shell, so we can use the same syntax for environment variable | |
# access regardless of the host operating system | |
shell: bash | |
working-directory: ${{github.workspace}}/build | |
# Note the current convention is to use the -S and -B options here to specify source | |
# and build directories, but this is only available with CMake 3.13 and higher. | |
# The CMake binaries on the GitHub Actions machines are (as of this writing) 3.12 | |
run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DTARGET_RASPI=ON | |
-DCMAKE_TOOLCHAIN_FILE=${{steps.pi-sysroot.outputs.cmake-toolchain}} | |
- name: Build | |
working-directory: ${{github.workspace}}/build | |
shell: bash | |
# Execute the build. You can specify a specific target with "--target <NAME>" | |
run: | | |
cmake --build . --config $BUILD_TYPE |