mirror of https://github.com/grpc/grpc-node.git
grpc-tools build script fixes part 2
This commit is contained in:
parent
c349c201d4
commit
b2756d2d78
|
@ -1,3 +1,5 @@
|
|||
$ErrorActionPreference = "Stop"
|
||||
|
||||
Install-PackageProvider -Name NuGet -RequiredVersion 2.8.5.201 -Force
|
||||
Import-PackageProvider -Name NuGet -RequiredVersion 2.8.5.201
|
||||
Install-Module -Force -Name 7Zip4Powershell
|
||||
|
@ -28,16 +30,17 @@ foreach ($Arch in $ArchList) {
|
|||
} else {
|
||||
$Generator = "Visual Studio 14 2015"
|
||||
}
|
||||
Remove-Item ($Base + "/build/bin/protoc.exe")
|
||||
Remove-Item ($Base + "/build/bin/grpc_node_plugin.exe")
|
||||
Remove-Item ($Base + "CMakeCache.txt")
|
||||
|
||||
Invoke-Expression "cmake ."
|
||||
Invoke-Expression "cmake --build ."
|
||||
& cmake .
|
||||
& cmake --build .
|
||||
|
||||
Copy-Item ($ProtobufBase + "/protoc.exe") -Destination ($Base + "/build/bin/protoc.exe")
|
||||
Copy-Item ($Base + "/grpc_node_plugin.exe") -Destination ($Base + "/build/bin/grpc_node_plugin.exe")
|
||||
|
||||
Compress-7Zip -Path ($Base + "/build") -Format Tar -ArchiveFileName ($Base + "/Archive.tar")
|
||||
Compress-7Zip -Path ($Base + "/Archive.tar") -Format GZip -ArchiveFileName ($OutDir + "/windows-x64.tar.gz")
|
||||
|
||||
Remove-Item ($Base + "/build/bin/protoc.exe")
|
||||
Remove-Item ($Base + "/build/bin/grpc_node_plugin.exe")
|
||||
Remove-Item ($Base + "CMakeCache.txt")
|
||||
}
|
|
@ -3,6 +3,8 @@ cd ../..
|
|||
|
||||
git submodule update --init --recursive
|
||||
|
||||
@rem make sure msys binaries are preferred over cygwin binaries
|
||||
set PATH=C:\tools\msys64\usr\bin;%PATH%
|
||||
set ARTIFACTS_OUT=%cd%/artifacts
|
||||
powershell -File ./packages/grpc-tools/build_binaries.ps1 || goto :error
|
||||
goto :EOF
|
||||
|
|
Loading…
Reference in New Issue