mirror of
https://github.com/qemu/qemu.git
synced 2026-04-23 14:42:54 +00:00
Move raw FFI bindings generation to separate crates. This makes it possible to reuse bindgen declarations for a header file in its dependencies (this was not the case before this change), while keeping multiple -sys crates to avoid rebuilding all the code whenever something changes. Because the -sys crates are generated in dependency order, this also enforces that the crates are organized in something that resembles the dependencies between C headers. The meson.build for rust-safe crates becomes simpler, and it should be possible in the future to let Meson's cargo support handle most of it. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> [General cleanup and Python script. - Paolo] Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
40 lines
1.0 KiB
C
40 lines
1.0 KiB
C
/* SPDX-License-Identifier: GPL-2.0-or-later */
|
|
|
|
/*
|
|
* This header file is meant to be used as input to the `bindgen` application
|
|
* in order to generate C FFI compatible Rust bindings.
|
|
*/
|
|
|
|
/*
|
|
* We block include/qemu/typedefs.h from bindgen, add here symbols
|
|
* that are needed as opaque types by other functions.
|
|
*/
|
|
typedef struct QEMUBH QEMUBH;
|
|
typedef struct QEMUFile QEMUFile;
|
|
typedef struct QemuOpts QemuOpts;
|
|
typedef struct JSONWriter JSONWriter;
|
|
typedef struct Visitor Visitor;
|
|
|
|
#include "qemu/osdep.h"
|
|
|
|
#include "qapi/error.h"
|
|
#include "qapi/error-internal.h"
|
|
#include "qemu/event_notifier.h"
|
|
#include "qemu/main-loop.h"
|
|
#include "qemu/aio.h"
|
|
#include "qemu/log-for-trace.h"
|
|
#include "qemu/log.h"
|
|
#include "qemu/module.h"
|
|
#include "qemu/option.h"
|
|
#include "qemu/timer.h"
|
|
#include "qapi/visitor.h"
|
|
#include "qobject/qbool.h"
|
|
#include "qobject/qdict.h"
|
|
#include "qobject/qjson.h"
|
|
#include "qobject/qlist.h"
|
|
#include "qobject/qnull.h"
|
|
#include "qobject/qnum.h"
|
|
#include "qobject/qobject.h"
|
|
#include "qobject/qstring.h"
|
|
#include "qobject/json-writer.h"
|