File: gccxml_vcupdate.bat.in

package info (click to toggle)
gccxml 0.9.0%2Bcvs20100501-2
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 79,132 kB
  • ctags: 73,371
  • sloc: ansic: 751,436; cpp: 34,175; asm: 26,833; sh: 5,077; makefile: 4,696; lex: 589; awk: 566; perl: 334; yacc: 271; pascal: 86; python: 29
file content (52 lines) | stat: -rwxr-xr-x 1,519 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
@echo off
rem --------------------------------------------------------------------------
rem This is a driver script to update GCC-XML's support of new Visual Studio
rem installations.
rem --------------------------------------------------------------------------

set vcupdate=%0
if "%OS%" equ "Windows_NT" (goto winnt) else (goto non_winnt)

:winnt
rem Get absolute name of directory where this batch is
rem and strip double quotes
set vcupdate=%~dp0

rem Get the absolute name of the VC data directory
set directory="%vcupdate%\..\@VC_DATA_DIR@"
for %%T in (%directory%) do set vc_dir=%%~dfT

goto start

:non_winnt
rem Reference the TEMP directory in a safe way.
set vc_temp=%TEMP%.

rem Get the current working directory.
type "%vcupdate%\..\..\@VC_DATA_DIR@\VcInstall\vc_helper" > "%vc_temp%\vc_env_temp.bat"
cd >>"%vc_temp%\vc_env_temp.bat"
call "%vc_temp%\vc_env_temp.bat"
del "%vc_temp%\vc_env_temp.bat"
set cwd=%vc_result%

rem Change to the directory containing this script and get its location.
type "%vcupdate%\..\..\@VC_DATA_DIR@\VcInstall\vc_helper" > "%vc_temp%\vc_env_temp.bat"
cd /D "%vcupdate%\..\..\@VC_DATA_DIR@"
cd >>"%vc_temp%\vc_env_temp.bat"
call "%vc_temp%\vc_env_temp.bat"
del "%vc_temp%\vc_env_temp.bat"
set vc_dir=%vc_result%

set vcupdate=%vcupdate%\..

rem Change back to the original working directory.
cd /D "%cwd%"

goto start

:start

rem Run the installer executable to do the rest of the work.
"%vcupdate%\gccxml_vcconfig.exe" "%vc_dir%\VcInstall" "%vc_dir%"

if errorlevel 1 pause