Ignore:
Timestamp:
2014-05-15T16:50:01+12:00 (10 years ago)
Author:
ak19
Message:

Before calling VS bat file, pushd into there and then popd out of it after the call. Also changed the many comments to just the current commands attempted to get VS12 and 10 to work and which failed, with notes on why only VS9 works for us at present.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • local/greenstone2/windows-64bit/setup32.bat

    r29053 r29059  
    1515echo + Set PERL_PATH=%PERL_HOME% and updated PATH
    1616
    17 :: WORKS:
    18 call "C:\Program Files (x86)\Microsoft Visual Studio 9.0\Common7\Tools\vsvars32.bat"
     17:: Setup Visual Studio env
    1918
    20 :: Common Tools folder not found
    21 :: call "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\vcvars32.bat"
     19:: Running VS in 64 bit mode doesn't work, need to run in 32 bit mode.
     20:: For now only VS9.0 (VS2008) works
     21:: call "C:\Program Files (x86)\Microsoft Visual Studio 9.0\Common7\Tools\vsvars32.bat"
     22set vslocation=C:\Program Files (x86)\Microsoft Visual Studio 9.0\Common7\Tools
     23if not exist "%vslocation%" echo %vslocation% does not exist& goto done
     24pushd "%vslocation%"
     25call vsvars32.bat
     26popd
    2227
    23 :: Same problem as with C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\amd64_x86\vcvarsamd64_x86.bat
    24 :: call "C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\Tools\vsvars32.bat"
     28:: VS10 fails: Common Tools folder not found for VS10
     29rem call "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\vcvars32.bat"
    2530
    26 
    27 :: 64 bit mode doesn't work
    28 :: Running vcvarsamd64_x86 has the same problem as below
    29 ::set vclocation=C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC
    30 ::set vclocation=C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC
    31 ::::set vclocation=C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\amd64_x86
    32 ::if not exist "%vclocation%" echo %vclocation% does not exist& goto done
    33 ::pushd "%vclocation%"
    34 ::call vcvarsamd64_x86.bat
    35 ::::call vcvarsall.bat amd64
    36 ::popd
    37 
     31:: VS12 fails: Calling "vsvars32.bat" above produces the same error as calling
     32:: C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\amd64_x86\vcvarsamd64_x86.bat
     33:: (and possibly the same error as calling
     34:: C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat without passing "amd64" param)
     35rem call "C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\Tools\vsvars32.bat"
    3836
    3937:: Error: https://groups.google.com/forum/#!topic/UniMRCP/Iybpn51UYnI
     
    4139:: http://stackoverflow.com/questions/11544563/can-i-set-the-platform-toolset-from-the-command-line-when-building-with-vs2010s
    4240:: /p:PlatformToolset=v100
    43 :: call "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\amd64_x86\vcvarsamd64_x86.bat"
    4441
    4542
    46 :: If using SetEnv.cmd:
    47 
    48 :: http://go4answers.webhost4life.com/Example/windows-sdk-v70a-setenvbat-218785.aspx
    49 :: explains that SetEnv.cmd does exist in the new Microsoft SDK:
    50 :: C:\Windows\System32\cmd.exe /E:ON /V:ON /T:0E /K "C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\SetEnv.cmd"
    51 :: (Unused: http://stackoverflow.com/questions/887894/how-to-find-windows-sdks-setenv-cmd-setenv-cmd-does-not-work-correctly )
     43:: If using SetEnv.cmd to set up MS SDK env (no longer needed even for compiling GS2 with debug):
    5244
    5345::call "C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\SetEnv.cmd"
     
    6052::popd
    6153
    62 :: http://www.apachelounge.com/viewtopic.php?t=3348
    63 :: http://stackoverflow.com/questions/10888391/error-link-fatal-error-lnk1123-failure-during-conversion-to-coff-file-inval
    64 :: https://ask.mozilla.org/question/256/failure-during-conversion-to-coff-file-invalid-or-corrupt/
    65 :: Rename cvtres.exe in C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\amd64, then put the one from
    66 :: C:\Windows\Microsoft.NET\Framework\v4.0.30319 (or from C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\amd64) in there
    67 ::set cvlocation=C:\Windows\Microsoft.NET\Framework\v4.0.30319
    68 ::set cvlocation=C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\amd64
    69 ::if exist "%cvlocation%\cvtres.exe" set PATH=%cvlocation%;%PATH%
     54
    7055
    7156:done
     
    7459echo.
    7560
    76 :: http://stackoverflow.com/questions/10888391/error-link-fatal-error-lnk1123-failure-during-conversion-to-coff-file-inval
Note: See TracChangeset for help on using the changeset viewer.