[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] [SOLARIS] Fix xentop build.
# HG changeset patch # User kaf24@xxxxxxxxxxxxxxxxxxxxx # Date 1167409073 0 # Node ID f0e9c518d0ff27cc3b505e4ba1d6dc9d47b7bd2c # Parent 25723963a6b639a0651b961c40808be63cb2c27b [SOLARIS] Fix xentop build. Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx> --- tools/xenstat/xentop/Makefile | 1 + tools/xenstat/xentop/xentop.c | 11 +++++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff -r 25723963a6b6 -r f0e9c518d0ff tools/xenstat/xentop/Makefile --- a/tools/xenstat/xentop/Makefile Fri Dec 29 14:25:03 2006 +0000 +++ b/tools/xenstat/xentop/Makefile Fri Dec 29 16:17:53 2006 +0000 @@ -26,6 +26,7 @@ CFLAGS += -DGCC_PRINTF -Wall -Werror -I$ CFLAGS += -DGCC_PRINTF -Wall -Werror -I$(XEN_LIBXENSTAT) LDFLAGS += -L$(XEN_LIBXENSTAT) LDLIBS += -lxenstat $(CURSES_LIBS) $(SOCKET_LIBS) +CFLAGS += -DHOST_$(XEN_OS) .PHONY: all all: xentop diff -r 25723963a6b6 -r f0e9c518d0ff tools/xenstat/xentop/xentop.c --- a/tools/xenstat/xentop/xentop.c Fri Dec 29 14:25:03 2006 +0000 +++ b/tools/xenstat/xentop/xentop.c Fri Dec 29 16:17:53 2006 +0000 @@ -48,6 +48,13 @@ #endif #define KEY_ESCAPE '\x1B' + +#ifdef HOST_SunOS +/* Old curses library on Solaris takes non-const strings. */ +#define curses_str_t char * +#else +#define curses_str_t const char * +#endif /* * Function prototypes @@ -269,7 +276,7 @@ static void print(const char *fmt, ...) if (!batch) { if((current_row() < lines()-1)) { va_start(args, fmt); - vwprintw(stdscr, fmt, args); + vwprintw(stdscr, (curses_str_t)fmt, args); va_end(args); } } else { @@ -283,7 +290,7 @@ static void attr_addstr(int attr, const static void attr_addstr(int attr, const char *str) { attron(attr); - addstr(str); + addstr((curses_str_t)str); attroff(attr); } _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |