Files
UnrealEngineUWP/Engine/Source/Editor/Experimental/BazelExecutor/Generate.bat
Joe Kirchoff 152203ac9d Update Win64 vcpkg to 2021.05.12, Linux will be enabled in a separate changelist
#rb none
#preflight 60c3ed4713e9fc00017b7358

[CL 16652339 by Joe Kirchoff in ue5-main branch]
2021-06-12 15:36:56 -04:00

34 lines
945 B
Batchfile
Executable File

@echo off
setlocal
SET vcpkg_root=%~dp0..\..\..\ThirdParty\vcpkg\Win64\x64-windows-static-md-v142
SET protoc=%vcpkg_root%\protobuf_x64-windows-static-md-v142\tools\protobuf\protoc.exe
SET include=%vcpkg_root%\protobuf_x64-windows-static-md-v142\include
SET grpc_cpp_plugin=%vcpkg_root%\grpc_x64-windows\tools\grpc\grpc_cpp_plugin.exe
pushd %~dp0
mkdir .\Generated
for /R ".\Schemas" %%f in (*.proto) do (
%protoc% -I=%include% --proto_path=%CD%\Schemas --cpp_out=%CD%\Generated %%f
%protoc% -I=%include% --proto_path=%CD%\Schemas --plugin=protoc-gen-grpc=%grpc_cpp_plugin% --grpc_out=%CD%\Generated %%f
)
for /R ".\Generated" %%f in (*.pb.cc) do (
type SchemaAutogenHeader.txt >%%f.new
type SchemaHeader.txt >>%%f.new
type %%f >>%%f.new
type SchemaFooter.txt >>%%f.new
move /y %%f.new %%f >NUL
)
for /R ".\Generated" %%f in (*.pb.h) do (
type SchemaAutogenHeader.txt >%%f.new
type %%f >>%%f.new
move /y %%f.new %%f >NUL
)
popd