From 17afd5257b31912195c93d1d1be585c06f8382d7 Mon Sep 17 00:00:00 2001 From: Zach Mullen Date: Mon, 9 Nov 2009 14:07:36 -0500 Subject: [PATCH] Bug 9090: CTest does not handle absolute paths in CTestTestfile SUBDIR( ) entries. The ctest subdirs command now checks the relative path first, and if that does not exist, also checks if the given path was absolute. Thanks vodall for the patch. --- Source/CTest/cmCTestTestHandler.cxx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Source/CTest/cmCTestTestHandler.cxx b/Source/CTest/cmCTestTestHandler.cxx index 56ddec7f1..d314052c8 100644 --- a/Source/CTest/cmCTestTestHandler.cxx +++ b/Source/CTest/cmCTestTestHandler.cxx @@ -86,6 +86,12 @@ bool cmCTestSubdirCommand fname += "/"; fname += *it; + //sanity check on relative path; if not, try absolute path + if ( !cmSystemTools::FileIsDirectory(fname.c_str())) + { + fname = *it; + } + if ( !cmSystemTools::FileExists(fname.c_str()) ) { // No subdirectory? So what...