Merge topic 'test-update-svn-1.7-issue-12535'

6d79b50 Teach CTest.UpdateSVN to detect svn add --depth before using it
74eb86c Fix CTest.UpdateSVN with Subversion 1.7 (#12535)
This commit is contained in:
David Cole 2011-10-25 15:34:37 -04:00 committed by CMake Topic Stage
commit a17709974f
1 changed files with 11 additions and 1 deletions

View File

@ -23,6 +23,16 @@ file(MAKE_DIRECTORY ${TOP}/config)
set(SVNCMD ${SVN} --config-dir ${TOP}/config) set(SVNCMD ${SVN} --config-dir ${TOP}/config)
set(SVNUSER --username "test author" --non-interactive) set(SVNUSER --username "test author" --non-interactive)
# Configure for this svn version.
execute_process(
COMMAND ${SVN} help add OUTPUT_VARIABLE help_add ERROR_VARIABLE help_add
)
if("${help_add}" MATCHES "--depth")
set(depth_empty "--depth=empty")
else()
set(depth_empty "")
endif()
#----------------------------------------------------------------------------- #-----------------------------------------------------------------------------
# Initialize the testing directory. # Initialize the testing directory.
message("Creating test directory...") message("Creating test directory...")
@ -63,7 +73,7 @@ update_content(user-source files_added files_removed dirs_added)
if(dirs_added) if(dirs_added)
run_child( run_child(
WORKING_DIRECTORY ${TOP}/user-source WORKING_DIRECTORY ${TOP}/user-source
COMMAND ${SVNCMD} add ${dirs_added} COMMAND ${SVNCMD} add ${depth_empty} ${dirs_added}
) )
endif(dirs_added) endif(dirs_added)
run_child( run_child(