2004-11-07 06:05:37 +01:00
|
|
|
#===- test/Makefile ----------------------------------------*- Makefile -*--===#
|
|
|
|
#
|
|
|
|
# The LLVM Compiler Infrastructure
|
|
|
|
#
|
|
|
|
# This file was developed by the LLVM research group and is distributed under
|
|
|
|
# the University of Illinois Open Source License. See LICENSE.TXT for details.
|
|
|
|
#
|
|
|
|
#===------------------------------------------------------------------------===#
|
|
|
|
|
2001-11-05 01:22:16 +01:00
|
|
|
LEVEL = ..
|
2004-09-05 10:18:23 +02:00
|
|
|
DIRS =
|
2002-01-23 22:36:59 +01:00
|
|
|
|
2003-09-06 17:12:21 +02:00
|
|
|
#
|
2004-12-04 07:25:08 +01:00
|
|
|
# Make Dejagnu the default for testing
|
2003-09-06 17:12:21 +02:00
|
|
|
#
|
2004-12-06 06:35:38 +01:00
|
|
|
all:: check-local
|
2003-09-06 17:12:21 +02:00
|
|
|
|
2003-10-27 18:46:42 +01:00
|
|
|
# Include other test rules
|
|
|
|
include Makefile.tests
|
|
|
|
|
2004-11-07 06:05:37 +01:00
|
|
|
#===------------------------------------------------------------------------===#
|
|
|
|
# DejaGNU testing support
|
|
|
|
#===------------------------------------------------------------------------===#
|
|
|
|
|
2004-11-07 22:39:41 +01:00
|
|
|
ifdef TESTSUITE
|
2004-12-12 22:39:49 +01:00
|
|
|
CLEANED_TESTSUITE := $(patsubst %/,%,$(TESTSUITE))
|
|
|
|
RUNTESTFLAGS := --tool $(CLEANED_TESTSUITE)
|
2004-11-07 22:39:41 +01:00
|
|
|
endif
|
|
|
|
|
2004-12-06 06:35:38 +01:00
|
|
|
check-local:: site.exp
|
2005-07-13 02:35:12 +02:00
|
|
|
PATH="$(LLVMToolDir):$(LLVMExmplDir):$(LLVM_SRC_ROOT)/test/Scripts:$(PATH)" \
|
2004-11-08 06:44:05 +01:00
|
|
|
$(RUNTEST) $(RUNTESTFLAGS)
|
2004-11-07 22:39:41 +01:00
|
|
|
|
2004-12-04 07:25:08 +01:00
|
|
|
clean::
|
2004-11-07 06:05:37 +01:00
|
|
|
$(RM) -rf `find $(LLVM_OBJ_ROOT)/test/Regression -name Output -type d -print`
|
2004-12-04 07:47:07 +01:00
|
|
|
$(RM) -rf `find $(LLVM_OBJ_ROOT)/test/Feature -name Output -type d -print`
|
2004-11-07 05:59:52 +01:00
|
|
|
|
|
|
|
site.exp: Makefile $(LLVM_OBJ_ROOT)/Makefile.config
|
|
|
|
@echo 'Making a new site.exp file...'
|
|
|
|
@echo '## these variables are automatically generated by make ##' >site.tmp
|
|
|
|
@echo '# Do not edit here. If you wish to override these values' >>site.tmp
|
|
|
|
@echo '# edit the last section' >>site.tmp
|
2006-04-13 22:33:59 +02:00
|
|
|
@echo 'set target_triplet "$(TARGET_TRIPLE)"' >> site.tmp
|
|
|
|
@echo 'set llvmgcc_version "$(LLVMGCC_VERSION)"' >> site.tmp
|
2004-11-30 20:13:06 +01:00
|
|
|
@echo 'set prcontext "$(TCLSH) $(LLVM_SRC_ROOT)/test/Scripts/prcontext.tcl"' >> site.tmp
|
2006-04-13 22:33:59 +02:00
|
|
|
@echo 'set srcdir "$(LLVM_SRC_ROOT)/test"' >>site.tmp
|
|
|
|
@echo 'set objdir "$(LLVM_OBJ_ROOT)/test"' >>site.tmp
|
2005-05-20 22:13:41 +02:00
|
|
|
@echo 'set llvmgcc "PATH=\"$(LLVMToolDir):$(PATH)\" \"$(LLVMGCC)\""' >> site.tmp
|
|
|
|
@echo 'set llvmgxx "PATH=\"$(LLVMToolDir):$(PATH)\" \"$(LLVMGCC)\""' >> site.tmp
|
2006-04-07 00:22:08 +02:00
|
|
|
@echo 'set llvmgccmajvers "$(LLVMGCC_MAJVERS)"' >> site.tmp
|
2004-11-07 05:59:52 +01:00
|
|
|
@echo '## All variables above are generated by configure. Do Not Edit ## ' >>site.tmp
|
|
|
|
@test ! -f site.exp || \
|
|
|
|
sed '1,/^## All variables above are.*##/ d' site.exp >> site.tmp
|
|
|
|
@-rm -f site.bak
|
|
|
|
@test ! -f site.exp || mv site.exp site.bak
|
|
|
|
@mv site.tmp site.exp
|