From 8d396573b3074b7b677511f353f20f7fa96df4b6 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Wed, 6 Jun 2018 16:56:35 +0200 Subject: fix test_codegen for x86 --- test/distrib/csharp/test_codegen/test_codegen.sh | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'test/distrib') diff --git a/test/distrib/csharp/test_codegen/test_codegen.sh b/test/distrib/csharp/test_codegen/test_codegen.sh index 62c9040f20..21ccb7e6c3 100755 --- a/test/distrib/csharp/test_codegen/test_codegen.sh +++ b/test/distrib/csharp/test_codegen/test_codegen.sh @@ -17,12 +17,18 @@ set -ex cd "$(dirname "$0")" -ls -lR ../packages/Grpc.Tools.__GRPC_NUGET_VERSION__/tools +ls -lR "../packages/Grpc.Tools.__GRPC_NUGET_VERSION__/tools" -PROTOC=../packages/Grpc.Tools.__GRPC_NUGET_VERSION__/tools/linux_x64/protoc -PLUGIN=../packages/Grpc.Tools.__GRPC_NUGET_VERSION__/tools/linux_x64/grpc_csharp_plugin +PLATFORM_ARCH=linux_x64 +if [ "$(getconf LONG_BIT)" == "32" ] +then + PLATFORM_ARCH=linux_x86 +fi -$PROTOC --plugin=protoc-gen-grpc=$PLUGIN --csharp_out=. --grpc_out=. -I . helloworld.proto +PROTOC="../packages/Grpc.Tools.__GRPC_NUGET_VERSION__/tools/${PLATFORM_ARCH}/protoc" +PLUGIN="../packages/Grpc.Tools.__GRPC_NUGET_VERSION__/tools/${PLATFORM_ARCH}/grpc_csharp_plugin" + +$PROTOC --plugin="protoc-gen-grpc=${PLUGIN}" --csharp_out=. --grpc_out=. -I . helloworld.proto ls *.cs -- cgit v1.2.3