[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v2 15/20] Disable options unsupported on Emscripten
From: |
Kohei Tokunaga |
Subject: |
[PATCH v2 15/20] Disable options unsupported on Emscripten |
Date: |
Tue, 22 Apr 2025 14:27:19 +0900 |
Daemonizing and run-with aren't supported on Emscripten so disable these
flags.
Signed-off-by: Kohei Tokunaga <ktokunaga.mail@gmail.com>
---
qemu-options.hx | 4 ++--
system/vl.c | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
V2:
- Unified two consecutive #ifndef macros into a single condition in
qemu-options.hx.
diff --git a/qemu-options.hx b/qemu-options.hx
index dc694a99a3..aab53bcfe8 100644
--- a/qemu-options.hx
+++ b/qemu-options.hx
@@ -4862,7 +4862,7 @@ SRST
Start right away with a saved state (``loadvm`` in monitor)
ERST
-#ifndef _WIN32
+#if !defined(_WIN32) && !defined(EMSCRIPTEN)
DEF("daemonize", 0, QEMU_OPTION_daemonize, \
"-daemonize daemonize QEMU after initializing\n", QEMU_ARCH_ALL)
#endif
@@ -5249,7 +5249,7 @@ HXCOMM Internal use
DEF("qtest", HAS_ARG, QEMU_OPTION_qtest, "", QEMU_ARCH_ALL)
DEF("qtest-log", HAS_ARG, QEMU_OPTION_qtest_log, "", QEMU_ARCH_ALL)
-#ifdef CONFIG_POSIX
+#if defined(CONFIG_POSIX) && !defined(EMSCRIPTEN)
DEF("run-with", HAS_ARG, QEMU_OPTION_run_with,
"-run-with [async-teardown=on|off][,chroot=dir][user=username|uid:gid]\n"
" Set miscellaneous QEMU process lifecycle options:\n"
diff --git a/system/vl.c b/system/vl.c
index 8d89394b45..255ea3be6b 100644
--- a/system/vl.c
+++ b/system/vl.c
@@ -766,7 +766,7 @@ static QemuOptsList qemu_smp_opts = {
},
};
-#if defined(CONFIG_POSIX)
+#if defined(CONFIG_POSIX) && !defined(EMSCRIPTEN)
static QemuOptsList qemu_run_with_opts = {
.name = "run-with",
.head = QTAILQ_HEAD_INITIALIZER(qemu_run_with_opts.head),
@@ -3677,7 +3677,7 @@ void qemu_init(int argc, char **argv)
case QEMU_OPTION_nouserconfig:
/* Nothing to be parsed here. Especially, do not error out
below. */
break;
-#if defined(CONFIG_POSIX)
+#if defined(CONFIG_POSIX) && !defined(EMSCRIPTEN)
case QEMU_OPTION_daemonize:
os_set_daemonize(true);
break;
--
2.25.1
- [PATCH v2 09/20] target/s390x: Fix type conflict of GLib function pointers, (continued)
- [PATCH v2 09/20] target/s390x: Fix type conflict of GLib function pointers, Kohei Tokunaga, 2025/04/22
- [PATCH v2 11/20] util/cacheflush.c: Update cache flushing mechanism for Emscripten, Kohei Tokunaga, 2025/04/22
- [PATCH v2 10/20] include/glib-compat.h: Poison g_list_sort and g_slist_sort, Kohei Tokunaga, 2025/04/22
- [PATCH v2 08/20] target/ppc: Fix type conflict of GLib function pointers, Kohei Tokunaga, 2025/04/22
- [PATCH v2 15/20] Disable options unsupported on Emscripten,
Kohei Tokunaga <=
- [PATCH v2 12/20] block: Add including of ioctl header for Emscripten build, Kohei Tokunaga, 2025/04/22
- [PATCH v2 13/20] block: Fix type confict of the copy_file_range stub, Kohei Tokunaga, 2025/04/22
- [PATCH v2 14/20] include/qemu/osdep.h: Add Emscripten-specific OS dependencies, Kohei Tokunaga, 2025/04/22
- [PATCH v2 16/20] util: exclude mmap-alloc.c from compilation target on Emscripten, Kohei Tokunaga, 2025/04/22
- [PATCH v2 17/20] util: Add coroutine backend for emscripten, Kohei Tokunaga, 2025/04/22