From 348ac061330b78cc03ed2d6841df65be5a7782fc Mon Sep 17 00:00:00 2001 From: Eric Blake Date: Thu, 2 May 2013 15:30:48 -0600 Subject: [PATCH] build: fix FreeBSD build Commit 7c9a2d88 cleaned up too many headers; FreeBSD builds failed due to: util/virutil.c:556: warning: implicit declaration of function 'canonicalize_file_name' (Not sure which Linux header leaked this declaration, but gnulib only guarantees it in stdlib.h) libvirt.c:956: warning: implicit declaration of function 'virGetUserConfigDirectory' (Here, a build on Linux was picking up virutil.h indirectly via one of the conditional driver headers, where that driver was not being built on my FreeBSD setup) * src/util/virutil.c (includes): Need for canonicalize_file_name. * src/libvirt.c (includes): Use "virutil.h" unconditionally, rather than relying on conditional indirect inclusion. Signed-off-by: Eric Blake --- src/libvirt.c | 1 + src/util/virutil.c | 1 + 2 files changed, 2 insertions(+) diff --git a/src/libvirt.c b/src/libvirt.c index 15b37a3c9f..467f6dde45 100644 --- a/src/libvirt.c +++ b/src/libvirt.c @@ -63,6 +63,7 @@ #include "viruri.h" #include "virthread.h" #include "virstring.h" +#include "virutil.h" #ifdef WITH_TEST # include "test/test_driver.h" diff --git a/src/util/virutil.c b/src/util/virutil.c index dc14c15238..982d4a3345 100644 --- a/src/util/virutil.c +++ b/src/util/virutil.c @@ -29,6 +29,7 @@ #include #include #include +#include #include #include #include