gatomic: Temporarily disable C11-style atomics on FreeBSD

They’re causing the CI to fail. While someone familiar with FreeBSD
investigates the failure, it’s easiest to disable all C11-style atomics
than add more preprocessor checks to only disable the atomics added in
!1123.

If nobody can fix the new C11-style atomics before the 2.64.0 release,
this commit should be reverted and a more comprehensive set of preprocessor
checks put in place to essentially revert !1123 for BSD only.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

Helps: #1940
This commit is contained in:
Philip Withnall 2019-11-15 10:28:21 +00:00
parent e825a98845
commit fd3ed5e31b

View File

@ -85,7 +85,9 @@ G_END_DECLS
#if defined(G_ATOMIC_LOCK_FREE) && defined(__GCC_HAVE_SYNC_COMPARE_AND_SWAP_4)
/* We prefer the new C11-style atomic extension of GCC if available */
#if defined(__ATOMIC_SEQ_CST)
/* FIXME: Temporarily disabled on FreeBSD due to CI failures:
* https://gitlab.gnome.org/GNOME/glib/issues/1940 */
#if defined(__ATOMIC_SEQ_CST) && !defined(__FreeBSD__)
#define g_atomic_int_get(atomic) \
(G_GNUC_EXTENSION ({ \