[babl/wip/msvc: 6/20] build: Define __WIN32__ on MSVC too



commit ed412bec7d2d6ca74223651d073778179bc6b1ee
Author: Chun-wei Fan <fanchunwei src gnome org>
Date:   Mon Jan 20 16:15:40 2020 +0800

    build: Define __WIN32__ on MSVC too
    
    __WIN32__ is not defined by MSVC by default, but we need it

 meson.build | 1 +
 1 file changed, 1 insertion(+)
---
diff --git a/meson.build b/meson.build
index f20b7f9f0..2f43ff641 100644
--- a/meson.build
+++ b/meson.build
@@ -174,6 +174,7 @@ common_c_flags += cc.get_supported_arguments(extra_warnings_list)
 if cc.get_id() == 'msvc'
   msvc_cflags = [
     '-utf-8',              # Avoid C4819 (Unicode handling) compiler warnings
+    '-D__WIN32__',         # MSVC does not define this by default
     '-D_USE_MATH_DEFINES', # Allow more math macro usage
     '-wd4244',             # Silence some unneeded compiler warnings
     '-wd4305'


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]