oslib-posix: Fix build on FreeBSD
PATCH 1/1 oslib-posix: Fix build on FreeBSD
Commit 10f5bff622cad71645e22c027b77ac31e51008ef (util: Split out exec_dir from os_find_datadir) moved code from os-posix.c to util/oslib-posix.c but forgot to move a FreeBSD #include alongside, needed for CTL_KERN among others.
Cc Fam Zheng <[email protected]>
Cc Paolo Bonzini <[email protected]>
Signed-off-by Andreas Färber <[email protected]>
--- os-posix.c | 4 ---- util/oslib-posix.c | 4 ++++ 2 files changed, 4 insertions(+), 4 deletions(-)
os-posix.c +0 -4
@@ -44,10 +44,6 @@#include <sys/prctl.h> #endif -#ifdef __FreeBSD__ -#include <sys/sysctl.h> -#endif -static struct passwd *user_pwd;static const char *chroot_dir;static int daemonize;
util/oslib-posix.c +4 -0
@@ -63,6 +63,10 @@ extern int daemon(int, int);#include <sys/syscall.h> #endif +#ifdef __FreeBSD__ +#include <sys/sysctl.h> +#endif +int qemu_get_thread_id (void ) {#if defined(__linux__)
Signature · 1 line
1.8.4.5
Peter Maydell
AppliedQuoted 8 lines · Andreas Färber
Commit
10f5bff622cad71645e22c027b77ac31e51008ef(util: Split outexec_dirfromos_find_datadir) moved code fromos-posix.ctoutil/oslib-posix.cbut forgot to move a FreeBSD #include alongside, needed forCTL_KERNamong others.Cc Fam Zheng <[email protected]>Cc Paolo Bonzini <[email protected]>Signed-off-by Andreas Färber <[email protected]>
Applied to master, thanks.
-- PMM