From ef25ea023e8f110d4633633f966b4c4907455f9b Mon Sep 17 00:00:00 2001 From: Kowalski Dragon Date: Thu, 23 Dec 2021 16:41:10 +0100 Subject: [PATCH] Decouple Readme from Linux building instructions --- Platform/Linux/BUILD.md | 25 +++++++++++++++++++++++++ README.md | 24 ++---------------------- 2 files changed, 27 insertions(+), 22 deletions(-) create mode 100644 Platform/Linux/BUILD.md diff --git a/Platform/Linux/BUILD.md b/Platform/Linux/BUILD.md new file mode 100644 index 0000000..f235b6e --- /dev/null +++ b/Platform/Linux/BUILD.md @@ -0,0 +1,25 @@ +# Building + +Install devel packages for `SDL2` and `SDL2_mixer`.\ + +Compile with CMake; tested with GCC 10, Clang 11.\ +To cross-compile for Windows, install a 64-bit version of mingw and its `SDL2` and `SDL2_mixer` distributions, then use the `mingwcc.cmake` toolchain. + +```bash +# On Debian and Ubuntu +sudo apt install cmake build-essential ninja-build libsdl2-dev libsdl2-mixer-dev libsdl2-mixer-2.0-0 libsdl2-2.0-0 fluidsynth + +# On Fedora +sudo dnf install cmake ninja-build SDL2 SDL2-devel SDL2_mixer SDL2_mixer-devel fluidsynth fluidsynth-libs mscore-fonts g++ + +# Build +cmake -GNinja . +ninja +``` + +**If you can't hear the background music**: You need to export the following variable before launching the game like this: +`export SDL_SOUNDFONT=/path/to/your/soundfont` + +Fluidsynth will install a default soundfont in the following path: +On Fedora: `/usr/share/soundfonts/FluidR3_GM.sf2` +On Ubuntu/Debian: `/usr/share/sounds/sf2/FluidR3_GM.sf2` diff --git a/README.md b/README.md index 8e4bd22..81e61b8 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ ## Summary -Reverse engineering of `3D Pinball for Windows – Space Cadet`, a game bundled with Windows. +Reverse engineering of `3D Pinball for Windows - Space Cadet`, a game bundled with Windows. ## How to play @@ -60,33 +60,13 @@ Compile with Visual Studio; tested with 2019. ### On Linux Install devel packages for `SDL2` and `SDL2_mixer`.\ - Compile with CMake; tested with GCC 10, Clang 11.\ To cross-compile for Windows, install a 64-bit version of mingw and its `SDL2` and `SDL2_mixer` distributions, then use the `mingwcc.cmake` toolchain. -```bash -# On Debian and Ubuntu -sudo apt install cmake build-essential ninja-build libsdl2-dev libsdl2-mixer-dev libsdl2-mixer-2.0-0 libsdl2-2.0-0 fluidsynth - -# On Fedora -sudo dnf install cmake ninja-build SDL2 SDL2-devel SDL2_mixer SDL2_mixer-devel fluidsynth fluidsynth-libs mscore-fonts g++ - -# Build -cmake -GNinja . -ninja -``` - -[![Packaging status](https://repology.org/badge/tiny-repos/spacecadetpinball.svg)](https://repology.org/project/spacecadetpinball/versions) +[![Packaging status](https://repology.org/badge/tiny-repos/spacecadetpinball.svg)](https://repology.org/project/spacecadetpinball/versions) Some distributions provide a package in their repository. You can use those for easier dependency management and updates. -**If you can't hear the background music**: You need to export the following variable before launching the game like this: -`export SDL_SOUNDFONT=/path/to/your/soundfont` - -Fluidsynth will install a default soundfont in the following path: -On Fedora: `/usr/share/soundfonts/FluidR3_GM.sf2` -On Ubuntu/Debian: `/usr/share/sounds/sf2/FluidR3_GM.sf2` - ### On macOS * **Homebrew**: Install the `SDL2`, `SDL2_mixer` homebrew packages.