Description: Simple Python install layout for Debian based systems
 Ported from origin below (Xen-3.4), which is a follower of
 previous version from ubuntu Xen-3.3 sources
 xen-3.3-3.3.0/debian/patches/use-python-2.6.diff
 Drivers: User Virtual <virtualusr@xxxxxxxxx>
 URL: http://virtualusr.wordpress.com
Origin: https://bugs.launchpad.net/ubuntu/+source/xen-3.3/+bug/378240/+attachment/662345/+files/xen-3.4_3.4.1-1ubuntu1.diff.gz
Index: xen-4.0-4.0.1/tools/pygrub/Makefile
===================================================================
--- xen-4.0-4.0.1.orig/tools/pygrub/Makefile	2010-08-25 10:22:42.000000000 +0200
+++ xen-4.0-4.0.1/tools/pygrub/Makefile	2011-01-04 19:08:18.556582404 +0100
@@ -11,7 +11,8 @@
 .PHONY: install
 install: all
 	CC="$(CC)" CFLAGS="$(CFLAGS)" $(PYTHON) setup.py install \
-		$(PYTHON_PREFIX_ARG) --root="$(DESTDIR)" --force
+		$(PYTHON_PREFIX_ARG) --root="$(DESTDIR)" --force \
+		$(if $(filter y,$(DEBIANBASE)),--install-layout=deb)
 	$(INSTALL_PYTHON_PROG) src/pygrub $(DESTDIR)/$(BINDIR)/pygrub
 	$(INSTALL_DIR) $(DESTDIR)/var/run/xend/boot
 
Index: xen-4.0-4.0.1/tools/python/Makefile
===================================================================
--- xen-4.0-4.0.1.orig/tools/python/Makefile	2010-08-25 10:22:42.000000000 +0200
+++ xen-4.0-4.0.1/tools/python/Makefile	2011-01-04 19:08:18.556582404 +0100
@@ -60,7 +60,8 @@
 .PHONY: install
 install: install-messages install-dtd
 	CC="$(CC)" CFLAGS="$(CFLAGS)" $(PYTHON) setup.py install \
-		$(PYTHON_PREFIX_ARG) --root="$(DESTDIR)" --force
+		$(PYTHON_PREFIX_ARG) --root="$(DESTDIR)" --force \
+		$(if $(filter y,$(DEBIANBASE)),--install-layout=deb)
 
 install-dtd: all
 	$(INSTALL_DIR) $(DESTDIR)$(SHAREDIR)/xen
Index: xen-4.0-4.0.1/tools/security/Makefile
===================================================================
--- xen-4.0-4.0.1.orig/tools/security/Makefile	2010-08-25 10:22:42.000000000 +0200
+++ xen-4.0-4.0.1/tools/security/Makefile	2011-01-04 19:08:18.556582404 +0100
@@ -61,7 +61,8 @@
 	$(INSTALL_DIR) $(DESTDIR)$(ACM_SECGEN_CGIDIR)
 	$(INSTALL_PROG) $(ACM_INST_CGI) $(DESTDIR)$(ACM_SECGEN_CGIDIR)
 	$(PYTHON) python/setup.py install $(PYTHON_PREFIX_ARG) \
-		--root="$(DESTDIR)" --force
+		--root="$(DESTDIR)" --force \
+		$(if $(filter y,$(DEBIANBASE)),--install-layout=deb)
 else
 .PHONY: all
 all: