Build image #26
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 image | |
on: | |
workflow_dispatch: | |
push: | |
# Pattern matched against refs/tags | |
tags: | |
- '*' # Push events to every tag not containing / | |
jobs: | |
build: | |
runs-on: ubuntu-22.04 | |
# Use the Bash shell regardless whether the GitHub Actions runner is ubuntu-latest, macos-latest, or windows-latest | |
defaults: | |
run: | |
shell: bash | |
steps: | |
- name: cleanup | |
run: | | |
sudo rm -rf /usr/share/dotnet | |
- name: check free space | |
run: | | |
df -h | |
pwd | |
# Checkout the repository to the GitHub Actions runner | |
- name: Checkout GUI | |
uses: actions/checkout@v4 | |
with: | |
submodules: true | |
path: x6100_gui | |
- name: Checkout buildroot | |
uses: actions/checkout@v4 | |
with: | |
submodules: true | |
repository: gdyuldin/AetherX6100Buildroot | |
path: AetherX6100Buildroot | |
- name: Patch GUI mk | |
run: | | |
sed -i "s,https://github.com/gdyuldin/x6100_gui,${GITHUB_WORKSPACE}/x6100_gui,g" AetherX6100Buildroot/br2_external/package/x6100-gui/x6100_gui.mk | |
sed -i "s,^X6100_GUI_SITE_METHOD = git,X6100_GUI_SITE_METHOD = local,g" AetherX6100Buildroot/br2_external/package/x6100-gui/x6100_gui.mk | |
sed -i "s,^X6100_GUI_GIT_SUBMODULES,# X6100_GUI_GIT_SUBMODULES,g" AetherX6100Buildroot/br2_external/package/x6100-gui/x6100_gui.mk | |
- name: Cache ccache | |
id: cache-ccache | |
uses: actions/cache@v4 | |
with: | |
path: ~/.buildroot-ccache | |
key: ${{ runner.os }}-ccache | |
# Configure | |
- name: Configure | |
run: | | |
cd AetherX6100Buildroot && bash ./br_config.sh | |
# Build | |
- name: Build | |
run: | | |
cd AetherX6100Buildroot/build | |
make lame mpg123 | |
make libsndfile-dirclean | |
make | |
# Compress image | |
- name: Compress image | |
run: | | |
cd AetherX6100Buildroot/build/images | |
zip sdcard.img.zip sdcard.img | |
# Upload image | |
- name: 'Upload image' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: sdcard.img | |
path: AetherX6100Buildroot/build/images/sdcard.img | |
# Create release | |
- name: Release | |
uses: softprops/action-gh-release@v2 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
files: AetherX6100Buildroot/build/images/sdcard.img.zip |