Changeset 2275


Ignore:
Timestamp:
Jan 22, 2007, 9:53:23 PM (14 years ago)
Author:
orlov
Message:
  • Try to find Visual C++ and Platform SDK automatically.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • to-imperative/trunk/c++/config-VS.bat

    r2274 r2275  
    33rem -1- C++ environment
    44
    5 rem : If you haven't registered environment variables for using Platform
    6 rem : SDK or want to use libraries shipped with Visual Studio then call
    7 rem : appropriate batch file which sets the environment.
    8 
    9 rem : Example for Platform SDK:
    10 call "%ProgramFiles%\Microsoft Platform SDK for Windows Server 2003 R2\SetEnv" /RETAIL
    11 
    12 rem : Also if you don't use Visual Studio then call appropriate batch to
    13 rem : configure C++ compiler.
    14 rem : The following sets environment for using Microsoft Visual C++ 2005
    15 rem : Express Edition:
    16 call "%VS80COMNTOOLS%\vsvars32.bat"
    17 
    18 rem : Example for using Microsoft Visual C++ Toolkit 2003:
    19 rem call "%VCToolkitInstallDir%\vcvars32.bat"
     5rem : Try to set the environment for using Microsoft Visual C++
     6if defined VS80COMNTOOLS (
     7        call "%VS80COMNTOOLS%\vsvars32.bat"
     8) else if defined VS71COMNTOOLS (
     9        call "%VS71COMNTOOLS%\vsvars32.bat"
     10) else if defined VCToolkitInstallDir (
     11        call "%VCToolkitInstallDir%\vcvars32.bat"
     12) else if defined VS70COMNTOOLS (
     13        call "%VS70COMNTOOLS%\vsvars32.bat"
     14) else (
     15        echo Can't find Visual C++ installed.
     16        echo Try manually set path to appropriate vcvars32.bat
     17        echo in section -1- in %~f0.
     18)
    2019
    2120rem : If you want to use another version of Visual Studio
    22 rem : or Visual C++ then change the path to run vcvars32.bat for that
    23 rem : version.
     21rem : or Visual C++ then call the vcvars32.bat for that
     22rem : version instead of the code above.
     23
     24
     25rem : Try to find Platform SDK
     26if exist "%ProgramFiles%\Microsoft Platform SDK for Windows Server 2003 R2\SetEnv.*" (
     27        call "%ProgramFiles%\Microsoft Platform SDK for Windows Server 2003 R2\SetEnv" /RETAIL
     28) else if exist "%ProgramFiles%\Microsoft Platform SDK\SetEnv.*" (
     29        call "%ProgramFiles%\Microsoft Platform SDK\SetEnv" /RETAIL
     30)
     31
     32rem : If you don't use Visual Studio and have Platform SDK installed in
     33rem : nonstandard location then call appropriate batch file which sets the
     34rem : environment instead of the code above.
     35
    2436
    2537rem -2- Refal+ options
    2638
    2739set RFLAGS=-B "%~dp0\..\lib"
     40
    2841
    2942rem -3- C++ compiler options
     
    3851
    3952set CFLAGS=%CFLAGS% /O2
     53
    4054
    4155rem -4- Linker options
     
    5367rem set LFLAGS=%LFLAGS% /STACK:8388608
    5468
     69
    5570rem -5- Auxiliary
    5671
Note: See TracChangeset for help on using the changeset viewer.