This page outlines procedures for compiling SpMp from its source code. For installing from pre-compiled packages, see Installation.

Requirements

All platforms:
Linux (for packaging AppImage):

Downloading source code

From a command-line terminal:

  1. Clone the SpMp Git repository and its submodules git clone https://github.com/toasterofbread/spmp --recurse-submodules

  2. Enter the cloned directory cd spmp

Compiling

Android

Gradle command: androidApp:packageRelease (Debug: androidApp:packageDebug)

To build separate APKs for each CPU architecture instead of a single universal APK, add the argument -PenableApkSplit to the Gradle command.

Compiled APK(s) will be stored in androidApp/build/outputs/apk/.

Linux

Gradle command: desktopApp:packageReleaseAppImage (Debug: desktopApp:packageAppImage)

The AppImage will be packaged into desktopApp/build/.

Windows

Gradle command: desktopApp:packageReleaseExe (Debug: desktopApp:packageExe)

The installer executable will be packaged into desktopApp/build/compose/binaries/.

Packaging with SpMs

Prerequisites

Before starting, follow the instructions for compiling SpMs up to (but not including) running the final Gradle command. However, instead of cloning the SpMs repository, perform the steps within the spmp-server submodule directory within the SpMp source code.

Packaging

To include an spmp-server executable in a desktop SpMp package (this is the default for releases of SpMp), append the Gradle build command with WithServer. For example, to build a release AppImage packaged with the server, run the task desktopApp:packageReleaseAppImageWithServer.