try_compile: Cleanup temporary directories (#13160)
Since commit 4fbdce2b
(try_compile: Use random executable file name,
2012-02-13) a different <target>.dir is used for each try-compile.
Cleanup the directories as well as their content to avoid accumulating
leftover temporary directories.
This commit is contained in:
parent
a7d0fb1470
commit
953257ca61
|
@ -404,6 +404,7 @@ void cmCoreTryCompile::CleanupFiles(const char* binDir)
|
||||||
if(cmSystemTools::FileIsDirectory(fullPath.c_str()))
|
if(cmSystemTools::FileIsDirectory(fullPath.c_str()))
|
||||||
{
|
{
|
||||||
this->CleanupFiles(fullPath.c_str());
|
this->CleanupFiles(fullPath.c_str());
|
||||||
|
cmSystemTools::RemoveADirectory(fullPath.c_str());
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue