Check msys2 perf

This commit is contained in:
Stepanov Igor 2024-12-25 17:20:18 +03:00
parent c17c6b6e93
commit 54c51b5e64

View File

@ -21,35 +21,56 @@ jobs:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
with: with:
submodules: 'true' submodules: 'true'
- uses: msys2/setup-msys2@v2
- name: Install latest cmake and ninja id: msys2
uses: lukka/get-cmake@latest name: Setup MSYS2
with:
- name: Bootstrap vcpkg msystem: clang64
shell: pwsh install: >-
mingw-w64-clang-x86_64-toolchain
mingw-w64-clang-x86_64-cmake
mingw-w64-clang-x86_64-make
mingw-w64-clang-x86_64-luajit
git
- name: Set up vcpkg
shell: msys2 {0}
run: | run: |
git clone https://github.com/microsoft/vcpkg.git git clone https://github.com/microsoft/vcpkg.git
${{ github.workspace }}/vcpkg/bootstrap-vcpkg.bat cd vcpkg
- name: Configure and build project with CMake and vcpkg ./bootstrap-vcpkg.bat
env: ./vcpkg integrate install
VCPKG_ROOT: ${{ github.workspace }}/vcpkg cd ..
- name: Configure project with CMake and vcpkg
shell: msys2 {0}
run: | run: |
cmake --preset default-ninja-clang-windows export VCPKG_DEFAULT_TRIPLET=x64-mingw-static
cmake --build --preset default-ninja-clang-windows --config Release export VCPKG_DEFAULT_HOST_TRIPLET=x64-mingw-static
- name: Run tests export VCPKG_DEFAULT_HOST_TRIPLET=./vcpkg
run: ctest --preset default-vs-msvc-windows mkdir build
- name: Run engine tests cd build
run: | cmake -G "MinGW Makefiles" -DVCPKG_TARGET_TRIPLET=x64-mingw-static -DCMAKE_BUILD_TYPE=Release -DVOXELENGINE_BUILD_WINDOWS_VCPKG=ON ..
build/vctest/Release/vctest.exe -e build/Release/VoxelEngine.exe -d dev/tests -u build --output-always cmake --build . --config Release
timeout-minutes: 1
- name: Package for Windows - name: Package for Windows
run: | run: |
mkdir packaged mkdir packaged
cp -r build/Release/* packaged/ mkdir packaged/res
cp build/vctest/Release/vctest.exe packaged/ cp build/VoxelEngine.exe packaged/
cp build/vctest/vctest.exe packaged/
cp build/*.dll packaged/
cp -r build/res/* packaged/res/
mv packaged/VoxelEngine.exe packaged/VoxelCore.exe mv packaged/VoxelEngine.exe packaged/VoxelCore.exe
- env:
MSYS2_LOCATION: ${{ steps.msys2.outputs.msys2-location }}
name: Add lua51.dll to the package
run: |
cp $env:MSYS2_LOCATION/clang64/bin/lua51.dll ${{ github.workspace }}/packaged/
working-directory: ${{ github.workspace }} working-directory: ${{ github.workspace }}
- uses: actions/upload-artifact@v4 - uses: actions/upload-artifact@v4
with: with:
name: Windows-Build name: Windows-Build
path: 'packaged/*' path: 'packaged/*'
- name: Run engine tests
shell: msys2 {0}
working-directory: ${{ github.workspace }}
run: |
packaged/vctest.exe -e packaged/VoxelCore.exe -d dev/tests -u build --output-always