Skip to content

Commit

Permalink
fix: Github Actions failure
Browse files Browse the repository at this point in the history
  • Loading branch information
MikeWang000000 committed Feb 1, 2025
1 parent fac87dc commit 3dbf014
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 24 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/caching.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ on:
jobs:
Windows-MSYS2-MINGW64-Caching:
name: Windows MSYS2/MINGW64 Caching
runs-on: windows-2022
runs-on: windows-latest
defaults:
run:
shell: msys2 {0}
steps:
- name: Check out repository code
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Setup MSYS2
uses: msys2/setup-msys2@v2
with:
Expand All @@ -24,7 +24,7 @@ jobs:
cd '${{ github.workspace }}' && ./dist/win/install_deps.sh
du -sh 'C:\msys2'
- name: Cache MSYS2
uses: actions/cache@v3
uses: actions/cache@v4
with:
key: spek-x-msys2-mingw64
path: C:\msys2
41 changes: 21 additions & 20 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,39 +8,39 @@ env:
jobs:
Build-Debian-x86_64:
name: Build Spek-X (Debian, x86_64)
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
container: debian:sid
steps:
- name: Check out repository code
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Install dependencies
run: |
sudo apt update
sudo apt install -y intltool libwxgtk3.2-dev wx-common libavcodec-dev libavformat-dev
apt update
apt install -y g++ make pkg-config libtool intltool libwxgtk3.2-dev wx-common libavcodec-dev libavformat-dev
- name: Compile and bundle application
run: |
cd '${{ github.workspace }}'
mkdir -p ./dist/debian/spek-x/usr ./dist/debian/spek-x/DEBIAN
./autogen.sh --prefix="$(realpath ./dist/debian/spek-x/usr)"
make -j2 && make install
cp ./dist/debian/control.ci ./dist/debian/spek-x/DEBIAN/control
dpkg-deb --build dist/debian/spek-x
- name: Archive production artifacts
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: Spek-X (Debian, x86_64)
path: ${{ github.workspace }}/dist/debian/spek-x.deb

Build-Windows-x64:
name: Build Spek-X (Windows, x64)
runs-on: windows-2022
runs-on: windows-latest
defaults:
run:
shell: cmd
steps:
- name: Check out repository code
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Get dependencies from cache
uses: actions/cache/restore@v3
uses: actions/cache/restore@v4
with:
key: spek-x-msys2-mingw64
path: C:\msys2
Expand All @@ -51,17 +51,17 @@ jobs:
run: |
"C:\msys2\msys64\usr\bin\env.exe" MSYSTEM=MINGW64 /usr/bin/bash -lc "cd '${{ github.workspace }}' && ./dist/win/bundle.sh"
- name: Archive production artifacts
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: Spek-X (Windows, x64)
path: ${{ github.workspace }}/dist/win/Spek/Spek.zip

Build-macOS-Intel:
name: Build Spek-X (macOS, Intel)
runs-on: macos-12
runs-on: macos-13
steps:
- name: Check out repository code
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Install dependencies
run: |
eval "$(brew shellenv)"
Expand All @@ -72,17 +72,17 @@ jobs:
eval "$(brew shellenv)"
cd '${{ github.workspace }}' && ./dist/osx/bundle.sh
- name: Archive production artifacts
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: Spek-X (macOS, Intel)
path: ${{ github.workspace }}/dist/osx/Spek.tgz

Build-macOS-AppleSilicon:
name: Build Spek-X (macOS, Apple Silicon)
runs-on: macos-12
runs-on: macos-13
steps:
- name: Check out repository code
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Install dependencies
run: |
eval "$(brew shellenv)"
Expand All @@ -93,21 +93,22 @@ jobs:
eval "$(brew shellenv)"
cd '${{ github.workspace }}' && ./dist/osx/cross/bundle.sh i_am_ci
- name: Archive production artifacts
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: Spek-X (macOS, Apple Silicon)
path: ${{ github.workspace }}/dist/osx/Spek.tgz

Unit-Test:
name: Unit Tests
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
container: debian:sid
steps:
- name: Check out repository code
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Install dependencies
run: |
sudo apt update
sudo apt install -y intltool libwxgtk3.2-dev wx-common libavcodec-dev libavformat-dev
apt update
apt install -y g++ make pkg-config libtool intltool libwxgtk3.2-dev wx-common libavcodec-dev libavformat-dev
- name: Run tests
run: |
./autogen.sh && make check
2 changes: 1 addition & 1 deletion dist/osx/cross/install_deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ brew install autoconf automake gettext intltool libtool pkg-config wxwidgets nas
# Force install arm64 libraries on x86_64 machines
for dep in jpeg-turbo libpng zstd libtiff pcre2 wxwidgets
do
brew reinstall $(brew fetch --force --bottle-tag=arm64_monterey "${dep}" | egrep -om1 '/Users/.*\.gz') || return 1
brew reinstall $(brew fetch --force --bottle-tag=arm64_ventura "${dep}" | egrep -om1 '/Users/.*\.gz') || exit 1
done

rm -rf $(dirname $0)/../deps
Expand Down

0 comments on commit 3dbf014

Please sign in to comment.