Lines Matching +full:test +full:- +full:mingw
1 Chun-wei Fan `<fanc999@yahoo.com.tw>`
17 To build GLib on Win32, you can use either GCC ("MinGW") or the Microsoft
21 You can also cross-compile GLib for Windows from Linux using the
22 cross-compiling mingw packages for your distro.
31 compilation related to Win32 in GLib-using code:
33 - `G_OS_WIN32` is defined when compiling for native Win32, without
37 - `G_WITH_CYGWIN` is defined if compiling for the Cygwin
42 - `G_PLATFORM_WIN32` is defined when either `G_OS_WIN32` or `G_WITH_CYGWIN`
48 Additionally, there are the compiler-specific macros:
49 - `__GNUC__` is defined when using GCC or Clang
50 - `__clang__` is defined when using Clang or Clang-CL
51 - `_MSC_VER` is defined when using MSVC or Clang-CL
54 …the [Universal CRT](https://docs.microsoft.com/en-us/cpp/c-runtime-library/crt-library-features?vi…
55 when building with Visual Studio. When using the MinGW-GCC toolchain, the CRT
58 MinGW](https://mingwpy.github.io/ucrt.html) too.
66 the right compiler set up the right way. If you intend to use MinGW-GCC,
69 You should link to GLib using the `-mms-bitfields` GCC flag. This flag means
71 essential if the same DLLs are to be usable both from gcc- and MSVC-compiled
74 ## Cross-CRT issues
89 …(https://docs.microsoft.com/en-us/cpp/c-runtime-library/potential-errors-passing-crt-objects-acros…
95 You can build GLib with MinGW-GCC, MSVC, or (experimentally) with Clang-CL.
99 - Install Python 3.6.x or newer, either 32-bit or 64-bit. We recommend enabling
101 - [Install Meson](https://mesonbuild.com/Getting-meson.html)
102 - Install the [Ninja build tool](https://github.com/ninja-build/ninja/releases), which can also be
105 - [git for Windows](https://gitforwindows.org/) is required, since Meson makes
108 ## Building with MinGW-GCC
111 MinGW-GCC toolchain installed, and build GLib [like any other Meson
112 project](https://mesonbuild.com/Quick-guide.html#compiling-a-meson-project).
120 - Open a Visual Studio (or SDK) command prompt that matches the Visual Studio
124 - Create an empty directory/folder for the build inside your GLib sources
127 - Set up the build using Meson:
130 > meson .. --buildtype=<release|debug|debugoptimized> --prefix=<path> [--backend=vs]
133 Please see [the Meson docs](https://mesonbuild.com/Builtin-options.html#core-options)
134 for an explanation for `--buildtype`.
136 The path passed for `--prefix` need not to be on the same drive as where the
138 path. The `--backend=vs` option can be used if the Visual Studio project
141 - Build, test and install the build:
142 Run `ninja` to build, `meson test` to test and `meson install` to install the
143 build. If you used `--backend=vs`, instead of running `ninja`, you need to
152 If you are building GLib-based libraries or applications, or GLib itself
160 To overcome this problem, please set your system's locale setting for non-Unicode to
164 ### Support for pre-2012 Visual Studio
169 Visual Studio 2008 or 2010 should continue to use glib-2.66.x.