PLATFORM_ |
Please see the "options for commands" section of this manual for general information about the use of macros for configuration.
This defines where the Windows SDK that you wish to use is located (note that "Windows SDK" is the new name for the "Windows Platform SDK").
If you don't specify a value then MAKEMSI has a go at locating it (see below).
By default the value you set (or MAKEMSI determines) for this macro becomes the default value for the "INSTALLER_SDK_DIR" macro.
EXAMPLE |
This works on my computer:
#define? PLATFORM_SDK_DIR <??*ProgramFiles>\Microsoft Platform SDK for Windows XP SP2
HOW MAKEMSI Sets the Default Value |
This is how MAKEMSI determines the default value if you don't supply one:
#ifndef PLATFORM_SDK_DIR ;--- Not defined, define some locations to be checked ------------------- #( ';' #define? PLATFORM_SDK_DIR_LOOK_HERE_LIST ;<??*ProgramFiles>\Windows Installer 4.5 SDK ;;WI 4.5 SDK (can't use SDK buggy, missing required header files) <??*ProgramFiles>\Microsoft Platform SDK ;;Seems to be the standard location <??*ProgramFiles>\Microsoft Platform SDK for Windows Server 2003 R2 ;;From Kevin Keane in email dated 2 Jan 2008 <??*ProgramFiles>\Microsoft SDKs\Windows\v7.0 ;;SDK Version 4.5 as per email "guitargeeser" on 17 March 2010 <??*ProgramFiles>\Microsoft Platform SDK for Windows XP SP2 ;;Has worked in past (maybe I extracted it here)! <??*ProgramFiles>\Microsoft SDK ;;Has worked in past (maybe I extracted it here)! #) #( ';' #define? PLATFORM_SDK_DIR_LOOK_FOR_THESE_ENV_VARS_LIST ;--- List of SDK env vars provided by Kevin Keane in email dated 2+5 Jan 2008 --- INETSDK MSSdk Bkoffice MSSdk Mstools #) ;--- User already set it? ----------------------------------------------- #ifndef PLATFORM_SDK_DIR ;--- User hasn't set, Loop through the set of possible known locations --- #{ SET "@@Dir={;}<$PLATFORM_SDK_DIR_LOOK_HERE_LIST>" ;--- See if the directory exists -------------------------------- #if DirQueryExists('<??SET_@@DIR>') <> '' ;--- The directory exists so update the required definition --- #define PLATFORM_SDK_DIR <??SET_@@DIR> #break #endif #} #endif ;--- Found it in the above loop? ---------------------------------------- #ifndef PLATFORM_SDK_DIR ;--- Not found, look through list of env vars that are known to point here (if there exist) --- #{ SET "@@EnvVar={;}<$PLATFORM_SDK_DIR_LOOK_FOR_THESE_ENV_VARS_LIST>" ;--- Check this environment variable ---------------------------- #if GetEnv(SET_@@EnvVar) <> '' #evaluate "PLATFORM_SDK_DIR" "GetEnv(SET_@@EnvVar)" #break #endif #} ;--- If not found above then assign empty string -------------------- #define? PLATFORM_SDK_DIR #endif #info ^SDK: <$PLATFORM_SDK_DIR>^ #endif #define? INSTALLER_SDK_DIR <$PLATFORM_SDK_DIR> ;;We assume same dir as Platform SDK by default.