|
|
@@ -1,62 +1,44 @@ |
|
|
|
# izanagi |
|
|
|
|
|
|
|
A run-and-gun shooter inspired by Metal Slug. |
|
|
|
A run-and-gun shooter inspired by Metal Slug and Counter-Strike. |
|
|
|
|
|
|
|
## Setup |
|
|
|
|
|
|
|
> **Note:** CMake and OpenSSL are required. |
|
|
|
The following tools are required: |
|
|
|
|
|
|
|
* CMake |
|
|
|
* Ninja |
|
|
|
* Clang |
|
|
|
* [Windows SDK](https://developer.microsoft.com/en-us/windows/downloads/windows-sdk/) (Windows) |
|
|
|
* `autoconf` (macOS/*NIX) |
|
|
|
* `make` (macOS/*NIX) |
|
|
|
* `libtool` (*NIX) |
|
|
|
|
|
|
|
For Windows and macOS, it is recommended to use Chocolatey and Homebrew respectively, for retrieving the required tools. |
|
|
|
|
|
|
|
For *NIX, use whatever dependency manager you prefer to obtain the needed tools. |
|
|
|
|
|
|
|
### Windows |
|
|
|
|
|
|
|
The following tools are required: |
|
|
|
1. Ensure your environment variables are set up. |
|
|
|
|
|
|
|
* [Windows SDK](https://developer.microsoft.com/en-us/windows/downloads/windows-sdk/) |
|
|
|
> **Important:** Set your `CC` environment variable to the full path of `clang-cl.exe` |
|
|
|
|
|
|
|
These required tools may be installed via Chocolatey (recommended): |
|
|
|
> **Important:** Set your `CMAKE_MT` environment variable to the full path of `mt.exe`, which can be found on your |
|
|
|
> Windows SDK installation folder (usually `C:/Program Files (x86)/Windows Kits/10/bin/10.0.19041.0/x86/mt.exe`) |
|
|
|
|
|
|
|
* CMake |
|
|
|
* Ninja |
|
|
|
* Clang |
|
|
|
> Set your `CC` environment variable to the full path of `clang-cl.exe` |
|
|
|
|
|
|
|
> Set your `CMAKE_MT` environment variable to the full path of `mt.exe`, which can be found on your Windows SDK |
|
|
|
> installation folder (usually `C:/Program Files (x86)/Windows Kits/10/bin/10.0.19041.0/x86/mt.exe`) |
|
|
|
|
|
|
|
> **Note:** The CMake cache might be filled in with library paths that might be unknown when Visual Studio is installed. |
|
|
|
> It will cause errors in building. Run the scripts provided in this project to ensure that the correct library paths |
|
|
|
> are supplied. |
|
|
|
|
|
|
|
1. Clone this repo. |
|
|
|
2. Clone the repositories under `dependencies.txt` except for SDL2. |
|
|
|
3. Unpack the **MSVC** archive under `dependencies` folder in this project's root. Rename the directory as `SDL2`. |
|
|
|
4. Build the following dependencies first: |
|
|
|
- `portmidi` |
|
|
|
- `libwebsockets` (follow the [instructions on building LWS](https://libwebsockets.org/lws-api-doc-master/html/md_README_8build.html)) |
|
|
|
5. Build via CMake. |
|
|
|
2. Clone this repo recursively. |
|
|
|
3. Build the dependencies under `subprojects`. Follow the instructions on building for Visual C. |
|
|
|
|
|
|
|
> **Important:** For `libwebsockets`, follow the [instructions on building LWS](https://libwebsockets.org/lws-api-doc-master/html/md_README_8build.html). |
|
|
|
|
|
|
|
4. Generate the CMake cache. |
|
|
|
5. Build the specific executables you want to build, which are defined in `CMakeLists.txt`. |
|
|
|
|
|
|
|
### macOS/*NIX |
|
|
|
|
|
|
|
1. Clone this repo. |
|
|
|
2. Clone the repositories under `dependencies.txt`, including SDL2. |
|
|
|
3. Build the SDL, SDL_image, and SDL_ttf dependencies using the [build instructions for Linux/UNIX](https://wiki.libsdl.org/SDL2/Installation#linuxunix) |
|
|
|
or [build instructions for macOS](https://wiki.libsdl.org/SDL2/Installation#macos). |
|
|
|
> **Note:** You may need to download other tools to build the libraries: |
|
|
|
> - autoconf |
|
|
|
> - make |
|
|
|
|
|
|
|
> **Note:** Clone the submodules under SDL_ttf to download freetype and harfbuzz: |
|
|
|
> |
|
|
|
> ```shell |
|
|
|
> git submodule update --init --recursive |
|
|
|
> ``` |
|
|
|
4. For OpenSSL, simply run: |
|
|
|
```shell |
|
|
|
./Configure |
|
|
|
make |
|
|
|
make test |
|
|
|
``` |
|
|
|
5. Build the following dependencies first: |
|
|
|
- `portmidi` (Linux needs [ALSA libraries](https://www.alsa-project.org/files/pub/lib/) to be compiled) |
|
|
|
- ALSA Lib requires `libtool` to be compiled. |
|
|
|
- `libwebsockets` (follow the [instructions on building LWS](https://libwebsockets.org/lws-api-doc-master/html/md_README_8build.html)) |
|
|
|
6. Build via CMake. |
|
|
|
1. Clone this repo recursively. |
|
|
|
2. Build the dependencies under `subprojects`. Follow the instructions on building for *NIX (macOS should have similar |
|
|
|
instructions for *NIX). |
|
|
|
3. Generate the CMake cache. |
|
|
|
4. Build the specific executables you want to build, which are defined in `CMakeLists.txt`. |