aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/qemu-common.h2
-rw-r--r--include/qemu/osdep.h9
2 files changed, 10 insertions, 1 deletions
diff --git a/include/qemu-common.h b/include/qemu-common.h
index 50548361d0..17c2959b4f 100644
--- a/include/qemu-common.h
+++ b/include/qemu-common.h
@@ -360,7 +360,7 @@ char *qemu_find_file(int type, const char *name);
/* OS specific functions */
void os_setup_early_signal_handling(void);
-char *os_find_datadir(const char *argv0);
+char *os_find_datadir(void);
void os_parse_cmd_args(int index, const char *optarg);
void os_pidfile_error(void);
diff --git a/include/qemu/osdep.h b/include/qemu/osdep.h
index eac7172bcb..ffb296692d 100644
--- a/include/qemu/osdep.h
+++ b/include/qemu/osdep.h
@@ -215,6 +215,15 @@ bool fips_get_state(void);
*/
char *qemu_get_local_state_pathname(const char *relative_pathname);
+/* Find program directory, and save it for later usage with
+ * qemu_get_exec_dir().
+ * Try OS specific API first, if not working, parse from argv0. */
+void qemu_init_exec_dir(const char *argv0);
+
+/* Get the saved exec dir.
+ * Caller needs to release the returned string by g_free() */
+char *qemu_get_exec_dir(void);
+
/**
* qemu_getauxval:
* @type: the auxiliary vector key to lookup