Changes between Version 379 and Version 380 of BuildInstructions
- Timestamp:
- Nov 30, 2020, 10:12:59 AM (3 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
BuildInstructions
v379 v380 16 16 * [#Windows Windows] (7 or newer) 17 17 * [#Linux Linux] 18 * [#OSX macOS / OS X] (10. 7/Lionor newer)18 * [#OSX macOS / OS X] (10.13/High Sierra or newer) 19 19 * [#BSD FreeBSD/OpenBSD] (only experimental support at this time) 20 20 * Up-to-date system software (Windows service packs, graphics driver updates, etc) … … 31 31 Libraries are external dependencies (such as SpiderMonkey). For Windows and Linux, the script to create or update the Workspaces also handles installation and updating of libraries. For macOS, the `libraries/osx/build-osx-libs.sh` script should be used instead. 32 32 33 Workspaces contain the integrations for code editors (such as Visual Studio, Xcode, etc.) as well as the Makefile for the main source code. The workspaces are auto-generated by the `update-workspaces` script from the `buids/workspaces/` directory. Once ready, the integrations are ready for use, such as `build/workspaces/gcc/Makefile` (for Linux and macOS) and `build\workspaces\v c2015` (for Windows).33 Workspaces contain the integrations for code editors (such as Visual Studio, Xcode, etc.) as well as the Makefile for the main source code. The workspaces are auto-generated by the `update-workspaces` script from the `buids/workspaces/` directory. Once ready, the integrations are ready for use, such as `build/workspaces/gcc/Makefile` (for Linux and macOS) and `build\workspaces\vs2017` (for Windows). 34 34 35 35 Finally, the source code is build by the workspace. For example, by running `make` in `build/workspaces/gcc`. … … 45 45 If you want to develop, the only supported IDE is: 46 46 47 * Visual C++ 201 547 * Visual C++ 2017 48 48 49 49 '''Important notes:''' 50 50 51 * We have dropped support for older versions of Visual Studio when moving to C++1 1, see #2669.52 * XP and Vista are supported as targets, but not for installing Visual Studio 201 5.51 * We have dropped support for older versions of Visual Studio when moving to C++14, see #5862. 52 * XP and Vista are supported as targets, but not for installing Visual Studio 2017. 53 53 * Only 32-bit builds are supported, though they can be compiled and run on 64-bit Windows. 54 54 … … 58 58 59 59 === Setting up the build environment === 60 The game must be compiled with Microsoft Visual C++. You can get the free 201 5 Community edition here: [https://www.visualstudio.com/vs/older-downloads/ Visual Studio older downloads]. You can also install Visual Studio 2017/2019 and choose to install the 2015 compiler (version 14.0). When choosing Visual Studio 2019, firstly Visual Studio 2015 have to be installed to be able to select the 2015 compiler.60 The game must be compiled with Microsoft Visual C++. You can get the free 2017 Community edition here: [https://www.visualstudio.com/vs/older-downloads/ Visual Studio older downloads]. You can also install Visual Studio 2019 and choose to install the 2017 compiler (version 14.0). 61 61 62 62 The Visual Studio project/solution files are automatically generated from the source files: 63 63 64 64 * Run `cd build\workspaces` and then [source:/ps/trunk/build/workspaces/update-workspaces.bat update-workspaces.bat]. 65 * Open `build\workspaces\v c2015\pyrogenesis.sln`.65 * Open `build\workspaces\vs2017\pyrogenesis.sln`. 66 66 67 67 === Build configuration === … … 95 95 First you need to install various standard tools and development libraries: 96 96 97 * a C++17 conforming compiler 98 * the rust compiler and toolchain 97 99 * Boost (at least 1.57 since r21726) 98 100 * CMake (only needed if you use bundled NVTT) 99 * GCC (at least 4.8.1, required by C++11 features)100 101 * Python 2.7 (required for cxxtest and non-system SpiderMonkey 45) 101 102 * libcurl (at least 7.32) … … 142 143 * `./update-workspaces.sh --with-system-nvtt` 143 144 * If the game crashes at startup (#5757), you might need to use the bundled NVTT instead of the system-provided one: see below. 144 * If you want to use a packaged ** mozjs45**, which will be made available for example in [https://launchpad.net/~wfg/+archive/ubuntu/0ad.dev/+packages 0ad.dev PPA]:145 * you should add `libmozjs- 45-dev` and run `update-workspace.sh` with `--with-system-mozjs45`.145 * If you want to use a packaged **SpiderMonkey**, which will be made available for example in [https://launchpad.net/~wfg/+archive/ubuntu/0ad.dev/+packages 0ad.dev PPA]: 146 * you should add `libmozjs-68-dev` and run `update-workspace.sh` with `--with-system-mozjs`. 146 147 * When not using system nvidia-texture-tools, `libnvtt-dev` can be omitted, but `cmake` is needed to build the bundled NVTT. 147 148 * You can also use `libcurl4-openssl-dev` instead of `libcurl4-gnutls-dev` (it's not possible to install both at once), but [http://lintian.debian.org/tags/possible-gpl-code-linked-with-openssl.html note that openssl is not GPL compatible and the resulting binaries could not be redistributed]. … … 422 423 423 424 === Dependencies === 424 1. '''Apple Command Line Tools for Xcode'''. There are a number of command-line tools you need that are not installed on macOS by default. Instead, these are available as a separate free download from Apple. '''This does not include or require Xcode.''' It is branded as "for Xcode" but it works by itself. 425 * If you're using macOS 10.7 Lion or later, install this package from [https://developer.apple.com/downloads/index.action Apple Developer Downloads]. You need a (free) Apple ID to access the download. 426 * See [https://developer.apple.com/library/archive/technotes/tn2339/_index.html Apple Command Line FAQ] for additional instructions. 427 2. Python 2.7.3 or later If you're on Mountain Lion (10.8) or earlier, you will need to first update your Python installation with the latest 2.7.x installer from [https://www.python.org/downloads/release/python-279/ here]. 425 1. Install Xcode, version 10.1+ is recommended. Only 10.13+ are supported to compile the game. 426 2. Install the command line tools for Xcode: 427 * Open a Terminal window and enter `xcode-select --install`. 428 2. Install the rust toolchain. 429 * Open a Terminal window and enter `curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh`. 430 * See https://www.rust-lang.org/tools/install for more information. 428 431 3. CMake: 429 * If you have [https://brew.sh/ Homebrew] installed, use [https://brewformulas.org/Cmake `brew install cmake`].432 * (recommended) If you have [https://brew.sh/ Homebrew] installed, use [https://brewformulas.org/Cmake `brew install cmake`]. 430 433 * Alternatively, download a prebuilt macOS package at https://cmake.org/download/. If prompted, choose to install the "CMake command line tools" to the **default location**. 431 434 * '''Note:''' Recent versions have no installer, so after copying the app bundle to '''Applications''', you need to run CMake with elevated permissions to install the command line tools. From the terminal: `sudo "/Applications/CMake.app/Contents/bin/cmake-gui" --install`. … … 468 471 binaries/system/pyrogenesis 469 472 }}} 470 * '''Note:''' Newer versions of Xcode no longer include the command line tools by default, you need to install them as described above.471 * '''Note:''' It is recommended to use the command line build, since the Xcode build is not as well-tested, but Xcode's IDE can be very useful for code editing.472 473 473 474 == Create macOS distributable app bundle == 475 '''This is outdated and will soon change.''' 476 474 477 * You will need Xcode installed (for its SDKs) 475 478 * Open [source:/ps/trunk/build/workspaces/build-osx-bundle.sh build/workspaces/build-osx-bundle.sh] and read the comments. You will need to change a few settings depending on your version of macOS, Xcode, etc. … … 543 546 544 547 === OpenBSD === 545 * As we require GCC 4.8.1+ you need to set `CC` and `CXX` before building548 * You need to set `CC` and `CXX` before building 546 549 {{{ 547 550 #!sh