summaryrefslogtreecommitdiff
path: root/sysutils/xentools3
diff options
context:
space:
mode:
authorjoerg <joerg@pkgsrc.org>2013-04-11 19:57:51 +0000
committerjoerg <joerg@pkgsrc.org>2013-04-11 19:57:51 +0000
commite441ebed12521528c8ca5be7d24f3c880abd2a71 (patch)
treea48bd646c2a7b3e6340b8037d55ab035cbba1f29 /sysutils/xentools3
parentdcceeb788f49a4372be2f50b5e1727fa5ae6cade (diff)
downloadpkgsrc-e441ebed12521528c8ca5be7d24f3c880abd2a71.tar.gz
Allow building Xen infrastructure with Clang. Fix various bugs in
xenkernel3, xenkernel41, xentools3 and xentools41 exposed by Clang default warnings. Bump revisions for those.
Diffstat (limited to 'sysutils/xentools3')
-rw-r--r--sysutils/xentools3/Makefile14
-rw-r--r--sysutils/xentools3/distinfo7
-rw-r--r--sysutils/xentools3/patches/patch-.._patch-Config.mk17
-rw-r--r--sysutils/xentools3/patches/patch-cg21
-rw-r--r--sysutils/xentools3/patches/patch-libxc_xc__dom__x86.c22
5 files changed, 68 insertions, 13 deletions
diff --git a/sysutils/xentools3/Makefile b/sysutils/xentools3/Makefile
index 8319d414c67..d2bd5e6ea35 100644
--- a/sysutils/xentools3/Makefile
+++ b/sysutils/xentools3/Makefile
@@ -1,10 +1,10 @@
-# $NetBSD: Makefile,v 1.32 2013/04/06 13:01:27 rodent Exp $
+# $NetBSD: Makefile,v 1.33 2013/04/11 19:57:52 joerg Exp $
#
VERSION= 3.1.4
DISTNAME= xen-${VERSION}
PKGNAME= xentools3-${VERSION}
-PKGREVISION= 13
+PKGREVISION= 14
CATEGORIES= sysutils
MASTER_SITES= http://bits.xensource.com/oss-xen/release/${VERSION}/
@@ -137,6 +137,16 @@ CONF_FILES_PERMS+= ${EGDIR}/${s} ${PKG_SYSCONFDIR}/scripts/${s} \
OWN_DIRS= ${PKG_SYSCONFDIR}/scripts /var/log/xen
+.include "../../mk/compiler.mk"
+.if !empty(PKGSRC_COMPILER:Mclang)
+EXTRA_HOSTCFLAGS+= -Wno-error=ignored-attributes -Wno-error=format-security
+EXTRA_CFLAGS+= -Wno-error=ignored-attributes -no-integrated-as \
+ -Wno-error=tautological-compare -Wno-error=null-dereference \
+ -Wno-error=self-assign -Wno-error=sometimes-uninitialized
+.endif
+
+MAKE_ENV+= EXTRA_HOSTCFLAGS=${EXTRA_HOSTCFLAGS:Q} EXTRA_CFLAGS=${EXTRA_CFLAGS:Q}
+
pre-build:
.if !exists(/usr/include/xen/xenio.h)
${MKDIR} ${WRKSRC}/libxc/xen
diff --git a/sysutils/xentools3/distinfo b/sysutils/xentools3/distinfo
index b441ec49313..ccdbd6ff261 100644
--- a/sysutils/xentools3/distinfo
+++ b/sysutils/xentools3/distinfo
@@ -1,9 +1,9 @@
-$NetBSD: distinfo,v 1.15 2012/05/14 15:39:52 manu Exp $
+$NetBSD: distinfo,v 1.16 2013/04/11 19:57:52 joerg Exp $
SHA1 (xen-3.1.4.tar.gz) = 0d784662776239195df10b3f29d40350f9d0644d
RMD160 (xen-3.1.4.tar.gz) = c02ad2bd64e6306b127a4f37a8aa370dadc11859
Size (xen-3.1.4.tar.gz) = 6894493 bytes
-SHA1 (patch-.._patch-Config.mk) = af18346fb13d1dc9e56e7d01057d2cebfbbaba14
+SHA1 (patch-.._patch-Config.mk) = 5ce1a561c8e358ceff4187b7109702c85fa29af8
SHA1 (patch-aa) = dca8b8de73b9bdbb17f8245224575eb881cdf00d
SHA1 (patch-ab) = dcafc8b6c4cd1e4dfc6f4ec806fd8076b3104b86
SHA1 (patch-ac) = d6d895e0361194cd84da13c42e17e17efecae7dd
@@ -31,7 +31,7 @@ SHA1 (patch-cb) = 0bf2513749e28ff955caabd76bf79dd8280b61ed
SHA1 (patch-cc) = 3e618c7da953115e7b3c7fe07f17b75ef2c2bb34
SHA1 (patch-cd) = a692eea5dcbf90536ffbbd2b934772bdefda5664
SHA1 (patch-cf) = 05c5e86d33d31a2216c2751a2bf684c8d5d06746
-SHA1 (patch-cg) = 36073c7327f187702203108b3e7596178aac3327
+SHA1 (patch-cg) = e01915fc13291920106318b30681719cd226ff53
SHA1 (patch-ch) = ebe2aedf1ecd1dce66f4a8a25ef5e83ee1d4c60d
SHA1 (patch-cj) = 5227c180e9ec2cf7146ade6f250f6bdff8f2bda1
SHA1 (patch-ck) = 3783d9b4b9344670bae2f35e2ac7f11e2ec9ce7b
@@ -63,5 +63,6 @@ SHA1 (patch-dk) = 5685f52835885635eacd305945653f817bbe8a2a
SHA1 (patch-dl) = 480b515da8773e4d3cfc305d74f833f16bb12750
SHA1 (patch-dm) = af4b849dfb54454e08acd0618afc0a81572bcbc3
SHA1 (patch-dn) = 1b6490b8f75ab9fe4d66d444fdacdde7db38131d
+SHA1 (patch-libxc_xc__dom__x86.c) = 098e42cef3a5e34b1b4b941d9f8709e8a97e60f6
SHA1 (patch-python_xen_util_xmlrpcclient.py) = 227db87dee15cfb7bedd67d6c118983b4dae2e34
SHA1 (patch-python_xen_util_xmlrpclib2.py) = 0fc01ed0511ccff6942453f3592a6939b60ab0c0
diff --git a/sysutils/xentools3/patches/patch-.._patch-Config.mk b/sysutils/xentools3/patches/patch-.._patch-Config.mk
index 5776172af84..04128e65e5c 100644
--- a/sysutils/xentools3/patches/patch-.._patch-Config.mk
+++ b/sysutils/xentools3/patches/patch-.._patch-Config.mk
@@ -1,8 +1,17 @@
-$NetBSD: patch-.._patch-Config.mk,v 1.1 2011/12/07 15:22:28 joerg Exp $
+$NetBSD: patch-.._patch-Config.mk,v 1.2 2013/04/11 19:57:52 joerg Exp $
--- ../Config.mk.orig 2011-12-07 10:40:48.000000000 +0000
+++ ../Config.mk
-@@ -70,7 +70,7 @@ CFLAGS += -Wall -Wstrict-prototypes
+@@ -19,7 +19,7 @@ SHELL ?= /bin/sh
+ # Tools to run on system hosting the build
+ HOSTCC = gcc
+ HOSTCFLAGS = -Wall -Werror -Wstrict-prototypes -O2 -fomit-frame-pointer
+-HOSTCFLAGS += -fno-strict-aliasing
++HOSTCFLAGS += -fno-strict-aliasing ${EXTRA_HOSTCFLAGS}
+ HOSTCFLAGS_x86_32 = -m32
+ HOSTCFLAGS_x86_64 = -m64
+ HOSTCFLAGS += $(HOSTCFLAGS_$(XEN_COMPILE_ARCH))
+@@ -70,10 +70,11 @@ CFLAGS += -Wall -Wstrict-prototypes
# -Wunused-value makes GCC 4.x too aggressive for my taste: ignoring the
# result of any casted expression causes a warning.
@@ -11,3 +20,7 @@ $NetBSD: patch-.._patch-Config.mk,v 1.1 2011/12/07 15:22:28 joerg Exp $
HOSTCFLAGS += $(call cc-option,$(HOSTCC),-Wdeclaration-after-statement,)
CFLAGS += $(call cc-option,$(CC),-Wdeclaration-after-statement,)
++CFLAGS += ${EXTRA_CFLAGS}
+
+ LDFLAGS += $(foreach i, $(EXTRA_LIB), -L$(i))
+ CFLAGS += $(foreach i, $(EXTRA_INCLUDES), -I$(i))
diff --git a/sysutils/xentools3/patches/patch-cg b/sysutils/xentools3/patches/patch-cg
index beb75034982..29f197b22c7 100644
--- a/sysutils/xentools3/patches/patch-cg
+++ b/sysutils/xentools3/patches/patch-cg
@@ -1,7 +1,7 @@
-$NetBSD: patch-cg,v 1.2 2007/11/17 16:45:32 bouyer Exp $
+$NetBSD: patch-cg,v 1.3 2013/04/11 19:57:52 joerg Exp $
---- xenstat/xentop/xentop.c.orig 2007-05-18 16:45:21.000000000 +0200
-+++ xenstat/xentop/xentop.c 2007-11-17 14:50:57.000000000 +0100
+--- xenstat/xentop/xentop.c.orig 2008-04-25 13:03:12.000000000 +0000
++++ xenstat/xentop/xentop.c
@@ -18,7 +18,8 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
@@ -24,7 +24,16 @@ $NetBSD: patch-cg,v 1.2 2007/11/17 16:45:32 bouyer Exp $
#include <xenstat.h>
-@@ -740,10 +745,11 @@
+@@ -251,7 +256,7 @@ static void fail(const char *str)
+ {
+ if(cwin != NULL && !isendwin())
+ endwin();
+- fprintf(stderr, str);
++ fprintf(stderr, "%s", str);
+ exit(1);
+ }
+
+@@ -752,10 +757,11 @@ void do_summary(void)
unsigned i, num_domains = 0;
unsigned long long used = 0;
xenstat_domain *domain;
@@ -38,7 +47,7 @@ $NetBSD: patch-cg,v 1.2 2007/11/17 16:45:32 bouyer Exp $
num_domains = xenstat_node_num_domains(cur_node);
ver_str = xenstat_node_xen_version(cur_node);
print("xentop - %s Xen %s\n", time_str, ver_str);
-@@ -909,6 +915,7 @@
+@@ -921,6 +927,7 @@ void do_network(xenstat_domain *domain)
/* Output all VBD information */
void do_vbd(xenstat_domain *domain)
{
@@ -46,7 +55,7 @@ $NetBSD: patch-cg,v 1.2 2007/11/17 16:45:32 bouyer Exp $
int i = 0;
xenstat_vbd *vbd;
unsigned num_vbds = 0;
-@@ -933,6 +940,7 @@
+@@ -952,6 +959,7 @@ void do_vbd(xenstat_domain *domain)
xenstat_vbd_rd_reqs(vbd),
xenstat_vbd_wr_reqs(vbd));
}
diff --git a/sysutils/xentools3/patches/patch-libxc_xc__dom__x86.c b/sysutils/xentools3/patches/patch-libxc_xc__dom__x86.c
new file mode 100644
index 00000000000..0deecb72121
--- /dev/null
+++ b/sysutils/xentools3/patches/patch-libxc_xc__dom__x86.c
@@ -0,0 +1,22 @@
+$NetBSD: patch-libxc_xc__dom__x86.c,v 1.1 2013/04/11 19:57:52 joerg Exp $
+
+--- libxc/xc_dom_x86.c.orig 2013-03-25 20:08:33.000000000 +0000
++++ libxc/xc_dom_x86.c
+@@ -418,7 +418,7 @@ static int start_info_x86_32(struct xc_d
+ xc_dom_printf("%s: called\n", __FUNCTION__);
+
+ memset(start_info, 0, sizeof(*start_info));
+- sprintf(start_info->magic, dom->guest_type);
++ snprintf(start_info->magic, sizeof(start_info->magic), "%s", dom->guest_type);
+ start_info->nr_pages = dom->total_pages;
+ start_info->shared_info = shinfo << PAGE_SHIFT_X86;
+ start_info->pt_base = dom->pgtables_seg.vstart;
+@@ -457,7 +457,7 @@ static int start_info_x86_64(struct xc_d
+ xc_dom_printf("%s: called\n", __FUNCTION__);
+
+ memset(start_info, 0, sizeof(*start_info));
+- sprintf(start_info->magic, dom->guest_type);
++ snprintf(start_info->magic, sizeof(start_info->magic), "%s", dom->guest_type);
+ start_info->nr_pages = dom->total_pages;
+ start_info->shared_info = shinfo << PAGE_SHIFT_X86;
+ start_info->pt_base = dom->pgtables_seg.vstart;