Files
xen/tools/hotplug/common/Makefile
T
Keir Fraser a2b4af7d77 Get rid of hardcoded pathes for stubdom and hotplug scripts
- Have the buid system generate a file which exports the install paths
   for the hotplug scripts and stubdom / stubdom-dm
- Move file generation code from tools/python/Makefile into a gmake
   macro
  in Config.mk to avoid maintenance of three duplicates each with its
   own
  tweaks and bugs
- Export gmake variables into ioemu as shell variables
  for upcoming ioemu patches
- Do above as a gmake macro to avoid maintenance of several duplicates
- Adjust hotplug scripts to find the right xen binaries from the
  install directory
- Adjust stubdom-dm to use the install directories

Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
2009-06-23 17:25:51 +01:00

40 lines
789 B
Makefile

XEN_ROOT = ../../..
include $(XEN_ROOT)/tools/Rules.mk
HOTPLUGPATH="hotplugpath.sh"
# OS-independent hotplug scripts go in this directory
# Xen scripts to go there.
XEN_SCRIPTS = $(HOTPLUGPATH)
XEN_SCRIPT_DATA =
genpath-target = $(call buildmakevars2file,$(HOTPLUGPATH))
$(eval $(genpath-target))
.PHONY: all
all: build
.PHONY: build
build: genpath
.PHONY: install
install: all install-scripts
.PHONY: install-scripts
install-scripts:
[ -d $(DESTDIR)$(XEN_SCRIPT_DIR) ] || \
$(INSTALL_DIR) $(DESTDIR)$(XEN_SCRIPT_DIR)
set -e; for i in $(XEN_SCRIPTS); \
do \
$(INSTALL_PROG) $$i $(DESTDIR)$(XEN_SCRIPT_DIR); \
done
set -e; for i in $(XEN_SCRIPT_DATA); \
do \
$(INSTALL_DATA) $$i $(DESTDIR)$(XEN_SCRIPT_DIR); \
done
.PHONY: clean
clean:
rm -f $(HOTPLUGPATH)