qemu-e2k/include/qemu
Paolo Bonzini 875df03b22 osdep: protect qemu/osdep.h with extern "C"
System headers may include templates if compiled with a C++ compiler,
which cause the compiler to complain if qemu/osdep.h is included
within a C++ source file's 'extern "C"' block.  Add
an 'extern "C"' block directly to qemu/osdep.h, so that
system headers can be kept out of it.

There is a stray declaration early in qemu/osdep.h, which needs
to be special cased.  Add a definition in qemu/compiler.h to
make it look nice.

config-host.h, CONFIG_TARGET, exec/poison.h and qemu/compiler.h
are included outside the 'extern "C"' block; that is not
an issue because they consist entirely of preprocessor directives.

This allows us to move the include of osdep.h in our two C++
source files outside the extern "C" block they were previously
using for it, which in turn means that they compile successfully
against newer versions of glib which insist that glib.h is
*not* inside an extern "C" block.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Acked-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-id: 20210416135543.20382-3-peter.maydell@linaro.org
[PMM: Moved disas/arm-a64.cc osdep.h include out of its extern "C" block;
 explained in commit message why we're doing this]
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-04-17 18:44:30 +01:00
..
accel.h accel: replace struct CpusAccel with AccelOpsClass 2021-02-05 10:24:15 -10:00
atomic128.h qemu/atomic.h: rename atomic_ to qatomic_ 2020-09-23 16:07:44 +01:00
atomic.h qemu/atomic: Drop special case for unsupported compiler 2020-12-15 12:52:07 -05:00
base64.h nomaintainer: Fix Lesser GPL version number 2020-11-15 17:04:40 +01:00
bcd.h
bitmap.h
bitops.h qemu/atomic.h: rename atomic_ to qatomic_ 2020-09-23 16:07:44 +01:00
bswap.h bswap.h: Remove unused float-access functions 2021-02-15 09:38:50 +00:00
buffer.h nomaintainer: Fix Lesser GPL version number 2020-11-15 17:04:40 +01:00
cacheflush.h util: Enhance flush_icache_range with separate data pointer 2021-01-07 05:09:41 -10:00
co-shared-resource.h
compiler.h osdep: protect qemu/osdep.h with extern "C" 2021-04-17 18:44:30 +01:00
config-file.h qemu-config: add error propagation to qemu_config_parse 2021-03-06 11:41:54 +01:00
coroutine_int.h
coroutine.h coroutine-lock: Reimplement CoRwlock to fix downgrade bug 2021-03-31 10:44:21 +01:00
cpuid.h
crc32c.h
crc-ccitt.h util: Add CRC16 (CCITT) calculation routines 2021-01-24 20:10:54 +01:00
ctype.h
cutils.h cutils: replace strdup with g_strdup 2020-11-03 09:42:52 -05:00
datadir.h vl: extract softmmu/datadir.c 2020-12-10 12:15:18 -05:00
dbus.h
drm.h
envlist.h
error-report.h error: rename error_with_timestamp to message_with_timestamp 2021-02-01 10:50:55 +00:00
event_notifier.h event_notifier: handle initialization failure better 2021-02-08 14:43:55 +01:00
fifo8.h utils/fifo8: add VMSTATE_FIFO8_TEST macro 2021-02-07 20:38:34 +00:00
fifo32.h
filemonitor.h nomaintainer: Fix Lesser GPL version number 2020-11-15 17:04:40 +01:00
futex.h
guest-random.h
hbitmap.h
help_option.h keyval: Parse help options 2020-10-15 16:06:27 +02:00
host-utils.h
id.h net: Use id_generate() in the network subsystem, too 2021-03-09 21:47:45 +01:00
int128.h qemu/int128: Add int128_or 2021-02-18 07:48:22 -08:00
iov.h util/iov: make qemu_iovec_init_extended() honest 2021-02-03 08:00:33 -06:00
iova-tree.h
jhash.h
job.h job: add .cancel handler for the driver 2021-02-12 11:23:19 -06:00
lockable.h
log-for-trace.h
log.h qemu/atomic.h: rename atomic_ to qatomic_ 2020-09-23 16:07:44 +01:00
main-loop.h main-loop: Fix comment 2020-09-01 12:07:52 +02:00
memfd.h
mmap-alloc.h memory: alloc RAM from file at offset 2021-02-09 20:53:56 +00:00
module.h module: silence errors for module_load_qom_all(). 2020-10-15 10:43:48 +02:00
notify.h
nvdimm-utils.h Clean up includes 2020-12-10 17:16:44 +01:00
option_int.h
option.h qemu-option: restrict qemu_opts_set to merge-lists QemuOpts 2020-12-10 12:15:12 -05:00
osdep.h osdep: protect qemu/osdep.h with extern "C" 2021-04-17 18:44:30 +01:00
path.h
plugin-memory.h
plugin.h accel/tcg: allow plugin instrumentation to be disable via cflags 2021-02-18 08:19:23 +00:00
pmem.h
processor.h
progress_meter.h
qdist.h
qemu-plugin.h plugins: Fixes typo in qemu-plugin.h 2021-03-17 07:17:46 +00:00
qemu-print.h
qht.h
qsp.h
queue.h qemu/atomic.h: rename atomic_ to qatomic_ 2020-09-23 16:07:44 +01:00
range.h
ratelimit.h
rcu_queue.h qemu/atomic.h: rename atomic_ to qatomic_ 2020-09-23 16:07:44 +01:00
rcu.h qemu/atomic.h: rename atomic_ to qatomic_ 2020-09-23 16:07:44 +01:00
readline.h
selfmap.h
seqlock.h qemu/atomic.h: rename atomic_ to qatomic_ 2020-09-23 16:07:44 +01:00
sockets.h
stats64.h qemu/atomic.h: rename atomic_ to qatomic_ 2020-09-23 16:07:44 +01:00
sys_membarrier.h
systemd.h
thread-posix.h
thread-win32.h
thread.h qemu/atomic.h: rename atomic_ to qatomic_ 2020-09-23 16:07:44 +01:00
throttle-options.h
throttle.h
timed-average.h
timer.h spapr: rollback 'unplug timeout' for CPU hotunplugs 2021-04-12 12:27:14 +10:00
tsan.h
typedefs.h exec: Move TranslationBlock typedef to qemu/typedefs.h 2021-02-18 08:19:08 +00:00
unicode.h
units.h
uri.h
userfaultfd.h migration: introduce UFFD-WP low-level interface helpers 2021-02-08 11:19:51 +00:00
uuid.h
vfio-helpers.h util/vfio-helpers: Pass page protections to qemu_vfio_pci_map_bar() 2020-10-05 09:35:52 +01:00
vhost-user-server.h libvhost-user: make it a meson subproject 2020-12-08 13:48:58 -05:00
win_dump_defs.h
xattr.h
xxhash.h target/arm: Implement an IMPDEF pauth algorithm 2021-01-19 14:38:51 +00:00
yank.h yank: Remove dependency on qiochannel 2021-04-01 15:27:44 +04:00