Fix compile error with recent LuaJIT rolling release when compiled al… #23
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: LS2X-CI | |
on: [push, pull_request] | |
jobs: | |
build-linux: | |
name: LS2X-Ubuntu | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Update APT | |
run: sudo apt-get update | |
- name: Install FFmpeg Development Libraries | |
run: sudo apt-get install ffmpeg libavcodec-dev libavformat-dev libavutil-dev libswresample-dev libswscale-dev --assume-yes | |
- name: Install LuaJIT Development Libraries | |
run: sudo apt-get install libluajit-5.1-dev | |
- name: Print FFmpeg Version | |
run: ffmpeg -version | |
- name: Configure | |
run: cmake -Bbuild -S. --install-prefix $PWD/install -DCMAKE_BUILD_TYPE=Release | |
- name: Build | |
run: cmake --build build --target install | |
- name: Upload Artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ls2xlib-linux | |
path: install/lib/* | |
build-windows: | |
name: LS2X-Windows | |
runs-on: windows-2019 | |
strategy: | |
matrix: | |
ffmpeg-branch: ["4.4.1", "5.0", "6.0"] | |
env: | |
FFMPEG_TAG: ${{ matrix.ffmpeg-branch }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Download FFmpeg Development Libraries | |
shell: cmd | |
run: | | |
curl -Lo ffmpeg-dev.7z https://github.com/GyanD/codexffmpeg/releases/download/%FFMPEG_TAG%/ffmpeg-%FFMPEG_TAG%-full_build-shared.7z | |
7z x ffmpeg-dev.7z | |
- name: Shallow Clone LuaJIT | |
uses: actions/checkout@v3 | |
with: | |
repository: LuaJIT/LuaJIT | |
path: LuaJIT | |
- name: Build LuaJIT | |
shell: cmd | |
run: | | |
rem https://github.com/actions/runner-images/blob/main/images/win/Windows2019-Readme.md#visual-studio-enterprise-2019 | |
set VCBT="C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" | |
call %VCBT% x86_amd64 | |
if errorlevel 1 exit /b 1 | |
cd LuaJIT\src | |
if errorlevel 1 exit /b 1 | |
msvcbuild.bat amalg | |
if errorlevel 1 exit /b 1 | |
- name: Configure | |
shell: cmd | |
run: cmake -Bbuild -S. --install-prefix %CD%\install -DLUAJIT_DIR=%CD%\LuaJIT\src -DLIBAV_INCLUDE_DIR=%CD%\ffmpeg-%FFMPEG_TAG%-full_build-shared\include -T v142 -A x64 | |
- name: Build | |
shell: cmd | |
run: cmake --build build --config Release --target install | |
- name: Upload Artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ls2xlib-win64-ffmpeg${{ matrix.ffmpeg-branch }} | |
path: install/lib/* |