Enable gRPC support for macOS and Windows (#565)

This commit is contained in:
Kirill Bobyrev 2020-10-18 13:58:12 +02:00 committed by GitHub
parent 6f906275b0
commit 8d1f3300c5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -41,7 +41,7 @@ jobs:
config:
- name: windows
os: windows-latest
preinstall: choco install ninja
preinstall: choco install ninja nasm
vcvars: C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvars64.bat
cflags: /O2 /DNDEBUG
# FIXME: remove ALLOW_OLD_TOOLCHAIN once VS 16.5 is available.
@ -51,6 +51,8 @@ jobs:
"-DLLVM_ENABLE_ZLIB=OFF"
"-DLLVM_USE_CRT_RELEASE=MT"
"-DLLVM_TEMPORARILY_ALLOW_OLD_TOOLCHAIN=ON"
grpc_cmake: >
"-DgRPC_MSVC_STATIC_RUNTIME=ON"
binary_extension: ".exe"
- name: mac
os: macos-latest
@ -72,7 +74,6 @@ jobs:
"-DLLVM_STATIC_LINK_CXX_STDLIB=ON"
"-DLLVM_ENABLE_ZLIB=FORCE_ON"
"-DCMAKE_PROJECT_INCLUDE=$GITHUB_WORKSPACE/.github/workflows/linux-static-deps.cmake"
"-DCLANGD_ENABLE_REMOTE=ON"
# Using c-ares as a module prevents dynamic linking of unneeded
# libraries. All other gRPC dependencies can be built from sources.
grpc_cmake: >
@ -99,7 +100,6 @@ jobs:
# FIXME: gRPC support is currently available only on Linux. Other platforms
# will be added later.
- name: Clone gRPC
if: matrix.config.name == 'linux'
uses: actions/checkout@v2
with:
repository: grpc/grpc
@ -107,7 +107,6 @@ jobs:
ref: v1.32.0
submodules: recursive
- name: Build gRPC
if: matrix.config.name == 'linux'
run: >
mkdir grpc-installation
@ -150,6 +149,7 @@ jobs:
"-DLLVM_ENABLE_PLUGINS=OFF"
"-DCMAKE_C_FLAGS_RELEASE=${{ matrix.config.cflags }}"
"-DCMAKE_CXX_FLAGS_RELEASE=${{ matrix.config.cflags }}"
"-DCLANGD_ENABLE_REMOTE=ON"
"-DGRPC_INSTALL_PATH=grpc-installation"
${{ matrix.config.cmake }}
- name: Ninja