Sign inSign up

nukla/dp2compile

By nukla

Updated about 4 years ago

Docker based environment to compile the Linux version of Digital Paintball 2

Image
0

221

nukla/dp2compile repository overview

This image was made to download and compile the Linux version of the game Digital Paintball 2 without installing an old Linux VM or painfully figuring out what development libraries need to be installed.

Usage

First, create the directories that will hold the source code and the final build (as your normal user, not root):

mkdir /path/to/code/
mkdir /path/to/build/

Then, use the image to download the source code:

sudo docker run -v /path/to/code/:/code/ -v /path/to/build/:/build/ nukla/dp2compile download

The code can now be found and modified in /path/to/code/

And finally, build it:

sudo docker run -v /path/to/code/:/code/ -v /path/to/build/:/build/ nukla/dp2compile make release

Don't panic if it actually succeeds. The binaries will be in /path/to/build/

Fixing compilation issues

Right now (2021-08-05), the compiler will probably complain about undefined references to pthread functions. To fix this, replace the line LDFLAGS+= -ldl -lrt with LDFLAGS+= -ldl -lrt -pthread in /path/to/code/paintball2-code/trunk/paintball2/makefile

More options

Use sudo docker run nukla/dp2compile help to get a list of possible commands:

Usage: "/usr/bin/builder.sh" <argument>

Possible arguments:
download            Download the source code
make <target>       Build the source code. Just runs 'make <target>' in the container
clean               Remove the compiled binaries. Just runs 'make clean'
shell               Launch an interactive shell (bash) in the container

For example to launch an interactive shell inside the container (to install other libraries or something):

sudo docker run -it -v /path/to/code/:/code/ -v /path/to/build/:/build/ nukla/dp2compile shell

Dockerfile

Read the Dockerfile here: https://gitlab.com/nukla/paintball2-compile-linux

Tag summary

Content type

Image

Digest

sha256:e4cbd6ffc

Size

204.4 MB

Last updated

about 4 years ago

docker pull nukla/dp2compile