From: Ian Campbell <ian.campbell@citrix.com>
To: xen-devel@lists.xen.org
Cc: keir@xen.org, ian.jackson@eu.citrix.com,
Ian Campbell <ian.campbell@citrix.com>
Subject: [PATCH 2/9] tools: make building xend configurable.
Date: Wed, 31 Jul 2013 16:15:50 +0100 [thread overview]
Message-ID: <1375283757-19465-2-git-send-email-ian.campbell@citrix.com> (raw)
In-Reply-To: <1375283736.7382.100.camel@kazak.uk.xensource.com>
xend has been deprecated for 2 releases now. Lets make it possible to not even
build it.
For now I'm leaving the default of on but I would like to change that before
the 4.4 release.
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
---
config/Tools.mk.in | 1 +
tools/configure | 26 ++++++++++++++++++++++++++
tools/configure.ac | 1 +
tools/examples/Makefile | 33 ++++++++++++++++-----------------
tools/hotplug/Linux/Makefile | 5 ++++-
tools/hotplug/NetBSD/Makefile | 3 ++-
tools/python/Makefile | 10 ++++++++--
tools/python/setup.py | 35 ++++++++++++++++++++++++++---------
8 files changed, 84 insertions(+), 30 deletions(-)
diff --git a/config/Tools.mk.in b/config/Tools.mk.in
index 5e2c6d8..ef41c2a 100644
--- a/config/Tools.mk.in
+++ b/config/Tools.mk.in
@@ -52,6 +52,7 @@ CONFIG_LOMOUNT := @lomount@
CONFIG_OVMF := @ovmf@
CONFIG_ROMBIOS := @rombios@
CONFIG_SEABIOS := @seabios@
+CONFIG_XEND := @xend@
#System options
CONFIG_SYSTEM_LIBAIO:= @system_aio@
diff --git a/tools/configure b/tools/configure
index 079646c..6e2f758 100755
--- a/tools/configure
+++ b/tools/configure
@@ -654,6 +654,7 @@ APPEND_LIB
APPEND_INCLUDES
PREPEND_LIB
PREPEND_INCLUDES
+xend
debug
seabios
rombios
@@ -734,6 +735,7 @@ enable_ovmf
enable_rombios
enable_seabios
enable_debug
+enable_xend
'
ac_precious_vars='build_alias
host_alias
@@ -1394,6 +1396,7 @@ Optional Features:
--disable-rombios Disable ROM BIOS (default is ENABLED)
--disable-seabios Disable SeaBIOS (default is ENABLED)
--disable-debug Disable debug build of tools (default is ENABLED)
+ --disable-xend Disable xend toolstack (default is ENABLED)
Some influential environment variables:
CC C compiler command
@@ -3654,6 +3657,29 @@ debug=$ax_cv_debug
+# Check whether --enable-xend was given.
+if test "${enable_xend+set}" = set; then :
+ enableval=$enable_xend;
+fi
+
+
+if test "x$enable_xend" = "xno"; then :
+
+ ax_cv_xend="n"
+
+elif test "x$enable_xend" = "xyes"; then :
+
+ ax_cv_xend="y"
+
+elif test -z $ax_cv_xend; then :
+
+ ax_cv_xend="y"
+
+fi
+xend=$ax_cv_xend
+
+
+
diff --git a/tools/configure.ac b/tools/configure.ac
index 4f5e688..d6eba44 100644
--- a/tools/configure.ac
+++ b/tools/configure.ac
@@ -59,6 +59,7 @@ AX_ARG_DEFAULT_DISABLE([ovmf], [Enable OVMF])
AX_ARG_DEFAULT_ENABLE([rombios], [Disable ROM BIOS])
AX_ARG_DEFAULT_ENABLE([seabios], [Disable SeaBIOS])
AX_ARG_DEFAULT_ENABLE([debug], [Disable debug build of tools])
+AX_ARG_DEFAULT_ENABLE([xend], [Disable xend toolstack])
AC_ARG_VAR([PREPEND_INCLUDES],
[List of include folders to prepend to CFLAGS (without -I)])
diff --git a/tools/examples/Makefile b/tools/examples/Makefile
index 8cea724..cc853fa 100644
--- a/tools/examples/Makefile
+++ b/tools/examples/Makefile
@@ -1,31 +1,30 @@
XEN_ROOT = $(CURDIR)/../..
include $(XEN_ROOT)/tools/Rules.mk
-# Init scripts.
-XEND_INITD = init.d/xend
-XENDOMAINS_INITD = init.d/xendomains
-XENDOMAINS_SYSCONFIG = init.d/sysconfig.xendomains
-
# Xen configuration dir and configs to go there.
XEN_READMES = README
XEN_READMES += README.incompatibilities
-XEN_CONFIGS = xend-config.sxp
-XEN_CONFIGS += xm-config.xml
-XEN_CONFIGS += xmexample1
-XEN_CONFIGS += xmexample2
-XEN_CONFIGS += xmexample3
-XEN_CONFIGS += xmexample.hvm
-XEN_CONFIGS += xmexample.hvm-stubdom
-XEN_CONFIGS += xmexample.pv-grub
-XEN_CONFIGS += xmexample.nbd
-XEN_CONFIGS += xmexample.vti
+
+XEN_CONFIGS-$(CONFIG_XEND) += xend-config.sxp
+XEN_CONFIGS-$(CONFIG_XEND) += xm-config.xml
+XEN_CONFIGS-$(CONFIG_XEND) += xmexample1
+XEN_CONFIGS-$(CONFIG_XEND) += xmexample2
+XEN_CONFIGS-$(CONFIG_XEND) += xmexample3
+XEN_CONFIGS-$(CONFIG_XEND) += xmexample.hvm
+XEN_CONFIGS-$(CONFIG_XEND) += xmexample.hvm-stubdom
+XEN_CONFIGS-$(CONFIG_XEND) += xmexample.pv-grub
+XEN_CONFIGS-$(CONFIG_XEND) += xmexample.nbd
+XEN_CONFIGS-$(CONFIG_XEND) += xmexample.vti
+XEN_CONFIGS-$(CONFIG_XEND) += xend-pci-quirks.sxp
+XEN_CONFIGS-$(CONFIG_XEND) += xend-pci-permissive.sxp
+
XEN_CONFIGS += xlexample.hvm
XEN_CONFIGS += xlexample.pvlinux
-XEN_CONFIGS += xend-pci-quirks.sxp
-XEN_CONFIGS += xend-pci-permissive.sxp
XEN_CONFIGS += xl.conf
XEN_CONFIGS += cpupool
+XEN_CONFIGS += $(XEN_CONFIGS-y)
+
.PHONY: all
all:
diff --git a/tools/hotplug/Linux/Makefile b/tools/hotplug/Linux/Makefile
index 8b0d7f4..b7737ab 100644
--- a/tools/hotplug/Linux/Makefile
+++ b/tools/hotplug/Linux/Makefile
@@ -28,7 +28,8 @@ XEN_SCRIPT_DATA += xen-hotplug-common.sh xen-network-common.sh vif-common.sh
XEN_SCRIPT_DATA += block-common.sh
UDEV_RULES_DIR = $(CONFIG_DIR)/udev
-UDEV_RULES = xen-backend.rules xend.rules
+UDEV_RULES-$(CONFIG_XEND) = xend.rules
+UDEV_RULES = xen-backend.rules $(UDEV_RULES-y)
.PHONY: all
all:
@@ -44,7 +45,9 @@ install: all install-initd install-scripts install-udev
install-initd:
[ -d $(DESTDIR)$(INITD_DIR) ] || $(INSTALL_DIR) $(DESTDIR)$(INITD_DIR)
[ -d $(DESTDIR)$(SYSCONFIG_DIR) ] || $(INSTALL_DIR) $(DESTDIR)$(SYSCONFIG_DIR)
+ifeq ($(CONFIG_XEND),y)
$(INSTALL_PROG) $(XEND_INITD) $(DESTDIR)$(INITD_DIR)
+endif
$(INSTALL_PROG) $(XENDOMAINS_INITD) $(DESTDIR)$(INITD_DIR)
$(INSTALL_DATA) $(XENDOMAINS_SYSCONFIG) $(DESTDIR)$(SYSCONFIG_DIR)/xendomains
$(INSTALL_PROG) $(XENCOMMONS_INITD) $(DESTDIR)$(INITD_DIR)
diff --git a/tools/hotplug/NetBSD/Makefile b/tools/hotplug/NetBSD/Makefile
index 2ae5a34..3d7f222 100644
--- a/tools/hotplug/NetBSD/Makefile
+++ b/tools/hotplug/NetBSD/Makefile
@@ -8,7 +8,8 @@ XEN_SCRIPTS += vif-bridge
XEN_SCRIPTS += vif-ip
XEN_SCRIPT_DATA =
-XEN_RCD_PROG = rc.d/xencommons rc.d/xend rc.d/xendomains rc.d/xen-watchdog
+XEN_RCD_PROG-$(CONFIG_XEND) = rc.d/xend
+XEN_RCD_PROG = rc.d/xencommons $(XEN_RCD_PROG-y) rc.d/xendomains rc.d/xen-watchdog
.PHONY: all
all:
diff --git a/tools/python/Makefile b/tools/python/Makefile
index 8461d0f..3d0f8f0 100644
--- a/tools/python/Makefile
+++ b/tools/python/Makefile
@@ -16,20 +16,26 @@ build: genpath genwrap.py $(XEN_ROOT)/tools/libxl/libxl_types.idl \
$(XEN_ROOT)/tools/libxl/libxl_types.idl \
xen/lowlevel/xl/_pyxl_types.h \
xen/lowlevel/xl/_pyxl_types.c
- CC="$(CC)" CFLAGS="$(CFLAGS)" $(PYTHON) setup.py build
+ CC="$(CC)" CFLAGS="$(CFLAGS)" $(PYTHON) setup.py build --xend=$(CONFIG_XEND)
.PHONY: install
install: install-dtd
CC="$(CC)" CFLAGS="$(CFLAGS)" $(PYTHON) setup.py install \
- $(PYTHON_PREFIX_ARG) --root="$(DESTDIR)" --force
+ $(PYTHON_PREFIX_ARG) --root="$(DESTDIR)" --force --xend=$(CONFIG_XEND)
$(INSTALL_DIR) $(DESTDIR)$(SBINDIR)
+ifeq ($(CONFIG_XEND),y)
$(INSTALL_PYTHON_PROG) xen/xm/xm $(DESTDIR)$(SBINDIR)/xm
$(INSTALL_PYTHON_PROG) xen/xend/xend $(DESTDIR)$(SBINDIR)/xend
+endif
install-dtd: all
+ifeq ($(CONFIG_XEND),y)
$(INSTALL_DIR) $(DESTDIR)$(SHAREDIR)/xen
$(INSTALL_DATA) xen/xm/create.dtd $(DESTDIR)$(SHAREDIR)/xen
+else
+ :
+endif
.PHONY: test
test:
diff --git a/tools/python/setup.py b/tools/python/setup.py
index 42a70fc..4f66564 100644
--- a/tools/python/setup.py
+++ b/tools/python/setup.py
@@ -1,6 +1,6 @@
from distutils.core import setup, Extension
-import os
+import os, sys
XEN_ROOT = "../.."
@@ -95,11 +95,19 @@ if plat == 'SunOS':
if plat == 'Linux':
modules.extend([ checkpoint, netlink ])
-setup(name = 'xen',
- version = '3.0',
- description = 'Xen',
- packages = ['xen',
- 'xen.lowlevel',
+enable_xend = True
+new_argv = []
+for arg in sys.argv:
+ if arg == "--xend=y":
+ enable_xend = True
+ elif arg == "--xend=n":
+ enable_xend = False
+ else:
+ new_argv.append(arg)
+sys.argv = new_argv
+
+if enable_xend:
+ xend_packages = [
'xen.util',
'xen.util.xsm',
'xen.util.xsm.dummy',
@@ -110,14 +118,23 @@ setup(name = 'xen',
'xen.xend.xenstore',
'xen.xm',
'xen.web',
- 'xen.sv',
- 'xen.xsview',
'xen.remus',
'xen.xend.tests',
'xen.xend.server.tests',
'xen.xend.xenstore.tests',
'xen.xm.tests'
- ],
+ ]
+else:
+ xend_packages = []
+
+setup(name = 'xen',
+ version = '3.0',
+ description = 'Xen',
+ packages = ['xen',
+ 'xen.lowlevel',
+ 'xen.sv',
+ 'xen.xsview',
+ ] + xend_packages,
ext_package = "xen.lowlevel",
ext_modules = modules
)
--
1.7.2.5
next prev parent reply other threads:[~2013-07-31 15:15 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-31 15:15 [PATCH 0/9] tools: remove or disable old/useless/unused/unmainted stuff Ian Campbell
2013-07-31 15:15 ` [PATCH 1/9] tools: move xm and xend under tools python Ian Campbell
2013-08-07 15:03 ` Ian Jackson
2013-07-31 15:15 ` Ian Campbell [this message]
2013-08-07 15:04 ` [PATCH 2/9] tools: make building xend configurable Ian Jackson
2013-07-31 15:15 ` [PATCH 3/9] tools: remove in tree libaio Ian Campbell
2013-08-01 8:38 ` Egger, Christoph
2013-08-01 14:39 ` Ian Campbell
2013-08-07 15:06 ` Ian Jackson
2013-08-08 9:07 ` Ian Campbell
2013-08-20 14:28 ` Ian Campbell
2013-07-31 15:15 ` [PATCH 4/9] tools: delete xsview Ian Campbell
2013-08-07 15:06 ` Ian Jackson
2013-07-31 15:15 ` [PATCH 5/9] tools: remove miniterm Ian Campbell
2013-08-07 15:07 ` Ian Jackson
2013-07-31 15:15 ` [PATCH 6/9] tools: remove lomount Ian Campbell
2013-08-07 15:08 ` Ian Jackson
2013-07-31 15:15 ` [PATCH 7/9] .*ignore: remove some cruft Ian Campbell
2013-08-07 15:09 ` Ian Jackson
2013-07-31 15:15 ` [PATCH 8/9] tools: disable blktap1 build by default Ian Campbell
2013-08-07 15:13 ` Ian Jackson
2013-07-31 15:15 ` [PATCH 9/9] tools: drop 'sv' Ian Campbell
2013-08-07 15:13 ` Ian Jackson
2013-07-31 15:29 ` [PATCH 0/9] tools: remove or disable old/useless/unused/unmainted stuff Andrew Cooper
2013-07-31 15:35 ` Ian Campbell
2013-07-31 15:57 ` Andrew Cooper
2013-07-31 16:37 ` Andrew Cooper
2013-08-01 6:11 ` Matt Wilson
2013-08-20 15:03 ` Ian Campbell
2013-08-12 14:53 ` Fabio Fantoni
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1375283757-19465-2-git-send-email-ian.campbell@citrix.com \
--to=ian.campbell@citrix.com \
--cc=ian.jackson@eu.citrix.com \
--cc=keir@xen.org \
--cc=xen-devel@lists.xen.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).