libjpeg-turbo is needed to display jpeg images/textures
### Windows
-Darkplaces loads `libjpeg.dll`
-Obtainment instructions:
-* download `libjpeg-turbo-VERSION-vc.exe` & `libjpeg-turbo-VERSION-vc64.exe` from https://sourceforge.net/projects/libjpeg-turbo/files/
-* extract the *.exe files and use `bin/jpeg62.dll`
-* rename the dlls (x64 & x86) to `libjpeg.dll`
+```
+set -ex
+git clone https://github.com/libjpeg-turbo/libjpeg-turbo.git || true
+curl -o x86_64-w64-mingw32.cmake https://raw.githubusercontent.com/zyga/cmake-toolchains/master/Toolchain-Ubuntu-mingw64.cmake
+d0=$(pwd)
+rm -rf build
+mkdir build
+cd build
+cmake -DCMAKE_TOOLCHAIN_FILE="$d0/x86_64-w64-mingw32.cmake" -DCMAKE_SYSTEM_PROCESSOR=x86_64 -DCMAKE_INSTALL_PREFIX="$d0/out" -G"Unix Makefiles" "$d0/libjpeg-turbo"
+make
+make install
+cd "$d0"
+cp out/bin/libjpeg-62.dll ~/Games/xonotic/misc/buildfiles/win64/libjpeg.dll
+```
### macOS
Darkplaces loads `libjpeg.62.dylib`