shithub: cstory

Download patch

ref: a70b4e444eee4273035623c8d430f8b74d6cc7ab
parent: efa987d7ada94e605a5e9625dc95c78d3d376dbf
author: Clownacy <Clownacy@users.noreply.github.com>
date: Sat Mar 14 15:42:58 EDT 2020

Add CMake info to the readme

--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -4,7 +4,7 @@
 
 option(JAPANESE "Enable the Japanese-language build (instead of the unofficial Aeon Genesis English translation)" OFF)
 option(FIX_BUGS "Fix various bugs in the game" OFF)
-option(DEBUG_SAVE "Re-enable the ability to drag-and-drop save files onto the window" OFF)
+option(DEBUG_SAVE "Re-enable the dummied-out 'Debug Save' option, and the ability to drag-and-drop save files onto the window" OFF)
 
 option(LTO "Enable link-time optimisation" OFF)
 option(NATIVE_OPTIMIZATIONS "Enable processor-specific optimisations (executable might not work on other architectures) (GCC-compatible compilers only)" OFF)
--- a/README.md
+++ b/README.md
@@ -46,6 +46,37 @@
 
 Project files for Visual Studio 2017 can be found in the 'vs2017' folder.
 
+### CMake (Visual Studio & MinGW-w64)
+
+In this folder, create another folder called 'build', then switch to the command-line (Visual Studio users should open the [Developer Command Prompt](https://docs.microsoft.com/en-us/dotnet/framework/tools/developer-command-prompt-for-vs)) and `cd` into it. After that, generate the files for your build system with:
+
+```
+cmake .. -DCMAKE_BUILD_TYPE=Release
+```
+
+You can also add the following flags:
+
+Name | Function
+--------|--------
+`-DLTO=ON` | Enable link-time optimisation
+`-DNATIVE_OPTIMIZATIONS=ON` | Enable processor-specific optimisations (executable might not work on other architectures) (GCC-compatible compilers only)
+`-DJAPANESE=ON` | Enable the Japanese-language build (instead of the unofficial Aeon Genesis English translation)
+`-DFIX_BUGS=ON` | Fix various bugs in the game
+`-DDEBUG_SAVE=ON` | Re-enable the dummied-out 'Debug Save' option, and the ability to drag-and-drop save files onto the window
+`-DWARNINGS=ON` | Enable common compiler warnings (for GCC-compatible compilers and MSVC only)
+`-DWARNINGS_ALL=ON` | Enable ALL compiler warnings (for Clang and MSVC only)
+`-DWARNINGS_FATAL=ON` | Stop compilation on any compiler warning (for GCC-compatible compilers and MSVC only)
+
+Then compile CSE2 with this command:
+
+```
+cmake --build . --config Release
+```
+
+If you're a Visual Studio user, you can open the generated `CSE2.sln` file instead.
+
+Once built, the executable can be found in the `game_english`/`game_japanese` folder, depending on the selected language.
+
 ### Makefile (MinGW-w64)
 
 Run 'make' in this folder, preferably with some of the following settings: