[PATCH 12/12] Compile libvirt under Windows (Cygwin)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Miscellaneous minor fixes for the tests/ subdirectory.

Rich.

--
Emerging Technologies, Red Hat - http://et.redhat.com/~rjones/
Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod
Street, Windsor, Berkshire, SL4 1TE, United Kingdom.  Registered in
England and Wales under Company Registration No. 03798903
Index: tests/Makefile.am
===================================================================
RCS file: /data/cvs/libvirt/tests/Makefile.am,v
retrieving revision 1.28
diff -u -r1.28 Makefile.am
--- tests/Makefile.am	18 Nov 2007 11:23:09 -0000	1.28
+++ tests/Makefile.am	24 Nov 2007 17:07:16 -0000
@@ -70,63 +70,65 @@
 	@top_srcdir@/src/xmlrpc.c \
 	@top_srcdir@/src/xmlrpc.h
 
-xmlrpctest_LDFLAGS =
+LIBOBJDIR = ../src/
+
+xmlrpctest_LDFLAGS = $(LIBOBJS)
 xmlrpctest_LDADD = $(LDADDS)
 
 xml2sexprtest_SOURCES = \
 	xml2sexprtest.c \
 	testutils.c testutils.h
-xml2sexprtest_LDFLAGS =
+xml2sexprtest_LDFLAGS = $(LIBOBJS)
 xml2sexprtest_LDADD = $(LDADDS)
 
 sexpr2xmltest_SOURCES = \
 	sexpr2xmltest.c \
 	testutils.c testutils.h
-sexpr2xmltest_LDFLAGS =
+sexpr2xmltest_LDFLAGS = $(LIBOBJS)
 sexpr2xmltest_LDADD = $(LDADDS)
 
 xmconfigtest_SOURCES = \
 	xmconfigtest.c \
 	testutils.c testutils.h
-xmconfigtest_LDFLAGS =
+xmconfigtest_LDFLAGS = $(LIBOBJS)
 xmconfigtest_LDADD = $(LDADDS)
 
 qemuxml2argvtest_SOURCES = \
 	qemuxml2argvtest.c \
 	testutils.c testutils.h
-qemuxml2argvtest_LDFLAGS =
+qemuxml2argvtest_LDFLAGS = $(LIBOBJS)
 qemuxml2argvtest_LDADD = $(LDADDS)
 
 qemuxml2xmltest_SOURCES = \
 	qemuxml2xmltest.c \
 	testutils.c testutils.h
-qemuxml2xmltest_LDFLAGS =
+qemuxml2xmltest_LDFLAGS = $(LIBOBJS)
 qemuxml2xmltest_LDADD = $(LDADDS)
 
 virshtest_SOURCES = \
 	virshtest.c \
 	testutils.c testutils.h
-virshtest_LDFLAGS =
+virshtest_LDFLAGS = $(LIBOBJS)
 virshtest_LDADD = $(LDADDS)
 
 conftest_SOURCES = \
 	conftest.c
-conftest_LDFLAGS =
+conftest_LDFLAGS = $(LIBOBJS)
 conftest_LDADD = $(LDADDS)
 
 xencapstest_SOURCES = \
 	xencapstest.c testutils.h testutils.c
-xencapstest_LDFLAGS =
+xencapstest_LDFLAGS = $(LIBOBJS)
 xencapstest_LDADD = $(LDADDS)
 
 nodeinfotest_SOURCES = \
 	nodeinfotest.c testutils.h testutils.c
-nodeinfotest_LDFLAGS =
+nodeinfotest_LDFLAGS = $(LIBOBJS)
 nodeinfotest_LDADD = $(LDADDS)
 
 reconnect_SOURCES = \
 	reconnect.c
-reconnect_LDFLAGS =
+reconnect_LDFLAGS = $(LIBOBJS)
 reconnect_LDADD = $(LDADDS)
 
 $(LIBVIRT):
Index: tests/nodeinfotest.c
===================================================================
RCS file: /data/cvs/libvirt/tests/nodeinfotest.c,v
retrieving revision 1.2
diff -u -r1.2 nodeinfotest.c
--- tests/nodeinfotest.c	14 Nov 2007 10:35:59 -0000	1.2
+++ tests/nodeinfotest.c	24 Nov 2007 17:07:16 -0000
@@ -1,7 +1,11 @@
+#include "config.h"
+
 #include <stdio.h>
 #include <stdlib.h>
 
-#include "config.h"
+#ifdef HAVE_SYS_SYSLIMITS_H
+#include <sys/syslimits.h>
+#endif
 
 #include <string.h>
 
Index: tests/qemuxml2argvtest.c
===================================================================
RCS file: /data/cvs/libvirt/tests/qemuxml2argvtest.c,v
retrieving revision 1.7
diff -u -r1.7 qemuxml2argvtest.c
--- tests/qemuxml2argvtest.c	14 Nov 2007 10:35:59 -0000	1.7
+++ tests/qemuxml2argvtest.c	24 Nov 2007 17:07:16 -0000
@@ -1,9 +1,19 @@
+#include "config.h"
+
 #include <stdio.h>
+#include <stdlib.h>
+#include <unistd.h>
 #include <string.h>
 
 #include <sys/types.h>
 #include <fcntl.h>
 
+#ifdef HAVE_SYS_SYSLIMITS_H
+#include <sys/syslimits.h>
+#endif
+
+#ifdef WITH_QEMU
+
 #include "testutils.h"
 #include "qemu_conf.h"
 #include "internal.h"
@@ -187,6 +197,12 @@
     exit(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
 }
 
+#else
+
+int main (void) { exit (EXIT_SUCCESS); }
+
+#endif /* WITH_QEMU */
+
 /*
  * Local variables:
  *  indent-tabs-mode: nil
Index: tests/qemuxml2xmltest.c
===================================================================
RCS file: /data/cvs/libvirt/tests/qemuxml2xmltest.c,v
retrieving revision 1.6
diff -u -r1.6 qemuxml2xmltest.c
--- tests/qemuxml2xmltest.c	14 Nov 2007 10:35:59 -0000	1.6
+++ tests/qemuxml2xmltest.c	24 Nov 2007 17:07:16 -0000
@@ -1,9 +1,19 @@
+#include "config.h"
+
 #include <stdio.h>
+#include <stdlib.h>
+#include <unistd.h>
 #include <string.h>
 
 #include <sys/types.h>
 #include <fcntl.h>
 
+#ifdef HAVE_SYS_SYSLIMITS_H
+#include <sys/syslimits.h>
+#endif
+
+#ifdef WITH_QEMU
+
 #include "testutils.h"
 #include "qemu_conf.h"
 #include "internal.h"
@@ -150,6 +160,12 @@
     exit(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
 }
 
+#else
+
+int main (void) { exit (EXIT_SUCCESS); }
+
+#endif /* WITH_QEMU */
+
 /*
  * Local variables:
  *  indent-tabs-mode: nil
Index: tests/sexpr2xmltest.c
===================================================================
RCS file: /data/cvs/libvirt/tests/sexpr2xmltest.c,v
retrieving revision 1.19
diff -u -r1.19 sexpr2xmltest.c
--- tests/sexpr2xmltest.c	20 Nov 2007 10:05:45 -0000	1.19
+++ tests/sexpr2xmltest.c	24 Nov 2007 17:07:16 -0000
@@ -1,6 +1,12 @@
+#include "config.h"
+
 #include <stdio.h>
 #include <string.h>
 
+#ifdef HAVE_SYS_SYSLIMITS_H
+#include <sys/syslimits.h>
+#endif
+
 #ifdef WITH_XEN
 #include "xml.h"
 #include "xend_internal.h"
Index: tests/virshtest.c
===================================================================
RCS file: /data/cvs/libvirt/tests/virshtest.c,v
retrieving revision 1.6
diff -u -r1.6 virshtest.c
--- tests/virshtest.c	14 Nov 2007 10:35:59 -0000	1.6
+++ tests/virshtest.c	24 Nov 2007 17:07:16 -0000
@@ -1,9 +1,14 @@
+#include "config.h"
 
 #include <stdio.h>
 #include <string.h>
 #include <unistd.h>
 #include <limits.h>
 
+#ifdef HAVE_SYS_SYSLIMITS_H
+#include <sys/syslimits.h>
+#endif
+
 #include "xml.h"
 #include "testutils.h"
 #include "internal.h"
Index: tests/xencapstest.c
===================================================================
RCS file: /data/cvs/libvirt/tests/xencapstest.c,v
retrieving revision 1.5
diff -u -r1.5 xencapstest.c
--- tests/xencapstest.c	14 Nov 2007 10:35:59 -0000	1.5
+++ tests/xencapstest.c	24 Nov 2007 17:07:16 -0000
@@ -1,7 +1,11 @@
+#include "config.h"
+
 #include <stdio.h>
 #include <stdlib.h>
 
-#include "config.h"
+#ifdef HAVE_SYS_SYSLIMITS_H
+#include <sys/syslimits.h>
+#endif
 
 #ifdef WITH_XEN
 
Index: tests/xmconfigtest.c
===================================================================
RCS file: /data/cvs/libvirt/tests/xmconfigtest.c,v
retrieving revision 1.7
diff -u -r1.7 xmconfigtest.c
--- tests/xmconfigtest.c	14 Nov 2007 10:35:59 -0000	1.7
+++ tests/xmconfigtest.c	24 Nov 2007 17:07:17 -0000
@@ -21,9 +21,15 @@
  *
  */
 
+#include "config.h"
+
 #include <stdio.h>
 #include <string.h>
 
+#ifdef HAVE_SYS_SYSLIMITS_H
+#include <sys/syslimits.h>
+#endif
+
 #ifdef WITH_XEN
 #include "xen_unified.h"
 #include "xm_internal.h"
Index: tests/xml2sexprtest.c
===================================================================
RCS file: /data/cvs/libvirt/tests/xml2sexprtest.c,v
retrieving revision 1.17
diff -u -r1.17 xml2sexprtest.c
--- tests/xml2sexprtest.c	20 Nov 2007 10:05:45 -0000	1.17
+++ tests/xml2sexprtest.c	24 Nov 2007 17:07:17 -0000
@@ -1,9 +1,15 @@
+#include "config.h"
+
 #include <stdio.h>
 #include <string.h>
 
 #include <sys/types.h>
 #include <fcntl.h>
 
+#ifdef HAVE_SYS_SYSLIMITS_H
+#include <sys/syslimits.h>
+#endif
+
 #include "xml.h"
 #include "testutils.h"
 #include "internal.h"

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

--
Libvir-list mailing list
Libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]