Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add CI for MSYS2, and package build as artifact #757

Merged
merged 1 commit into from
Oct 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/action.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: GitHub Actions
name: Generic cross-platform tests

on:
push:
Expand Down
54 changes: 54 additions & 0 deletions .github/workflows/msys2.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: Build on MSYS2

on: [ push, pull_request ]

jobs:
build:
runs-on: windows-latest
steps:
- name: Set git to use LF
run: |
git config --global core.autocrlf false
git config --global core.eol lf

- uses: actions/checkout@v4
- uses: msys2/setup-msys2@v2
with:
msystem: mingw64
install: autotools mingw-w64-x86_64-gcc mingw-w64-x86_64-libogg

- name: Install pandoc
run: |
choco install pandoc

- name: Build, run tests and prepare package
shell: msys2 {0}
run: |
PATH=$PATH:/c/ProgramData/chocolatey/bin/
./autogen.sh
./configure --enable-static --disable-shared # This is because the libtool helper script doesn't handle UTF-8 filenames correctly
make LDFLAGS='-all-static' # Otherwise ogg isn't linked statically
make check
mkdir flac
cp src/flac/flac.exe flac/flac.exe
cp src/metaflac/metaflac.exe flac/metaflac.exe
strip flac/*.exe
cp COPYING.* flac
cp AUTHORS flac
cp README* flac
cp man/*.html flac

- name: Upload logs on failure
uses: actions/upload-artifact@v4
if: failure()
with:
name: flac-${{ github.sha }}-${{ github.run_id }}-logs
path: |
./**/*.log
./**/out*.meta

- name: Package build
uses: actions/upload-artifact@v4
with:
name: flac-win64-static-${{ github.sha}}
path: flac
2 changes: 1 addition & 1 deletion .github/workflows/options.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: GitHub Actions for specific options
name: Building with specific options

on:
push:
Expand Down
Loading