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

[Xen-changelog] [xen-unstable] build: Get rid of some more hardcoded install paths



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1238502650 -3600
# Node ID b3daeb123b6fb238483137a1f4d9295e44b749f4
# Parent  0faf7b884711a958d9073edb64d191d9a07fc064
build: Get rid of some more hardcoded install paths
Signed-off-by: Christoph Egger <Christoph.Egger@xxxxxxx>
---
 Config.mk             |    6 ++++--
 config/StdGNU.mk      |    3 ++-
 tools/pygrub/Makefile |    2 +-
 tools/python/Makefile |   10 +++++-----
 4 files changed, 12 insertions(+), 9 deletions(-)

diff -r 0faf7b884711 -r b3daeb123b6f Config.mk
--- a/Config.mk Tue Mar 31 13:28:45 2009 +0100
+++ b/Config.mk Tue Mar 31 13:30:50 2009 +0100
@@ -19,14 +19,16 @@ HOSTCFLAGS += -fno-strict-aliasing
 
 DISTDIR     ?= $(XEN_ROOT)/dist
 DESTDIR     ?= /
-DOCDIR      ?= /usr/share/doc/xen
-MANDIR      ?= /usr/share/man
 
 # Allow phony attribute to be listed as dependency rather than fake target
 .PHONY: .phony
 
 include $(XEN_ROOT)/config/$(XEN_OS).mk
 include $(XEN_ROOT)/config/$(XEN_TARGET_ARCH).mk
+
+SHAREDIR    ?= $(PREFIX)/share
+DOCDIR      ?= $(SHAREDIR)/doc/xen
+MANDIR      ?= $(SHAREDIR)/man
 
 ifneq ($(EXTRA_PREFIX),)
 EXTRA_INCLUDES += $(EXTRA_PREFIX)/include
diff -r 0faf7b884711 -r b3daeb123b6f config/StdGNU.mk
--- a/config/StdGNU.mk  Tue Mar 31 13:28:45 2009 +0100
+++ b/config/StdGNU.mk  Tue Mar 31 13:30:50 2009 +0100
@@ -31,7 +31,8 @@ LIBDIR_x86_32 = $(PREFIX)/$(LIBLEAFDIR_x
 LIBDIR_x86_32 = $(PREFIX)/$(LIBLEAFDIR_x86_32)
 LIBDIR_x86_64 = $(PREFIX)/$(LIBLEAFDIR_x86_64)
 LIBEXEC = $(LIBDIR_x86_32)/xen/bin
-MANDIR = $(PREFIX)/share/man
+SHAREDIR = $(PREFIX)/share
+MANDIR = $(SHAREDIR)/man
 MAN1DIR = $(MANDIR)/man1
 MAN8DIR = $(MANDIR)/man8
 SBINDIR = $(PREFIX)/sbin
diff -r 0faf7b884711 -r b3daeb123b6f tools/pygrub/Makefile
--- a/tools/pygrub/Makefile     Tue Mar 31 13:28:45 2009 +0100
+++ b/tools/pygrub/Makefile     Tue Mar 31 13:30:50 2009 +0100
@@ -12,7 +12,7 @@ ifndef XEN_PYTHON_NATIVE_INSTALL
 ifndef XEN_PYTHON_NATIVE_INSTALL
 install: LIBPATH=$(shell PYTHONPATH=../python/xen/util python -c "import 
auxbin; print auxbin.libpath()")
 install: all
-       CC="$(CC)" CFLAGS="$(CFLAGS)" python setup.py install 
--home="$(DESTDIR)/usr" --prefix="" --install-lib="$(DESTDIR)$(LIBPATH)/python"
+       CC="$(CC)" CFLAGS="$(CFLAGS)" python setup.py install 
--home="$(DESTDIR)$(PREFIX)" --prefix="" 
--install-lib="$(DESTDIR)$(LIBDIR)/python"
        $(INSTALL_DIR) $(DESTDIR)/var/run/xend/boot
 else
 install: all
diff -r 0faf7b884711 -r b3daeb123b6f tools/python/Makefile
--- a/tools/python/Makefile     Tue Mar 31 13:28:45 2009 +0100
+++ b/tools/python/Makefile     Tue Mar 31 13:30:50 2009 +0100
@@ -12,7 +12,7 @@ POTFILE := $(PODIR)/xen-xm.pot
 POTFILE := $(PODIR)/xen-xm.pot
 I18NSRCFILES = $(shell find xen/xm/ -name '*.py')
 CATALOGS = $(patsubst %,xen/xm/messages/%.mo,$(LINGUAS))
-NLSDIR = /usr/share/locale
+NLSDIR = $(SHAREDIR)/locale
 
 .PHONY: build buildpy
 buildpy: 
@@ -57,19 +57,19 @@ ifndef XEN_PYTHON_NATIVE_INSTALL
 ifndef XEN_PYTHON_NATIVE_INSTALL
 install: LIBPATH=$(shell PYTHONPATH=xen/util python -c "import auxbin; print 
auxbin.libpath()")
 install: install-messages install-dtd
-       CC="$(CC)" CFLAGS="$(CFLAGS)" python setup.py install 
--home="$(DESTDIR)/usr" --prefix="" --force 
--install-lib="$(DESTDIR)$(LIBPATH)/python"
+       CC="$(CC)" CFLAGS="$(CFLAGS)" python setup.py install 
--home="$(DESTDIR)$(PREFIX)" --prefix="" --force 
--install-lib="$(DESTDIR)$(LIBDIR)/python"
 else
 install: install-messages install-dtd
        CC="$(CC)" CFLAGS="$(CFLAGS)" python setup.py install 
--root="$(DESTDIR)" --force
 endif
 
 install-dtd: all
-       $(INSTALL_DIR) $(DESTDIR)/usr/share/xen
-       $(INSTALL_DATA) xen/xm/create.dtd $(DESTDIR)/usr/share/xen
+       $(INSTALL_DIR) $(DESTDIR)$(DOCDIR)
+       $(INSTALL_DATA) xen/xm/create.dtd $(DESTDIR)$(DOCDIR)
 
 install-messages: all
        set -e; if which $(MSGFMT) >/dev/null ; then \
-               mkdir -p $(DESTDIR)$(NLSDIR); \
+               $(INSTALL_DIR) $(DESTDIR)$(NLSDIR); \
                for l in $(LINGUAS); do \
                        $(INSTALL_DIR) $(DESTDIR)$(NLSDIR)/$$l; \
                        $(INSTALL_DIR) $(DESTDIR)$(NLSDIR)/$$l/LC_MESSAGES; \

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.