mirror of
https://github.com/qemu/qemu.git
synced 2026-02-04 02:24:51 +00:00
plugins: move qemu-plugin.h to include/plugins/
This change has two benefits: - ensure plugins can't include anything else from QEMU than plugins API - when compiling a C++ module, solves the header conflict with iostream header that includes transitively the wrong ctype.h, which already exists in include/qemu. By Hyrum's law, there was already one usage of other headers with mem plugin, which has been eliminated in previous commit. Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Reviewed-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org> Link: https://lore.kernel.org/qemu-devel/20260124182921.531562-7-pierrick.bouvier@linaro.org Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
This commit is contained in:
@@ -166,7 +166,7 @@ Plugin API
|
|||||||
==========
|
==========
|
||||||
|
|
||||||
The following API is generated from the inline documentation in
|
The following API is generated from the inline documentation in
|
||||||
``include/qemu/qemu-plugin.h``. Please ensure any updates to the API
|
``include/plugins/qemu-plugin.h``. Please ensure any updates to the API
|
||||||
include the full kernel-doc annotations.
|
include the full kernel-doc annotations.
|
||||||
|
|
||||||
.. kernel-doc:: include/qemu/qemu-plugin.h
|
.. kernel-doc:: include/plugins/qemu-plugin.h
|
||||||
|
|||||||
@@ -2,9 +2,6 @@
|
|||||||
* Copyright (C) 2017, Emilio G. Cota <cota@braap.org>
|
* Copyright (C) 2017, Emilio G. Cota <cota@braap.org>
|
||||||
* Copyright (C) 2019, Linaro
|
* Copyright (C) 2019, Linaro
|
||||||
*
|
*
|
||||||
* License: GNU GPL, version 2 or later.
|
|
||||||
* See the COPYING file in the top-level directory.
|
|
||||||
*
|
|
||||||
* SPDX-License-Identifier: GPL-2.0-or-later
|
* SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -8,7 +8,7 @@
|
|||||||
#define QEMU_PLUGIN_H
|
#define QEMU_PLUGIN_H
|
||||||
|
|
||||||
#include "qemu/config-file.h"
|
#include "qemu/config-file.h"
|
||||||
#include "qemu/qemu-plugin.h"
|
#include "plugins/qemu-plugin.h"
|
||||||
#include "qemu/error-report.h"
|
#include "qemu/error-report.h"
|
||||||
#include "qemu/queue.h"
|
#include "qemu/queue.h"
|
||||||
#include "qemu/option.h"
|
#include "qemu/option.h"
|
||||||
|
|||||||
@@ -4446,7 +4446,7 @@ endforeach
|
|||||||
# Other build targets
|
# Other build targets
|
||||||
|
|
||||||
if get_option('plugins')
|
if get_option('plugins')
|
||||||
install_headers('include/qemu/qemu-plugin.h')
|
install_headers('include/plugins/qemu-plugin.h')
|
||||||
if host_os == 'windows'
|
if host_os == 'windows'
|
||||||
# On windows, we want to deliver the qemu_plugin_api.lib file in the qemu installer,
|
# On windows, we want to deliver the qemu_plugin_api.lib file in the qemu installer,
|
||||||
# so that plugin authors can compile against it.
|
# so that plugin authors can compile against it.
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
#include "qemu/lockable.h"
|
#include "qemu/lockable.h"
|
||||||
#include "qemu/option.h"
|
#include "qemu/option.h"
|
||||||
#include "qemu/plugin.h"
|
#include "qemu/plugin.h"
|
||||||
#include "qemu/qemu-plugin.h"
|
#include "plugins/qemu-plugin.h"
|
||||||
#include "qemu/queue.h"
|
#include "qemu/queue.h"
|
||||||
#include "qemu/rcu_queue.h"
|
#include "qemu/rcu_queue.h"
|
||||||
#include "qemu/rcu.h"
|
#include "qemu/rcu.h"
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ if not get_option('plugins')
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
qemu_plugin_symbols = configure_file(
|
qemu_plugin_symbols = configure_file(
|
||||||
input: files('../include/qemu/qemu-plugin.h'),
|
input: files('../include/plugins/qemu-plugin.h'),
|
||||||
output: 'qemu-plugin.symbols',
|
output: 'qemu-plugin.symbols',
|
||||||
capture: true,
|
capture: true,
|
||||||
command: [files('../scripts/qemu-plugin-symbols.py'), '@INPUT@'])
|
command: [files('../scripts/qemu-plugin-symbols.py'), '@INPUT@'])
|
||||||
@@ -62,12 +62,12 @@ endif
|
|||||||
|
|
||||||
if host_os == 'windows'
|
if host_os == 'windows'
|
||||||
plugins_deps = declare_dependency(sources: [files('win32_linker.c')],
|
plugins_deps = declare_dependency(sources: [files('win32_linker.c')],
|
||||||
include_directories: '../include/qemu',
|
include_directories: '../include/plugins',
|
||||||
link_with: win32_qemu_plugin_api_lib,
|
link_with: win32_qemu_plugin_api_lib,
|
||||||
link_args: win32_qemu_plugin_api_link_flags,
|
link_args: win32_qemu_plugin_api_link_flags,
|
||||||
dependencies: glib)
|
dependencies: glib)
|
||||||
else
|
else
|
||||||
plugins_deps = declare_dependency(include_directories: '../include/qemu',
|
plugins_deps = declare_dependency(include_directories: '../include/plugins',
|
||||||
dependencies: glib)
|
dependencies: glib)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user