From df724af704d29bf3418a96837f2c902a3c820d63 Mon Sep 17 00:00:00 2001 From: CodingJellyfish Date: Thu, 17 Oct 2024 02:52:03 +0800 Subject: [PATCH] Update install instructions --- INSTALL.md | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/INSTALL.md b/INSTALL.md index 60a9fb7afd..7cdb58766d 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -214,35 +214,32 @@ SuperTuxKart can now be run as `bin\Debug\supertuxkart.exe` or `bin\Release\supe NOTE: the `stk-code` and `stk-assets` directories **must** be in the same directory, `stk-assets` is not needed if you download the full source tarball `(SuperTuxKart-version-src.tar.xz)`. Also make sure they lie within the C drive. 4. Download the Windows dependencies package from [SuperTuxKart on GitHub - Dependencies latest preview release](https://github.com/supertuxkart/dependencies/releases/tag/preview) and unpack the archive into the `stk-code` directory. Download `i686` if you compile for Intel / AMD 32-bit, `x86_64` for Intel / AMD 64-bit, `armv7` for ARM 32-bit and `aarch64` for ARM 64-bit version of Windows. -6. Download CMake from here: [CMake - download page](https://cmake.org/download/), install it; once CMake is installed, double click on the CMake icon on your desktop, and point it towards your `stk-code` directory in the 'Where is the source code' field, and point 'Where to build the binaries' to a new directory called `build` inside the stk-code directory. -7. Press the `Add Entry` button and add the values below: +5. Download CMake from here: [CMake - download page](https://cmake.org/download/), install it; once CMake is installed, double click on the CMake icon on your desktop, and point it towards your `stk-code` directory in the 'Where is the source code' field, and point 'Where to build the binaries' to a new directory called `build` inside the stk-code directory. +### For cmake-gui +6. Press the `Add Entry` button and add the values below: * Name: `LLVM_ARCH` Type: `STRING` Value: `i686`, `x86_64`, `armv7` or `aarch64` * Name: `LLVM_PREFIX` Type: `STRING` Value: `C:/llvm-mingw` * Name: `CMAKE_MAKE_PROGRAM` Type: `STRING` Value: `C:/llvm-mingw/ninja.exe` * Name: `USE_WIIUSE` Type: `BOOL` Value: `Empty (unchecked)` -8. Press 'Configure'; CMake will ask you if it is OK to create the aforementioned directory, press `Yes`. Choose `Ninja` from `Specify the generator for this project`, choose `Specify toolchain file for cross-compiling` then press `Next`. Specify the toolchain file which is located in `stk-code\cmake\Toolchain-llvm-mingw.cmake` and press `Finish`. If no error appears then press 'Generate' -9. Once inside the build directory using command line `cmd.exe` or PowerShell: +7. Press 'Configure'; CMake will ask you if it is OK to create the aforementioned directory, press `Yes`. Choose `Ninja` from `Specify the generator for this project`, choose `Specify toolchain file for cross-compiling` then press `Next`. Specify the toolchain file which is located in `stk-code\cmake\Toolchain-llvm-mingw.cmake` and press `Finish`. If no error appears then press 'Generate' +8. Once inside the build directory, run the build command using command line `cmd.exe` or PowerShell: ```cmd C:\llvm-mingw\ninja.exe ``` +SuperTuxKart can now be run as `bin\supertuxkart.exe`. -### Building SuperTuxKart on Windows using LLVM MinGW (from PowerShell/Command line) - -Do the above steps 1 to 6 to setup the required dependencies. - -7. Once inside the build directory; run CMake to start the compilation process: +### For PowerShell/Command Prompt +6. Once inside the build directory, run the cmake command using command line `cmd.exe` or PowerShell: ```cmd cmake .. -G Ninja -DLLVM_ARCH="x86_64" -DLLVM_PREFIX=C:\llvm-mingw -DCMAKE_MAKE_PROGRAM=C:\llvm-mingw\ninja.exe -DUSE_WIIUSE=OFF -DCMAKE_TOOLCHAIN_FILE="../cmake/Toolchain-llvm-mingw.cmake" ``` - -2. Now that CMake finished configuring and creating the necessary files for the build, run the build command in the same directory: +7. Run the build command in the same directory: ```cmd C:\llvm-mingw\ninja.exe ``` - SuperTuxKart can now be run as `bin\supertuxkart.exe`. ## Building SuperTuxKart on macOS