Skip to content

Building from Source

radj307 edited this page Dec 3, 2022 · 26 revisions

Building ARRCON From Source

Building ARRCON from source is a relatively painless process, and is automated with git submodules.

Prerequisites

  • git
  • CMake v3.22 or newer
  • A C++ Compiler.
    • MSVC 17.0 or newer on Windows
    • gcc-10 or newer on POSIX (Linux/macOS)
  • Ninja

Building The Executable

Short Version

Run the following commands in a terminal:

git clone https://github.com/radj307/ARRCON
cd ARRCON
git submodule update --init --recursive
cmake -B build -DCMAKE_BUILD_TYPE=Release -G Ninja
cmake --build build --config Release

The executable will be located at build/ARRCON/ARRCON (or build/ARRCON/ARRCON.exe on Windows).

Long Version

Using your preferred terminal (or git client), cd to a workspace directory of your choice, then enter the following commands:

  1. First, we'll need a copy of the source code:
    git clone https://github.com/radj307/ARRCON && cd ARRCON

  2. Next we'll need to download the dependencies:
    git submodule update --init --recursive
    Note: If you're using Linux or macOS, you can use this command instead: git submodule update --init --recursive 307lib

  3. Finally, we'll build the executable for your OS using cmake-gui:
    Open cmake-gui:

    If you're using CMake CLI, I'll assume you already know what you're doing & won't spend time writing the same guide twice.

  4. Enter the path to the root ARRCON directory in "Where is the source code"

  5. Create a build output directory: ARRCON/out, and enter its location in "Where to build the binaries"

  6. Next, click Configure and select a compiler.


    Once the configuring step is complete, you should see this message:

    You can ignore any warnings that appear, so long as they aren't errors.

  7. Click Generate to generate the project files using your compiler.

  8. Now we'll open the generated project files using whichever generator you chose in step 6.

  9. Open the project and compile it using your preferred compiler.

Visual Studio

  1. Switch the configuration to Release or MinSizeRel
  2. Then R+Click on the ARRCON project in the solution explorer, and select "Build"
  3. The generated executable will be located in this subdirectory: out/build/<CONFIGURATION>/ARRCON/
Clone this wiki locally