From a87eec766d99c33fc49ecc6dbce40f304168ac3f Mon Sep 17 00:00:00 2001 From: Alex Rozenman Date: Tue, 8 Jan 2013 01:28:02 +0200 Subject: [PATCH 1/3] Add libcacard/trace/generated-tracers.c to .gitignore Signed-off-by: Alex Rozenman Signed-off-by: Stefan Hajnoczi --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 5fea65dc14..53fe9c3078 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,7 @@ trace/generated-tracers.h trace/generated-tracers.c trace/generated-tracers-dtrace.h trace/generated-tracers-dtrace.dtrace +libcacard/trace/generated-tracers.c *-timestamp *-softmmu *-darwin-user From 3e84b4832180db2aa6187b6b971054bc3ca68be0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20F=C3=A4rber?= Date: Tue, 15 Jan 2013 02:55:10 +0100 Subject: [PATCH 2/3] qom: Make object_resolve_path_component() path argument const MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit A usage with a hardcoded partial path such as object_resolve_path_component(obj, "foo") is totally valid but currently leads to a compilation error. Fix this. Signed-off-by: Andreas Färber Signed-off-by: Stefan Hajnoczi --- include/qom/object.h | 2 +- qom/object.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/qom/object.h b/include/qom/object.h index d43b289a40..1ef2f0edd4 100644 --- a/include/qom/object.h +++ b/include/qom/object.h @@ -900,7 +900,7 @@ Object *object_resolve_path_type(const char *path, const char *typename, * * Returns: The resolved object or NULL on path lookup failure. */ -Object *object_resolve_path_component(Object *parent, gchar *part); +Object *object_resolve_path_component(Object *parent, const gchar *part); /** * object_property_add_child: diff --git a/qom/object.c b/qom/object.c index 351b88c817..03e6f24d28 100644 --- a/qom/object.c +++ b/qom/object.c @@ -1017,7 +1017,7 @@ gchar *object_get_canonical_path(Object *obj) return newpath; } -Object *object_resolve_path_component(Object *parent, gchar *part) +Object *object_resolve_path_component(Object *parent, const gchar *part) { ObjectProperty *prop = object_property_find(parent, part, NULL); if (prop == NULL) { From ecbe251fa0eb4905c4a82c887e37057243b9fbad Mon Sep 17 00:00:00 2001 From: Vadim Evard Date: Tue, 15 Jan 2013 16:17:24 +0400 Subject: [PATCH 3/3] configure: try pkg-config for curses Static linkikng against ncurses may require explicit -ltinfo. In case -lcurses and -lncurses both didn't work give pkg-config a chance. Fixes #1094786 for me. Signed-off-by: Vadim Evard Signed-off-by: Stefan Hajnoczi --- configure | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/configure b/configure index c908f66583..40473a9bd7 100755 --- a/configure +++ b/configure @@ -2039,7 +2039,7 @@ fi if test "$mingw32" = "yes" ; then curses_list="-lpdcurses" else - curses_list="-lncurses -lcurses" + curses_list="-lncurses:-lcurses:$($pkg_config --libs ncurses)" fi if test "$curses" != "no" ; then @@ -2052,13 +2052,16 @@ int main(void) { return s != 0; } EOF + IFS=: for curses_lib in $curses_list; do + unset IFS if compile_prog "" "$curses_lib" ; then curses_found=yes libs_softmmu="$curses_lib $libs_softmmu" break fi done + unset IFS if test "$curses_found" = "yes" ; then curses=yes else