From f9dbaba07643f15ea89e34e813d10ece1a2584dc Mon Sep 17 00:00:00 2001 From: John Wellbelove Date: Tue, 11 Aug 2020 09:52:12 +0100 Subject: [PATCH] Github actions for MSVC --- .github/workflows/main.yml | 73 ++++++++++++++------------------------ 1 file changed, 26 insertions(+), 47 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index b73dbf6f..941408b3 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,61 +1,40 @@ name: CI on: push: - branches: [ master, hotfix/clang-9 ] + branches: [ feature/github-actions-for-windows-compilers ] pull_request: branches: [ master ] jobs: - build: - runs-on: ${{ matrix.os }} - strategy: - matrix: - os: [ubuntu-18.04, ubuntu-20.04] + + build-visual-studio + runs-on: [windows] steps: - - uses: actions/checkout@v2 - - - name: Setup cmake - run: cmake -DBUILD_TESTS=ON ./ - - - name: Compile - run: make - - - name: Run tests - run: ./test/etl_tests - - - name: Save artifacts - uses: actions/upload-artifact@v2 + - name: Checkout + uses: actions/checkout@v2 with: - name: Testfile - path: test/etl_tests + submodules: recursive + + - name: Installing vcpkg + run: | + cd .. + git clone https://github.com/Microsoft/vcpkg.git + cd vcpkg + git checkout --force 2020.01 + .\bootstrap-vcpkg.bat + .\vcpkg.exe install cppzmq:x64-windows + + - name: Running cmake + run: | + cd ${{ github.workspace }} + mkdir build + cd build + cmake .. -DCMAKE_TOOLCHAIN_FILE=${{ github.workspace }} + /../vcpkg/scripts/buildsystems/vcpkg.cmake - build-clang-9-Linux: - runs-on: ubuntu-18.04 - steps: - - uses: actions/checkout@v2 - name: Build and run run: | - export CC=clang-9 - export CXX=clang++-9 cmake -D BUILD_TESTS=ON ./ - make - ./test/etl_tests - - - name: Save artifacts - uses: actions/upload-artifact@v2 - with: - name: Testfile - path: test/etl_tests - - build-clang-10-osx: - runs-on: macos-10.15 - steps: - - uses: actions/checkout@v2 - - name: Build and run - run: | - export CC=clang - export CXX=clang++ - cmake -D BUILD_TESTS=ON ./ - make - ./test/etl_tests + cd build + MSBuild.exe etl.sln