#define atomic_fetch_inc(ptr) __atomic_fetch_add(ptr, 1, __ATOMIC_SEQ_CST)
#define atomic_fetch_dec(ptr) __atomic_fetch_sub(ptr, 1, __ATOMIC_SEQ_CST)
-#ifndef atomic_fetch_add
+#ifndef __cplusplus
#define atomic_fetch_add(ptr, n) __atomic_fetch_add(ptr, n, __ATOMIC_SEQ_CST)
#define atomic_fetch_sub(ptr, n) __atomic_fetch_sub(ptr, n, __ATOMIC_SEQ_CST)
#define atomic_fetch_and(ptr, n) __atomic_fetch_and(ptr, n, __ATOMIC_SEQ_CST)
#define atomic_fetch_inc(ptr) __sync_fetch_and_add(ptr, 1)
#define atomic_fetch_dec(ptr) __sync_fetch_and_add(ptr, -1)
-#ifndef atomic_fetch_add
+#ifndef __cplusplus
#define atomic_fetch_add(ptr, n) __sync_fetch_and_add(ptr, n)
#define atomic_fetch_sub(ptr, n) __sync_fetch_and_sub(ptr, n)
#define atomic_fetch_and(ptr, n) __sync_fetch_and_and(ptr, n)
* supported; otherwise, it will be omitted from the compiler error
* message (but as it remains present in the source code, it can still
* be useful when debugging). */
-#if defined(CONFIG_STATIC_ASSERT)
+#if defined(CONFIG_STATIC_ASSERT) && !defined(__cplusplus)
#define QEMU_BUILD_BUG_MSG(x, msg) _Static_assert(!(x), msg)
#elif defined(__COUNTER__)
#define QEMU_BUILD_BUG_MSG(x, msg) typedef QEMU_BUILD_BUG_ON_STRUCT(x) \
--extra-cflags=-Wno-error=logical-not-parentheses
--extra-cflags=-Wno-error=strict-prototypes
--extra-ldflags=-Wl,-rpath,'@executable_path'
- --extra-ldflags=-Wl,-no_weak_imports
--audio-drv-list=coreaudio
--enable-cocoa
--enable-hax
#define QObject qemu_QObject
#define QList qemu_QList
#define bind qemu_bind
-//declare _Static_assert as there is none for cpp file in qemu
-#define _Static_assert(x , msg) //Q_ASSERT_X(x , "tizen/ui/displayglwidget.o", msg)
#include "qemu/osdep.h"
#include "qemu/thread.h"
#undef QObject