All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Fix builind error for old gcc
@ 2014-07-11  3:32 Wen Congyang
  2014-07-11  8:53 ` Wei Liu
  0 siblings, 1 reply; 3+ messages in thread
From: Wen Congyang @ 2014-07-11  3:32 UTC (permalink / raw
  To: Wei Liu, xen-devel; +Cc: Wen Congyang

commit de18e4c038306aeeca53e6e63e563036cafef162 introduces a building error:
gcc  -O1 -fno-omit-frame-pointer -m64 -g -fno-strict-aliasing -std=gnu99 -Wall -Wstrict-prototypes -Wdeclaration-after-statement -Wno-unused-but-set-variable   -D__XEN_TOOLS__ -MMD -MF .xl.o.d -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -fno-optimize-sibling-calls  -Werror -Wno-format-zero-length -Wmissing-declarations -Wno-declaration-after-statement -Wformat-nonliteral -I. -fPIC -pthread -I/home/wency/src/upstream/xen/tools/libxl/../../tools/libxc -I/home/wency/src/upstream/xen/tools/libxl/../../tools/include  -I/home/wency/src/upstream/xen/tools/libxl/../../tools/libxl -I/home/wency/src/upstream/xen/tools/libxl/../../tools/libxc -I/home/wency/src/upstream/xen/tools/libxl/../../tools/include -I/home/wency/src/upstream/xen/tools/libxl/../../tools/include -Wshadow -include /home/wency/src/upstream/xen/tools/libxl/../../tools/config.h   -c -o xl.o xl.c
In file included from xl.c:31:
libxl.h:582: error: redefinition of typedef ‘libxl_ctx’
libxl.h:348: note: previous declaration of ‘libxl_ctx’ was here

Signed-off-by: Wen Congyang <wency@cn.fujitsu.com>
---
 tools/libxl/libxl.h | 2 --
 1 file changed, 2 deletions(-)

diff --git a/tools/libxl/libxl.h b/tools/libxl/libxl.h
index e6e0301..5ae6532 100644
--- a/tools/libxl/libxl.h
+++ b/tools/libxl/libxl.h
@@ -579,8 +579,6 @@ typedef struct libxl__ctx libxl_ctx;
  */
 #define LIBXL_HAVE_CPUPOOL_NAME 1
 
-typedef struct libxl__ctx libxl_ctx;
-
 typedef uint8_t libxl_mac[6];
 #define LIBXL_MAC_FMT "%02hhx:%02hhx:%02hhx:%02hhx:%02hhx:%02hhx"
 #define LIBXL_MAC_FMTLEN ((2*6)+5) /* 6 hex bytes plus 5 colons */
-- 
1.9.3


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] Fix builind error for old gcc
  2014-07-11  3:32 [PATCH] Fix builind error for old gcc Wen Congyang
@ 2014-07-11  8:53 ` Wei Liu
  2014-07-11 11:18   ` Ian Campbell
  0 siblings, 1 reply; 3+ messages in thread
From: Wei Liu @ 2014-07-11  8:53 UTC (permalink / raw
  To: Wen Congyang; +Cc: Wei Liu, Ian Campbell, xen-devel

(There's typo in subject line)

CC'ing Ian

On Fri, Jul 11, 2014 at 11:32:33AM +0800, Wen Congyang wrote:
> commit de18e4c038306aeeca53e6e63e563036cafef162 introduces a building error:
> gcc  -O1 -fno-omit-frame-pointer -m64 -g -fno-strict-aliasing -std=gnu99 -Wall -Wstrict-prototypes -Wdeclaration-after-statement -Wno-unused-but-set-variable   -D__XEN_TOOLS__ -MMD -MF .xl.o.d -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -fno-optimize-sibling-calls  -Werror -Wno-format-zero-length -Wmissing-declarations -Wno-declaration-after-statement -Wformat-nonliteral -I. -fPIC -pthread -I/home/wency/src/upstream/xen/tools/libxl/../../tools/libxc -I/home/wency/src/upstream/xen/tools/libxl/../../tools/include  -I/home/wency/src/upstream/xen/tools/libxl/../../tools/libxl -I/home/wency/src/upstream/xen/tools/libxl/../../tools/libxc -I/home/wency/src/upstream/xen/tools/libxl/../../tools/include -I/home/wency/src/upstream/xen/tools/libxl/../../tools/include -Wshadow -include /home/wency/src/upstream/xen/tools/libxl/../../tools/config.h   -c -o xl.o xl.c
> In file included from xl.c:31:
> libxl.h:582: error: redefinition of typedef ‘libxl_ctx’
> libxl.h:348: note: previous declaration of ‘libxl_ctx’ was here
> 
> Signed-off-by: Wen Congyang <wency@cn.fujitsu.com>
> ---
>  tools/libxl/libxl.h | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/tools/libxl/libxl.h b/tools/libxl/libxl.h
> index e6e0301..5ae6532 100644
> --- a/tools/libxl/libxl.h
> +++ b/tools/libxl/libxl.h
> @@ -579,8 +579,6 @@ typedef struct libxl__ctx libxl_ctx;
>   */
>  #define LIBXL_HAVE_CPUPOOL_NAME 1
>  
> -typedef struct libxl__ctx libxl_ctx;
> -

Sigh, this duplicated definition sneaked in again.

Thanks for fixing this.

Wei.

>  typedef uint8_t libxl_mac[6];
>  #define LIBXL_MAC_FMT "%02hhx:%02hhx:%02hhx:%02hhx:%02hhx:%02hhx"
>  #define LIBXL_MAC_FMTLEN ((2*6)+5) /* 6 hex bytes plus 5 colons */
> -- 
> 1.9.3

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] Fix builind error for old gcc
  2014-07-11  8:53 ` Wei Liu
@ 2014-07-11 11:18   ` Ian Campbell
  0 siblings, 0 replies; 3+ messages in thread
From: Ian Campbell @ 2014-07-11 11:18 UTC (permalink / raw
  To: Wei Liu; +Cc: Wen Congyang, xen-devel

On Fri, 2014-07-11 at 09:53 +0100, Wei Liu wrote:
> (There's typo in subject line)

I rewrote the commit log a bit and applied, thanks.

Ian.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-07-11 11:18 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-11  3:32 [PATCH] Fix builind error for old gcc Wen Congyang
2014-07-11  8:53 ` Wei Liu
2014-07-11 11:18   ` Ian Campbell

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.