Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @echo off
- rem http://vijay.axham.com/blog/498/building-ogre3d-1-8-1-on-mingw
- rem http://forums.qhimm.com/index.php?topic=15060.0
- set home=%cd%
- set "path=%home%\cmake-2.8.11.2-win32-x86\bin;%path%"
- @echo Fetch the source code.
- set "hg_url=ssh://hg@bitbucket.org/sinbad/ogre -u v1-8"
- set "OGRE_SOURCE_DIR=%home%\ogre\v1-8"
- mkdir "%OGRE_SOURCE_DIR%"
- cd /D %OGRE_SOURCE_DIR%
- hg clone %hg_url%
- cd /D %home%
- set "OGRESDK_SOURCE_DIR=%OGRE_SOURCE_DIR%\ogre"
- @echo We need to tell Ogre where boost is:
- rem set "BOOST_ROOT=%home%"
- rem set "BOOST_INCLUDEDIR=%home%\boost_1_54_0"
- rem set "BOOST_LIBRARYDIR=%home%\boost_1_54_0\stage\lib"
- call %home%\boost_root.bat
- @echo And where the dependencies are:
- rem set "OGRE_DEPENDENCIES_DIR=%home%\build\install\ogredeps"
- call %home%\ogredeps_home.bat
- @echo Set up some environment vars for build and install locations:
- set "BUILD_OUTPUT_DIR=%home%\build\output"
- set "OGRE_OUTPUT_DIR=%BUILD_OUTPUT_DIR%\ogre\v1-8"
- set "OGRESDK_OUTPUT_DIR=%OGRE_OUTPUT_DIR%\ogre"
- set "BUILD_INSTALL_DIR=%home%\build\install"
- set "OGRESDK_INSTALL_DIR=%BUILD_INSTALL_DIR%\ogre"
- mkdir "%OGRESDK_OUTPUT_DIR%"
- cd /D %OGRESDK_OUTPUT_DIR%
- @echo if youβre using MinGW without MSYS:
- echo :Start of Log: > %home%\ogre.log
- set "CMAKE_BUILD_TYPE=Debug"
- :afterbuildtype
- cmake "%OGRESDK_SOURCE_DIR%" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE:STRING="%CMAKE_BUILD_TYPE%" >> %home%\ogre.log
- rem -j makes things go faster but uses 100% cpu
- mingw32-make >> %home%\ogre.log
- mkdir "%BUILD_INSTALL_DIR%"
- mingw32-make install >> %home%\ogre.log
- rem move /Y sdk "%OGRESDK_INSTALL_DIR%"
- robocopy sdk "%OGRESDK_INSTALL_DIR%" /E /IS /MOVE
- if not %CMAKE_BUILD_TYPE% == Release (
- set "CMAKE_BUILD_TYPE=Release"
- goto afterbuildtype
- )
- cd /D %home%
- @echo set "OGRE_HOME=%OGRESDK_INSTALL_DIR%" > %home%\ogre_home.bat
- @echo setx OGRE_HOME %OGRESDK_INSTALL_DIR% >> %home%\ogre_home.bat
- call %home%\ogre_home.bat
- echo You may need to reboot to for code blocks to find ogre.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement