From: Reid Spencer Date: Mon, 6 Dec 2004 05:35:13 +0000 (+0000) Subject: Add the check target so all projects can have this X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=9e8d54a0594dd063de2530d4bb1611771f5b7161;p=oota-llvm.git Add the check target so all projects can have this functionality. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18566 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/Makefile.rules b/Makefile.rules index d2d0556f9ee..a160c02d30b 100644 --- a/Makefile.rules +++ b/Makefile.rules @@ -20,10 +20,10 @@ # Define the various target sets #-------------------------------------------------------------------- RecursiveTargets := all clean clean-all install uninstall install-bytecode -LocalTargets := all-local clean-local clean-all-local \ +LocalTargets := all-local clean-local clean-all-local check-local \ install-local printvars uninstall-local \ install-bytecode-local -TopLevelTargets := dist dist-check dist-clean tags dist-gzip dist-bzip2 \ +TopLevelTargets := check dist dist-check dist-clean tags dist-gzip dist-bzip2 \ dist-zip UserTargets := $(RecursiveTargets) $(LocalTargets) $(TopLevelTargets) InternalTargets := preconditions distdir dist-hook @@ -1089,6 +1089,23 @@ endif endif +############################################################################### +# CHECK: Running the test suite +############################################################################### + +check:: + $(Verb) if test -d "$(BUILD_OBJ_ROOT)/test" ; then \ + if test -f "$(BUILD_OBJ_ROOT)/test/Makefile" ; then \ + $(EchoCmd) Running test suite ; \ + $(MAKE) -C $(BUILD_OBJ_ROOT)/test check-local \ + TESTSUITE=$(TESTSUITE) ; \ + else \ + $(EchoCmd) No Makefile in test directory ; \ + fi ; \ + else \ + $(EchoCmd) No test directory ; \ + fi + ############################################################################### # DISTRIBUTION: Handle construction of a distribution tarball ############################################################################### @@ -1212,7 +1229,7 @@ $(DistDir)/.makedistdir: $(DistSources) fi ; \ $(EchoCmd) Removing old $(DistDir) ; \ $(RM) -rf $(DistDir); \ - $(EchoCmd) Making 'all' to be sure. ; \ + $(EchoCmd) Making 'all' to verify build ; \ $(MAKE) all ; \ fi $(Echo) Building Distribution Directory $(DistDir) @@ -1296,7 +1313,7 @@ endif ifeq ($(LEVEL),.) #------------------------------------------------------------------------ -# Install support for project's include files: +# Install support for the project's include files: #------------------------------------------------------------------------ install-local:: $(Echo) Installing include files