Add my Windows build script for posterity.

Linux/Mac coming shortly.
This commit is contained in:
James Turner 2016-12-10 23:57:11 +00:00
parent c23ec2827f
commit 08cb5c481b
2 changed files with 66 additions and 0 deletions

14
compile-scripts/README.md Normal file
View File

@ -0,0 +1,14 @@
This is the scripts I (James) use to maintain my builds on each platform.
They're much less clever than 'download and compile' but they do enough for me
and probably most other people, if you tweak the paths accordingly. The Mac
and Linux ones require Ruby (which is usually pre-installed). There are no
instructions - if you can't figure out what these do from reading the scripts,
you almost certainly should not be using them!
They all assume a top-level folder (called 'FGFS' in my case) which contains
checkouts of simgear, flightgear, fgdata, OpenSceneGraph (into a dir named
'osg') and the windows-3rd-party dir in the case of Windows. It's assumed
you copy the script to that same dir, edit paths and run from there.
Files will be installed into a subdir called 'dist'

View File

@ -0,0 +1,52 @@
SET PATH=%PATH%;%ProgramFiles%\CMake\bin
SET QT5SDK64=C:\Qt\5.6\msvc2015_64
SET CMAKE_TOOLCHAIN="Visual Studio 14 Win64"
SET ROOT_DIR=%CD%
md osgbuild
md sgbuild
md fgbuild
REM md fgrun-build
cd simgear
git pull --rebase
cd ..\flightgear
git pull --rebase
REM cd ..\fgrun
REM git pull --rebase
cd ..\osgbuild
cmake ..\osg -G %CMAKE_TOOLCHAIN% ^
-DACTUAL_3RDPARTY_DIR:PATH=%ROOT_DIR%\windows-3rd-party\msvc140\3rdparty.x64 ^
-DCMAKE_INSTALL_PREFIX:PATH=%ROOT_DIR%\dist ^
-DOSG_USE_UTF8_FILENAME:BOOL=ON
cmake --build . --config Release --target INSTALL
cmake --build . --config Debug --target INSTALL
cd ..\sgbuild
cmake ..\simgear -G %CMAKE_TOOLCHAIN% ^
-DMSVC_3RDPARTY_ROOT=%ROOT_DIR%\windows-3rd-party\msvc140 ^
-DOSG_FSTREAM_EXPORT_FIXED:BOOL=ON ^
-DCMAKE_INSTALL_PREFIX:PATH=%ROOT_DIR%\dist
cmake --build . --config Release --target INSTALL
cmake --build . --config Debug --target INSTALL
cd ..\fgbuild
cmake ..\flightgear -G %CMAKE_TOOLCHAIN% ^
-DMSVC_3RDPARTY_ROOT=%ROOT_DIR%\windows-3rd-party\msvc140 ^
-DCMAKE_INSTALL_PREFIX:PATH=%ROOT_DIR%\dist ^
-DCMAKE_PREFIX_PATH=%QT5SDK64% ^
-DOSG_FSTREAM_EXPORT_FIXED:BOOL=ON
cmake --build . --config Release --target INSTALL
cmake --build . --config Debug --target INSTALL
REM cd ..\fgrun-build
REM cmake ..\fgrun -G %CMAKE_TOOLCHAIN% ^
REM -DMSVC_3RDPARTY_ROOT=C:\FGFS\windows-3rd-party\msvc140 ^
REM -DCMAKE_INSTALL_PREFIX:PATH=C:\FGFS\dist
REM cmake --build . --config Release --target INSTALL
REM cmake --build . --config Debug --target INSTALL