• Home
  • Raw
  • Download

Lines Matching +full:clang +full:- +full:cl +full:- +full:10 +full:- +full:x86

3   # NOTE: We keep this pinned at 0.49 because that's what Debian 10 ships
27 # Set the input and exec encoding to utf-8, like is the default with GCC
28 add_project_arguments(cc.get_supported_arguments(['/utf-8']), language: 'c')
31 # -mms-bitfields vs -fnative-struct ?
59 current = binary_age - interface_age
74 glib_pkgdatadir = join_paths(glib_datadir, 'glib-2.0')
92 # See https://mesonbuild.com/Builtin-options.html#directories
96 installed_tests_metadir = join_paths(glib_datadir, 'installed-tests', meson.project_name())
97 installed_tests_execdir = join_paths(glib_libexecdir, 'installed-tests', meson.project_name())
100 installed_tests_template_tap = files('template-tap.test.in')
105 add_project_arguments('-D_GNU_SOURCE', language: 'c')
108 add_project_arguments('-D_QNX_SOURCE', language: 'c')
113 if cc.has_argument('-fno-strict-aliasing')
114 add_project_arguments('-fno-strict-aliasing', language: 'c')
151 if host_system == 'windows' and cc.get_id() != 'msvc' and cc.get_id() != 'clang-cl'
155 # for gcc/clang by default, it doesn't do so on Windows.
185 # so it's OK to pass -Werror explicitly. Replace with
187 args: ['-Werror'],
199 if cc.get_id() == 'msvc' or cc.get_id() == 'clang-cl'
201 elif cc.has_argument('-fvisibility=hidden')
203 glib_hidden_visibility_args = ['-fvisibility=hidden']
205 elif cc.has_argument('-fvisibility=hidden')
207 glib_hidden_visibility_args = ['-fvisibility=hidden']
234 # Visual Studio for dependencies that don't normally come with pkg-config files
250 glib_debug_cflags += ['-DG_ENABLE_DEBUG']
253 glib_debug_cflags += ['-DG_DISABLE_CAST_CHECKS']
258 glib_debug_cflags += ['-DG_DISABLE_ASSERT']
263 glib_debug_cflags += ['-DG_DISABLE_CHECKS']
422 if cc.get_id() == 'gcc' or cc.get_id() == 'clang'
424 '-Wduplicated-branches',
425 '-Wimplicit-fallthrough',
426 '-Wmisleading-indentation',
427 '-Wstrict-prototypes',
428 '-Wunused',
430 '-Wno-unused-parameter',
432 # building with -Wbad-function-cast.
433 '-Wno-bad-function-cast',
434 '-Wno-cast-function-type',
435 # Due to function casts through (void*) we cannot support -Wpedantic:
437 '-Wno-pedantic',
438 # A zero-length format string shouldn't be considered an issue.
439 '-Wno-format-zero-length',
440 '-Werror=declaration-after-statement',
441 '-Werror=format=2',
442 '-Werror=implicit-function-declaration',
443 '-Werror=init-self',
444 '-Werror=missing-include-dirs',
445 '-Werror=missing-prototypes',
446 '-Werror=pointer-arith',
449 '-Wl,-z,nodelete',
452 warning_c_link_args += ['-Wl,-Bsymbolic-functions']
461 # FIXME: We cannot build some of the GResource tests with -z nodelete, which
463 # it to the relevant targets manually. We do the same with -Bsymbolic-functions
479 # We require Windows 10+ on WinRT
607 # cc.has_function() in some cases (clang, gcc 10+) assumes that if the
610 # stpcpy() on Windows using clang and gcc as well as posix_memalign() using
616 # posix_memalign() on Windows using GCC and clang we can remove this.
621 # When building for Android-20 and earlier, require Meson 0.54.2 or newer.
629 error('Compiling for <Android-21 requires Meson 0.54.2 or newer')
650 char *ptr = strerror_r (-2, error_string, 256);
651 char c = *strerror_r (-2, error_string, 256);
661 # Special-case these functions that have alternative names on Windows/MSVC
710 if cc.has_header_symbol('dlfcn.h', 'RTLD_NEXT', args: '-D_GNU_SOURCE')
753 osx_ldflags += ['-Wl,-framework,CoreFoundation']
762 osx_ldflags += '-Wl,-framework,Carbon'
779 osx_ldflags += ['-Wl,-framework,Foundation', '-Wl,-framework,AppKit']
813 # Check for __uint128_t (gcc) by checking for 128-bit division
816 static __uint128_t v2 = 10;
833 elif cc.links(clock_gettime_test_code, args : '-lrt', name : 'clock_gettime in librt')
853 elif cc.links(dlopen_dlsym_test_code, args : '-ldl', name : 'dlopen() and dlsym() in libdl')
937 if host_system == 'windows' and (cc.get_id() == 'msvc' or cc.get_id() == 'clang-cl')
938 # Unfortunately the Visual Studio 2015+ implementations of C99-style
975 /* AIX 5.1 and Solaris seems to have a half-baked vsnprintf()
1213 long long llmax = (long long) -1;
1226 int array [2*(sizeof(long double) >= sizeof(double)) - 1];''',
1249 uintmax_t i = (uintmax_t) -1;
1261 uintmax_t i = (uintmax_t) -1;
1290 if cc.get_id() == 'msvc' or cc.get_id() == 'clang-cl'
1296 # Some platforms (Apple) hard-code int64_t to long long instead of
1297 # using long on 64-bit architectures. This can cause type mismatch
1305 #pragma GCC diagnostic error "-Wincompatible-pointer-types"
1317 #pragma GCC diagnostic error "-Wincompatible-pointer-types"
1337 # be 64-bit in C99, and it is available on all supported compilers
1363 error('Compiler provides no native 16-bit integer type')
1389 error('Compiler provides no native 32-bit integer type')
1425 error('Compiler provides no native 64-bit integer type')
1461 # Do separate checks for gcc/clang (and ignore other compilers for now), since
1462 # we need to explicitly pass -Werror to the compilers.
1467 if cc.get_id() == 'gcc' or cc.get_id() == 'clang'
1477 args: ['-Werror'],
1487 args: ['-Werror'],
1497 args: ['-Werror'],
1507 args: ['-Werror'],
1512 if host_system == 'linux-gnu_ilp32'
1605 error('GLib requires a 64-bit type. You might want to consider using the GNU C compiler.')
1777 # never succeeded on Windows and used some pre-defined
1780 # and with *any* glib-using code compiled against them,
1831 # Note that the atomic ops are only available with GCC on x86 when
1832 # using -march=i486 or higher. If we detect that the atomic ops are
1851 if cc.get_id() == 'msvc' or cc.get_id() == 'clang-cl' or cc.links(atomictest, name : 'atomic ops')
1861 if host_machine.cpu_family() == 'x86' and cc.links(atomictest, args : '-march=i486')
1862 error('GLib must be built with -march=i486 or later.')
1956 f (i - 1);
1978 # the built-in implementation
1985 warning('-Diconv was set to @0@, which was ignored')
2008 pcre2 = dependency('libpcre2-8', version: '>= 10.32', required : true)
2025 if cc.get_id() != 'msvc' and cc.get_id() != 'clang-cl'
2039 # proxy-libintl subproject.
2040 # FIXME: glib-gettext.m4 has much more checks to detect broken/uncompatible
2056 # also defining the macros with the -pthread flag.
2069 libintl = subproject('proxy-libintl').get_variable('intl_dep')
2071 have_bind_textdomain_codeset = true # proxy-libintl supports it
2088 # pkg-config file below
2154 char p[10];
2155 (void) strlcpy (p, "hi", 10);
2178 /* This code is a dumbed-down version of g_file_get_contents() */
2235 # Determine which user environment-dependent files that we want to install
2237 bash_comp_dep = dependency('bash-completion', version: '>=2.0', required: false)
2238 have_sh = find_program('sh', required : false).found() # For glib-gettextize
2253 # Autotools explicitly removed --Wl,--export-all-symbols from windows builds,
2258 export_dynamic_ldflags = ['-Wl,--export-all-symbols']
2264 export_dynamic_ldflags = ['-Wl,--export-dynamic']
2269 if host_system == 'windows' and cc.get_id() != 'msvc' and cc.get_id() != 'clang-cl'
2270 # Ensure MSVC-compatible struct packing convention is used when
2272 # in glib-2.0.pc.
2273 win32_cflags = ['-mms-bitfields']
2276 # Win32 API libs, used only by libglib and exposed in glib-2.0.pc
2277 win32_ldflags = ['-lws2_32', '-lole32', '-lwinmm', '-lshlwapi']
2279 win32_ldflags = ['-luser32', '-lkernel32']
2286 # Since dtrace support is opt-in we just error out if it was requested but
2296 # FIXME: autotools build also passes -fPIC -DPIC but is it needed in this case?
2299 arguments : ['-G', '-s', '@INPUT@', '-o', '@OUTPUT@'])
2300 # FIXME: $(SED) -e "s,define STAP_HAS_SEMAPHORES 1,undef STAP_HAS_SEMAPHORES,"
2301 # -e "s,define _SDT_HAS_SEMAPHORES 1,undef _SDT_HAS_SEMAPHORES,"
2304 arguments : ['-h', '-s', '@INPUT@', '-o', '@OUTPUT@'])
2345 # Install glib-gettextize executable, if a UNIX-style shell is found
2354 configure_file(input : 'glib-gettextize.in',
2356 output : 'glib-gettextize',
2361 install_data('m4macros/glib-2.0.m4', 'm4macros/glib-gettext.m4', 'm4macros/gsettings.m4',
2368 install_dir : join_paths(get_option('datadir'), 'glib-2.0', 'valgrind'))
2374 install_headers([ 'msvc_recommended_pragmas.h' ], subdir : 'glib-2.0')
2381 '--nonet',
2382 '--stringparam', 'man.output.quietly', '1',
2383 '--stringparam', 'funcsynopsis.style', 'ansi',
2384 '--stringparam', 'man.th.extra1.suppress', '1',
2385 '--stringparam', 'man.authors.section.enabled', '0',
2386 '--stringparam', 'man.copyright.section.enabled', '0',
2387 '-o', '@OUTPUT@',