Export (0) Print
Expand All

TARGET_DESTINATION

Use the TARGET_DESTINATION macro to specify a destination directory for BinPlace files.

TARGET_DESTINATION is any valid destination for a BinPlace target. The value of the macro is the path, relative to _NTTREE, in which the files are put.

Multiple paths can be delimited by using a colon.

Syntax


TARGET_DESTINATION = Destination

Parameters

Destination

This parameter specifies the destination directory or the reserved name for one of the special cases. The reserved names are shown in the following table.

Reserved nameDescription

retail

Files go to the root of _NTTREE

windows

Files go to the root of _NTTREE

drivers

Files go to _NTTREE\system32\drivers

drvetc

Files go to _NTTREE\system32\drivers\etc

config

Files go to _NTTREE\system32\config

system

Files go to _NTTREE\system32

system16

Files go to _NTTREE\system

printer

Files go to _NTTREE\system32\spool\drivers\w32<ProcArch>

prtprocs

Files go to _NTTREE\system32\spool\prtprocs\w32<MProcArch>

hal

Files go to _NTTREE\system32 for x86 and _NTTREE for amd64 or ia64

 

Comments

The TARGET_DESTINATION macro specifies the default target directory for the reserved directory names that were previously described. If a binary file is specified by using the TARGETNAME macro, the TARGET_DESTINATION macro also specifies the target directory for that file.

The TARGET_DESTINATION macro is applied only when BinPlace is enabled in a Windows Driver Kit (WDK) build environment. To enable BinPlace, you must specify the separate_object_root parameter of SetEnv.bat. For more information about this parameter, see Using the SetEnv.bat Command-Line.

For example, to specify the separate_object_root parameter for the Windows 7 x86 free build environment, follow these steps:

  1. From the Windows Start menu, click Windows Drivers Kit and then click the Windows 7 WDK entry.

  2. Click the Build Environment menu, and then click Windows 7.

  3. Right-click x86 Free Build Environment and select Properties.

  4. Click the Shortcut tab and add the separate_object_root parameter to the end of the Target command for the Build Environment as shown in the following example:
    
    C:\Windows\System32\cmd.exe /k C:\WinDDK\bin\setenv.bat C:\WinDDK\ fre x86 WIN7 separate_object_root
    
    

The PASSn_BINPLACE macros (where n is 0, 1, or 2) can override the TARGET_DESTINATION macro. To do this, within the FileList parameter of these macros you must add the following for each file:


-:DEST altDest FileName

You can use multiple instances of the -:DEST parameter. For more information, see PASS0_BINPLACE, PASS1_BINPLACE and PASS2_BINPLACE.

Example

To instruct BinPlaceto put files under %_nttree%\setup\sources\, use the following statement within the Sources file:


TARGET_DESTINATION=setup\sources

This setting puts the binary file in the specified location.

See Also

_NTTREE,
BinPlace,
PASS0_BINPLACE,
PASS1_BINPLACE,
PASS2_BINPLACE,
Sources file

 

 

Send comments about this topic to Microsoft

Build date: 5/3/2011

Show:
© 2014 Microsoft