This repository has been archived by the owner on Nov 6, 2023. It is now read-only.
update working dir #6
Workflow file for this run
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: Build gRPC for Windows | |
on: | |
push: | |
branches: ['nh-57056-cpp17-github-actions'] | |
# Inputs for reusable workflow | |
workflow_call: | |
inputs: | |
logLevel: | |
description: 'Log level' | |
required: true | |
default: 'warning' | |
type: string | |
# Inputs for manually triggered workflow | |
workflow_dispatch: | |
inputs: | |
logLevel: | |
description: 'Log level' | |
required: true | |
default: 'warning' | |
jobs: | |
build: | |
strategy: | |
matrix: | |
arch: ['32', '64'] | |
configuration: ['Release', 'Debug'] | |
fail-fast: false | |
runs-on: windows-latest | |
steps: | |
- name: Set git to use LF | |
run: | | |
git config --global core.autocrlf false | |
git config --global core.eol lf | |
- name: 32 bit - set environment variables | |
if: ${{ matrix.arch == '32' }} | |
shell: powershell | |
run: | | |
echo "PLATFORM=win32" >> $env:GITHUB_ENV | |
- name: 64 bit - set environment variables | |
if: ${{ matrix.arch == '64' }} | |
shell: powershell | |
run: | | |
echo "PLATFORM=x64" >> $env:GITHUB_ENV | |
- name: Checkout ${{ github.ref }} | |
uses: actions/checkout@v3 | |
- name: Checkout gRPC repository | |
uses: actions/checkout@v3 | |
with: | |
path: grpc | |
- name: Add msbuild to PATH | |
uses: microsoft/[email protected] | |
- name: Build gRPC ${{ matrix.arch }} bit ( ${{ matrix.configuration }} ) | |
working-directory: ${{ github.workspace }}/grpc/build_windows_${{ matrix.arch }} | |
shell: cmd | |
run: | | |
dir "C:\\Program Files\\Microsoft Visual Studio\\2022\\Professional\\Common7\\IDE\\CommonExtensions\\Microsoft\\CMake\\CMake\\share\\" | |
msbuild.exe -maxcpucount /t:Clean,Build /m /p:Configuration=${{ matrix.configuration }} /p:Platform=${{ env.PLATFORM }} /fl /flp:logfile=build-${{ matrix.arch }}.${{ matrix.configuration }}.log;verbosity=diagnostic grpc.sln | |