MinGW-w64-13.0.0

Introduction to MinGW-w64

MinGW-w64's headers have been installed already, but not the rest of the project, including useful libraries. This building process will cover the rest of the MinGW-w64 project.

[Notat]

Notat

Dette kan ta litt tid å bygge. Gjør gjerne noe annet mens dette bygges.

MinGW-w64 Dependencies

Required

MinGW-w64-Binutils-2.44, MinGW-w64-headers-13.0.0, and Static MinGW-w64-GCC-15.1.0

Installation of MinGW-w64

x86_64 MinGW-w64

Install x86_64 MinGW-w64 by running the following commands:

mkdir build-x86_64 &&
cd    build-x86_64 &&

../configure --prefix=/usr/x86_64-w64-mingw32 \
             --host=x86_64-w64-mingw32        \
             --disable-lib32                  \
             --enable-experimental            \
             --with-default-msvcrt=msvcrt     &&

make

Now, as the root user:

make install

Now build the winpthreads library after installing the bulk of MinGW-w64 to prevent the build from linking against libraries that weren't installed but now are (this library enables POSIX thread support):

cd ..                          &&
mkdir build-x86_64-winpthreads &&
cd    build-x86_64-winpthreads &&

../mingw-w64-libraries/winpthreads/configure \
            --prefix=/usr/x86_64-w64-mingw32 \
            --host=x86_64-w64-mingw32        \
            --disable-lib32                  \
            --with-default-msvcrt=msvcrt     &&

make

Now install the winpthreads library as the root user:

make install && cd ..

i686 MinGW-w64

Install i686 MinGW-w64 by running the following commands:

mkdir build-i686 &&
cd    build-i686 &&

../configure --prefix=/usr/i686-w64-mingw32 \
             --host=i686-w64-mingw32        \
             --disable-lib64                \
             --enable-experimental          \
             --with-default-msvcrt=msvcrt   &&

make

Now, as the root user:

make install

Now build the winpthreads library after installing the bulk of MinGW-w64 to prevent the build from linking against libraries that weren't installed but now are (this library enables POSIX thread support):

cd ..                        &&
mkdir build-i686-winpthreads &&
cd    build-i686-winpthreads &&

../mingw-w64-libraries/winpthreads/configure \
            --prefix=/usr/i686-w64-mingw32   \
            --host=i686-w64-mingw32          \
            --disable-lib64                  \
            --with-default-msvcrt=msvcrt &&

make

Now install the winpthreads library as the root user:

make install

Command Explanations

[Notat]

Notat

Run ../configure --help and ../mingw-w64-libraries/winpthreads/configure --help respectively for a full list of options.

--prefix=/usr/*: This option installs the files to their respective architecture for better separation of architectures.

--host=*: This option builds files for the architecture passed to it.

--enable-experimental: This option enables experimental features.

--with-default-msvcrt=msvcrt: Fra og med MinGW-w64-12.0.0, Universal C Runtime (UCRT), som ble lagt til i Windows 10, har blitt standard. Dette alternativet gjør Microsoft Visual C Runtime (MSVCRT) til standard, som er mer testet og har færre feil. Det sikrer også kompatibilitet med programvare laget for eldre Windows versjoner.

Contents

Installed Programs: None
Installed Libraries: libwinpthread-1 (DLL; in /usr/{i686,x86_64}-w64-mingw32/bin) and hundreds of static libraries and headers needed by Windows. To see the whole list of libraries, visit https://archlinux.org/packages/extra/any/mingw-w64-crt/, and see "Package Contents".
Installed Directories: /usr/{i686,x86_64}-w64-mingw32/{bin,lib}