3 # this file attempts to provide all of the variables needed for compiling
4 # with the microsoft visual studio compiler (dot net version). it requires
5 # one environment variable (called VSxCOMNTOOLS) be set that points at the
6 # location of the common tools in the visual studio installation.
7 # The value of x can be 80, 90 or 100.
10 echo "The VS80COMNTOOLS, VS90COMNTOOLS and VS100COMNTOOLS variables are not set."
11 echo "This usually means that the Visual Studio compiler is not installed."
15 chmod 755 $PRODUCTION_DIR/win32_helper/*.exe
16 export PATH=$PRODUCTION_DIR/win32_helper:$PATH
18 # we try to use the most recent compiler location, and work backwards as
19 # needed for the supported range (10 = vs 2010, 9 = vs 2008, 8 = vs 2005).
20 export VSxTOOLS="$VS100COMNTOOLS"
21 if [ -z "$VSxTOOLS" ]; then
22 export VSxTOOLS="$VS90COMNTOOLS"
23 if [ -z "$VSxTOOLS" ]; then
24 export VSxTOOLS="$VS80COMNTOOLS"
28 if [ -z "$VSxTOOLS" ]; then
32 export VSxTOOLS="$(short_path "$VSxTOOLS" | tr "A-Z" "a-z" | sed -e 's/\\/\//g' | sed -e 's/^\(.\):/\/\1/' )"
34 export VIS_STU_ROOT="$(echo $VSxTOOLS | sed -e 's/^\(.*\)\/[^\/]*\/[^\/]*[\/]$/\1/' | sed -e 's/^\(.\):/\/\1/' )"
35 export VSINSTALLDIR="$VIS_STU_ROOT"
37 export WINDIR="$(short_path "$WINDIR" | sed -e 's/\\/\//g' | sed -e 's/^\(.\):/\/\1/' )"
39 export VCINSTALLDIR="$VSINSTALLDIR/VC"
40 export VSCOMMONROOT="$VSINSTALLDIR/Common7"
41 export VS_TOOLS_DIR="$VSCOMMONROOT/tools"
42 export DevEnvDir="$VSCOMMONROOT/IDE"
43 export MSVCDir="$VCINSTALLDIR"
44 export FrameworkDir="$WINDIR/Microsoft.NET/Framework"
45 export FrameworkVersion=v4.0.30319
46 #old export FrameworkSDKDir="$VSINSTALLDIR/SDK/v2.0"
48 export PLATFORM_DIR="$VCINSTALLDIR/PlatformSDK"
49 if [ ! -d "$PLATFORM_DIR" ]; then
50 export PLATFORM_DIR="$(short_path "$PROGRAMFILES/Microsoft SDKs/Windows/v7.0A" | tr "A-Z" "a-z" | sed -e 's/^\(.*\)\/[^\/]*\/[^\/]*[\/]$/\1/' | sed -e 's/^\(.\):/\/\1/' )"
52 export WindowsSdkDir="$PLATFORM_DIR"
54 echo "path before is $PATH"
55 export PATH="$DevEnvDir:$VCINSTALLDIR/BIN:$VSxTOOLS:$VSxTOOLS/bin:$FrameworkDir/$FrameworkVersion:$FrameworkDir/v3.5:$VCINSTALLDIR/VCPackages:$VSINSTALLDIR/Common7/Tools:$PLATFORM_DIR/bin:$PATH"
56 echo "path after is $PATH"
58 export INCLUDE="$VCINSTALLDIR/ATLMFC/INCLUDE:$VCINSTALLDIR/INCLUDE:$PLATFORM_DIR/include"
59 #:$FrameworkSDKDir/include"
61 export LIB="$VCINSTALLDIR/ATLMFC/LIB:$VCINSTALLDIR/LIB:$PLATFORM_DIR/lib"
62 #:$FrameworkSDKDir/lib"
64 # convert framework dir back or things yell like hell.
65 export FrameworkDir=$(msys_to_dos_path $FrameworkDir)
66 # the redirection of stderr to null is to get around an obnoxious cygwin
67 # warning that seems to be erroneously bitching about backslashes.
69 # mark this as executable because we will need it.
70 #chmod 755 $FEISTY_MEOW_SCRIPTS/generator/wrapdoze.sh
72 # convert all other relevant paths back to dos form, or visual studio barfs.
73 #export BUILD_SCRIPTS_DIR=$(msys_to_dos_path $BUILD_SCRIPTS_DIR)
74 #export BUILDING_HIERARCHY=$(msys_to_dos_path $BUILDING_HIERARCHY)
75 #export BUILDER_DIR=$(msys_to_dos_path $BUILDER_DIR)
76 #export BUILD_TOP=$(msys_to_dos_path $BUILD_TOP)
77 #export PRODUCTION_DIR=$(msys_to_dos_path $PRODUCTION_DIR)
78 #export LOGS_DIR=$(msys_to_dos_path $LOGS_DIR)
79 #export TOOL_SOURCES=$(msys_to_dos_path $TOOL_SOURCES)
80 #export BINARY_DIR=$(msys_to_dos_path $BINARY_DIR)
81 #export TARGETS_DIR=$(msys_to_dos_path $TARGETS_DIR)
82 #export INTERMEDIATE_EXE_DIR=$(msys_to_dos_path $INTERMEDIATE_EXE_DIR)
83 #export WASTE_DIR=$(msys_to_dos_path $WASTE_DIR)
87 echo "common tools dir is \"$VSxTOOLS\""
88 echo cleaned windir is $WINDIR
89 echo cleaned comn tools is $VSxTOOLS
90 echo root of visual studio is $VSINSTALLDIR
91 echo platform dir is $PLATFORM_DIR
92 echo framedir now $FrameworkDir