]> git.xonotic.org Git - xonotic/xonotic.wiki.git/commitdiff
Update Shared libraries (buildfiles)
authorz411 <electrik.persona@gmail.com>
Sun, 12 Dec 2021 22:06:37 +0000 (22:06 +0000)
committerz411 <electrik.persona@gmail.com>
Sun, 12 Dec 2021 22:06:37 +0000 (22:06 +0000)
Shared-libraries-(buildfiles).md

index 3afca5071901890b058faca44c3017d50b4c6f28..947c1cfbd7f4416d252321c348d3a6d5a2f83697 100644 (file)
@@ -85,8 +85,23 @@ Required for the Xolonium font
 ### Windows
 Darkplaces loads: `libfreetype-6.dll` or `freetype6.dll`
 
-Obtainment instructions:
-* Download x86 and x64 dlls from: https://github.com/ubawurinna/freetype-windows-binaries
+```
+VER="2.11.1"
+curl -L -o freetype-$VER.tar.xz https://download.savannah.gnu.org/releases/freetype/freetype-$VER.tar.xz || true
+tar -xf freetype-$VER.tar.xz
+rm freetype-$VER.tar.xz
+
+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" -DBUILD_SHARED_LIBS=true -DCMAKE_BUILD_TYPE=Release -DCMAKE_SYSTEM_PROCESSOR=x86_64 -DCMAKE_INSTALL_PREFIX="$d0/out" -G"Unix Makefiles" "$d0/freetype-$VER"
+make
+make install
+cd "$d0"
+cp out/bin/libfreetype.dll ~/Games/xonotic/misc/buildfiles/win64/libfreetype-6.dll
+```
 
 ### macOS
 Darkplaces loads: `libfreetype.6.dylib` or `libfreetype.dylib`