Difference between revisions of "Compiling ScummVM/MinGW-w64"

Jump to navigation Jump to search
→‎Setup MinGW-w64 and MSYS2: Added libmikmod to library packages downloaded with pacman
m
(→‎Setup MinGW-w64 and MSYS2: Added libmikmod to library packages downloaded with pacman)
 
(7 intermediate revisions by 3 users not shown)
Line 13: Line 13:
You can find [https://www.msys2.org/ MSYS2 on the official webpage] and detailed installation instructions on the [https://github.com/msys2/msys2/wiki/MSYS2-installation MSYS2 github wiki].
You can find [https://www.msys2.org/ MSYS2 on the official webpage] and detailed installation instructions on the [https://github.com/msys2/msys2/wiki/MSYS2-installation MSYS2 github wiki].


The MinGW packages are named mingw-<env>-<package>, where <env> is either x86_64 or i686, depending on your architecture (64-bit and 32-bit, respectively).
The MinGW packages are named <code>mingw-<env>-<package></code>, where <code><env></code> is either x86_64 or i686, depending on your architecture (64-bit and 32-bit, respectively).


To create an i686 or x86_64 build environment, we need to first update the already installed packages and the MSYS2 environment itself.
To create an i686 or x86_64 build environment, we need to first update the already installed packages and the MSYS2 environment itself.
Line 23: Line 23:
Follow the instructions (one upgrade step may require that the MSYS2 terminal window is closed directly from the window's e(X)it button on the top right. Keep issuing the above command in the MSYS2 terminal until there's no more updating tasks to be done.
Follow the instructions (one upgrade step may require that the MSYS2 terminal window is closed directly from the window's e(X)it button on the top right. Keep issuing the above command in the MSYS2 terminal until there's no more updating tasks to be done.


For i686 (32-bit executable and MinGW), type the following in the MSYS2 terminal to automatically install all packages/libraries needed to compile ScummVM:
In order to install all required tools and libraries, open the MinGW shell matching the architecture you want to build for (32 or 64 bits) and use the following command:
<syntaxhighlight lang="bash">
<syntaxhighlight lang="bash">
pacman -S --needed --noconfirm base-devel git mingw-w64-i686-{a52dec,ccache,cairo,curl-winssl,faad2,freetype,flac,fluidsynth,fribidi,glew,libjpeg-turbo,libogg,libvorbis,libmad,libmpeg2-git,libtheora,libpng,nasm,readline,SDL2,SDL2_net,toolchain,winsparkle,zlib,ntldd-git}
pacman -S --needed --noconfirm base-devel git ${MINGW_PACKAGE_PREFIX}-{a52dec,binutils,ccache,cairo,curl-winssl,faad2,freetype,flac,fluidsynth,fribidi,libjpeg-turbo,libogg,libvorbis,libvpx,libmad,libmpeg2-git,libtheora,libpng,lld,nasm,readline,SDL2,SDL2_net,toolchain,winsparkle,zlib,ntldd-git,libmikmod}
</syntaxhighlight>
</syntaxhighlight>


For x86_64 (64-bit executable and MinGW), type the following in the MSYS2 terminal to automatically install all packages/libraries needed to compile ScummVM:
These commands will fetch and install the packages needed for compiling, including (but not limited to) GCC 12.x, GDB, and libwinpthread-git.
<syntaxhighlight lang="bash">
pacman -S --needed --noconfirm base-devel git mingw-w64-x86_64-{a52dec,ccache,cairo,curl-winssl,faad2,freetype,flac,fluidsynth,fribidi,glew,libjpeg-turbo,libogg,libvorbis,libmad,libmpeg2-git,libtheora,libpng,nasm,readline,SDL2,SDL2_net,toolchain,winsparkle,zlib,ntldd-git}
</syntaxhighlight>


These commands will fetch and install the packages needed for compiling, including (but not limited to) GCC 10.x, GDB, and libwinpthread-git.
Additionally, if you would like to include Discord Rich Presence support, the pre-compiled libraries are [https://github.com/discord/discord-rpc/releases here]. Simply copy the files into your base MinGW directory.


== Let's get compiling! ==
== Let's get compiling! ==
1,310

edits

Navigation menu