From 4f0ecb702a601d122f261a134007377435e4aca1 Mon Sep 17 00:00:00 2001 From: Todd Gaunt Date: Mon, 3 Oct 2016 16:02:12 -0400 Subject: Add pharos-validator tool Change-Id: I38e077c2c90059e39ee9871abf5d867a875827a3 Signed-off-by: Todd Gaunt --- pharos-validator/Makefile | 56 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 pharos-validator/Makefile (limited to 'pharos-validator/Makefile') diff --git a/pharos-validator/Makefile b/pharos-validator/Makefile new file mode 100644 index 0000000..5569502 --- /dev/null +++ b/pharos-validator/Makefile @@ -0,0 +1,56 @@ +############################################################################## +# Copyright (c) 2015 Todd Gaunt and others. +# +# All rights reserved. This program and the accompanying materials +# are made available under the terms of the Apache License, Version 2.0 +# which accompanies this distribution, and is available at +# http://www.apache.org/licenses/LICENSE-2.0 +############################################################################## + +include config.mk + +# Variables passed down to subfolder make commands +export DESTDIR +export PREFIX + +SHELL=/bin/sh + +# Source paths +SRCDIR="src/" +PXE_INITRD=${SRCDIR}/pxe_initrd/ +VALIDATION_TOOL=${SRCDIR}/validation_tool/ + +# makefile names +PXE_MAKE=pxe_initrd.mk + + +all: validation_tool pxe_initrd + +########################################## +# The following forces rebuilding +########################################## +.PHONY: validation_tool ${VALIDATION_TOOL} +validation_tool: ${VALIDATION_TOOL} + +${VALIDATION_TOOL}: + pushd $@ && ./setup.py build && popd + +########################################## +# The following forces rebuilding +########################################## +.PHONY: pxe_initrd ${PXE_INITRD} +pxe_initrd: ${PXE_INITRD} + +${PXE_INITRD}: + ${MAKE} -C $@ -f ${PXE_MAKE} all +########################################## + +install: all + # Install the programs to the passed in PREFIX dir + ${MAKE} -C ${PXE_INITRD} -f ${PXE_MAKE} install + pushd ${VALIDATION_TOOL} && ./setup.py install --prefix=${DESTDIR}/${PREFIX} && popd + +.PHONY: clean +clean: + ${MAKE} -C ${PXE_INITRD} -f ${PXE_MAKE} clean + pushd ${VALIDATION_TOOL} && ./setup.py clean --all && popd -- cgit 1.2.3-korg