summaryrefslogtreecommitdiffstats
path: root/tools/win
diff options
context:
space:
mode:
authorgrt@chromium.org <grt@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-08-03 20:37:47 +0000
committergrt@chromium.org <grt@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-08-03 20:37:47 +0000
commit8e65fd3196240e703e235fc4d59cfb6ece788c8f (patch)
tree2687021098e2f7a5456d29c52e028ea183cf639f /tools/win
parente2e004bdb9d8d13d45b1db637bbad7bdd4a3ef4a (diff)
downloadchromium_src-8e65fd3196240e703e235fc4d59cfb6ece788c8f.zip
chromium_src-8e65fd3196240e703e235fc4d59cfb6ece788c8f.tar.gz
chromium_src-8e65fd3196240e703e235fc4d59cfb6ece788c8f.tar.bz2
Handle chrome.dll.pdb properly when incremental_chrome_dll is set.
Also: - speed up re-copies the XP/xcopy case by skipping old files - clean up output for re-copies in the robocopy case by ignoring "extra" files NOTRY=true BUG=none TEST=none Review URL: https://chromiumcodereview.appspot.com/10837096 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@149912 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'tools/win')
-rwxr-xr-xtools/win/copy-installer.bat44
1 files changed, 24 insertions, 20 deletions
diff --git a/tools/win/copy-installer.bat b/tools/win/copy-installer.bat
index 9a7f3b3..0e563de5 100755
--- a/tools/win/copy-installer.bat
+++ b/tools/win/copy-installer.bat
@@ -57,27 +57,25 @@ SET TOCOPY=*.pdb mini_installer.exe
SET INSTALLER=mini_installer.exe
)
-REM Branch to handle copying via robocopy (fast) or xcopy (slow).
-robocopy /? 1> nul 2> nul
-IF "%ERRORLEVEL%"=="9009" GOTO _xcopy else GOTO _robocopy
-
-REM robocopy is rsync, basically.
-:_robocopy
-robocopy "%FROM%" "%TO%" %TOCOPY% /J /MT
-GOTO _copydone
+CALL :_copyfiles
-REM xcopy is not.
-:_xcopy
-IF NOT exist "%TO%" mkdir "%TO%"
-call :_xcopy_hack %TOCOPY%
-GOTO _copydone
+REM incremental_chrome_dll=1 puts chrome_dll.pdb into the "initial" dir.
+IF EXIST "%FROM%\initial" (
+SET FROM=%FROM%\initial
+SET TOCOPY=*.pdb
+CALL :_copyfiles
+)
-:_copydone
ECHO Ready to run/debug %TO%\%INSTALLER%.
GOTO :EOF
REM All labels henceforth are subroutines intended to be invoked by CALL.
+REM Canonicalize the first argument, returning it in RET.
+:_canonicalize
+SET RET=%~f1
+GOTO :EOF
+
REM Search for a mini_installer.exe in the candidate build outputs.
:_find_build
IF "%OUTPUT%"=="" (
@@ -105,15 +103,21 @@ GOTO :EOF
)
GOTO :EOF
+REM Branch to handle copying via robocopy (fast) or xcopy (slow).
+:_copyfiles
+robocopy /? 1> nul 2> nul
+IF NOT "%ERRORLEVEL%"=="9009" (
+robocopy "%FROM%" "%TO%" %TOCOPY% /J /MT /XX
+) ELSE (
+IF NOT EXIST "%TO%" mkdir "%TO%"
+call :_xcopy_hack %TOCOPY%
+)
+GOTO :EOF
+
REM We can't use a for..in..do loop since we have wildcards, so we make a call
REM to this with the files to copy.
:_xcopy_hack
SHIFT
IF "%0"=="" GOTO :EOF
-xcopy "%FROM%\%0" "%TO%" /y
+xcopy "%FROM%\%0" "%TO%" /d /y
GOTO _xcopy_hack
-
-REM Canonicalize the first argument, returning it in RET.
-:_canonicalize
-SET RET=%~f1
-GOTO :EOF