Created
October 26, 2017 00:33
-
-
Save bluekyu/bdf897ce25653739f2208c83f3412a60 to your computer and use it in GitHub Desktop.
Build Script for Render Pipeline C++ on Windows
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
@echo off | |
REM ROOT | |
REM ├ _cache | |
REM │ ├ yaml-cpp | |
REM │ ├ spdlog | |
REM │ └ flatbuffers | |
REM ├ _install | |
REM │ ├ boost | |
REM │ └ panda3d-thirdparty | |
REM │ └ win-libs-vc14-x64 | |
REM │ └ freetype | |
REM ├ openvr | |
REM ├ render_pipeline_cpp | |
REM ├ rpcpp_plugins | |
REM └ builder.py (https://github.com/bluekyu/render_pipeline_cpp_ci/blob/master/builder.py) | |
set "CMAKE_GENERATOR=Visual Studio 12 2013 Win64" | |
set "CMAKE_PREFIX_PATH=%~dp0_install;%~dp0_cache;" | |
set "BOOST_ROOT=%~dp0_install\boost" | |
set "FREETYPE_DIR=%~dp0_install\panda3d-thirdparty\win-libs-vc12-x64\freetype" | |
set "INSTALL_DIR_PATH=%~dp0_install/render_pipeline_cpp" | |
pushd %~dp0 | |
if exist "%INSTALL_DIR_PATH%" ( rmdir /S /Q "%INSTALL_DIR_PATH%" ) | |
python builder.py "https://github.com/jbeder/yaml-cpp.git" --commit="beb44b87" --cmake-generator="%CMAKE_GENERATOR%" --install-prefix="_cache/yaml-cpp" --hash-path="_cache/yaml-cpp.hash" | |
if exist yaml-cpp ( rmdir /S /Q yaml-cpp ) | |
python builder.py "https://github.com/gabime/spdlog.git" --branch="v0.14.0" --cmake-generator="%CMAKE_GENERATOR%" --install-prefix="_cache/spdlog" --hash-path="_cache/spdlog.hash" | |
if exist spdlog ( rmdir /S /Q spdlog ) | |
python builder.py "https://github.com/google/flatbuffers.git" --branch="v1.7.1" --cmake-generator="%CMAKE_GENERATOR%" --install-prefix="_cache/flatbuffers" --hash-path="_cache/flatbuffers.hash" | |
if exist flatbuffers ( rmdir /S /Q flatbuffers ) | |
REM render_pipeline_cpp | |
set "BUILD_DIR_PATH=%~dp0render_pipeline_cpp/build" | |
if exist "%BUILD_DIR_PATH%" ( rmdir /S /Q "%BUILD_DIR_PATH%" ) | |
mkdir "%BUILD_DIR_PATH%" | |
pushd "%BUILD_DIR_PATH%" | |
cmake -G "%CMAKE_GENERATOR%" -Wno-dev .. -DCMAKE_INSTALL_PREFIX="%INSTALL_DIR_PATH%" -Dpanda3d_ROOT:PATH="%~dp0_install/panda3d" -Dyaml-cpp_DIR:PATH="%~dp0_cache/yaml-cpp/CMake" -DFlatBuffers_ROOT:PATH="%~dp0_cache/flatbuffers" | |
cmake --build . --config "RelWithDebInfo" --target install | |
cmake --build . --config "Release" --target install | |
popd | |
REM rpcpp_plugins | |
set "BUILD_DIR_PATH=%~dp0rpcpp_plugins/build" | |
if exist "%BUILD_DIR_PATH%" ( rmdir /S /Q "%BUILD_DIR_PATH%" ) | |
mkdir "%BUILD_DIR_PATH%" | |
pushd "%BUILD_DIR_PATH%" | |
cmake -G "%CMAKE_GENERATOR%" -Wno-dev .. -DCMAKE_INSTALL_PREFIX="%INSTALL_DIR_PATH%" -Dpanda3d_ROOT:PATH="%~dp0_install/panda3d" -DOpenVR_ROOT:PATH="%~dp0openvr" -Drpcpp_plugins_BUILD_background2d:BOOL=ON -Drpcpp_plugins_BUILD_openvr:BOOL=ON | |
cmake --build . --config "RelWithDebInfo" --target install | |
cmake --build . --config "Release" --target install | |
popd | |
popd |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment