aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorXavier Del Campo Romero <xavi.dcr@tutanota.com>2022-06-19 03:09:28 +0200
committerXavier Del Campo Romero <xavi.dcr@tutanota.com>2022-06-19 03:09:28 +0200
commit7c1795401be49831b6601ad31632ffe55c29c8f7 (patch)
treea75d04fb10f46471790e96413394202bea9fa01a /README.md
parent3cb276b19fa21699aa7241956f5b11d1d5b24fe3 (diff)
downloadrts-7c1795401be49831b6601ad31632ffe55c29c8f7.tar.gz
Deprecate <TARGET>_BUILD in favor of CMAKE_TOOLCHAIN_FILE
Diffstat (limited to 'README.md')
-rw-r--r--README.md30
1 files changed, 24 insertions, 6 deletions
diff --git a/README.md b/README.md
index c83d2bb..0802e07 100644
--- a/README.md
+++ b/README.md
@@ -34,6 +34,8 @@ hardware.
## Building from source
+### Native build
+
A native version of **RTS** can be built using the typical CMake build
process:
@@ -41,21 +43,25 @@ process:
mkdir build
cd build
cmake ..
+make -j$(nproc --all)
```
-The following options can be otherwise defined:
+### Cross-compilation
+
+[`CMAKE_TOOLCHAIN_FILE`](https://cmake.org/cmake/help/latest/variable/CMAKE_TOOLCHAIN_FILE.html)
+can be used to set up the cross-toolchain. Files labeled as
+`cmake/*-toolchain.cmake` can be used as values.
-- `PS1_BUILD`: builds for Sony Playstation 1
-- `HOST_BUILD`: builds for the host operating system using SDL-1.2
-- `WIN9X_BUILD`: builds for Microsoft Win9x operating systems using
-SDL-1.2. A `i386-mingw32` cross-toolchain must be available.
+#### Sony PlayStation 1
For example, the Sony PlayStation 1 version can be built using:
```sh
mkdir build
cd build
-cmake .. -DPS1_BUILD=1 -DVIDEO_MODE=VMODE_PAL
+cmake .. \
+ -DCMAKE_TOOLCHAIN_FILE=../cmake/ps1-toolchain.cmake \
+ -DVIDEO_MODE=VMODE_PAL # VMODE_NTSC can be otherwise used
make -j$(nproc --all)
```
@@ -63,6 +69,18 @@ This will generate a `.bin`/`.cue` file pair in `build` that can be
played on an emulator or burnt into a CD-r in order to play the game
on real hardware.
+#### Microsoft Win9x
+
+```sh
+mkdir build
+cd build
+cmake .. -DCMAKE_TOOLCHAIN_FILE=../cmake/win9x-toolchain.cmake
+make -j$(nproc --all)
+```
+
+A stripped version of the executable, as well as game assets, will be
+located in `build/cdimg`.
+
## License
Unless stated otherwise, **RTS** follows the license described by the