aboutsummaryrefslogtreecommitdiffstats
path: root/tools/libxl/xl.c
diff options
context:
space:
mode:
authorIan Campbell <ian.campbell@citrix.com>2011-04-06 16:50:16 +0100
committerIan Campbell <ian.campbell@citrix.com>2011-04-06 16:50:16 +0100
commitbbfc7c38075c1f5181ff205b5111eddc0a8c76eb (patch)
tree255743bf4cfc1ab2b4e075cc1ba891b15bd07fb8 /tools/libxl/xl.c
parente15c160c0f6ee65e0160826d8a3987a65ccfa9ec (diff)
downloadxen-bbfc7c38075c1f5181ff205b5111eddc0a8c76eb.tar.gz
xen-bbfc7c38075c1f5181ff205b5111eddc0a8c76eb.tar.bz2
xen-bbfc7c38075c1f5181ff205b5111eddc0a8c76eb.zip
libxl: do not expose libxenctrl/libxenstore headers via libxl.h
This completely removes libxenstore from libxl users' view. xl still needs libxenctrl directly due to the direct use of the xentoollog functionality but it is not exposed to the indirect linkage anymore. Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com> Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
Diffstat (limited to 'tools/libxl/xl.c')
-rw-r--r--tools/libxl/xl.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/tools/libxl/xl.c b/tools/libxl/xl.c
index 9e3023c629..5bab2ff1b8 100644
--- a/tools/libxl/xl.c
+++ b/tools/libxl/xl.c
@@ -26,6 +26,7 @@
#include <fcntl.h>
#include <ctype.h>
#include <inttypes.h>
+#include <xenctrl.h>
#include "libxl.h"
#include "libxl_utils.h"
@@ -111,7 +112,7 @@ int main(int argc, char **argv)
logger = xtl_createlogger_stdiostream(stderr, minmsglevel, 0);
if (!logger) exit(1);
- if (libxl_ctx_init(&ctx, LIBXL_VERSION, (xentoollog_logger*)logger)) {
+ if (libxl_ctx_alloc(&ctx, LIBXL_VERSION, (xentoollog_logger*)logger)) {
fprintf(stderr, "cannot init xl context\n");
exit(1);
}
@@ -123,7 +124,7 @@ int main(int argc, char **argv)
exit(1);
}
- ret = libxl_read_file_contents(&ctx, config_file,
+ ret = libxl_read_file_contents(ctx, config_file,
&config_data, &config_len);
if (ret)
fprintf(stderr, "Failed to read config file: %s: %s\n",
@@ -147,7 +148,7 @@ int main(int argc, char **argv)
ret = 1;
}
- libxl_ctx_free(&ctx);
+ libxl_ctx_free(ctx);
xtl_logger_destroy((xentoollog_logger*)logger);
return ret;