Share via


DIRS

The DIRS macro is used to specify a list of subdirectories that the Build utility will build every time that it runs. This macro is only used within the Dirs file.

Subdirectory names in the list specified by the DIRS macro must be separated by spaces or tabs. Each subdirectory name is relative to the directory that contains the Dirs file.

You can build subdirectories based on the build platform architecture. For example:

OPTIONAL_DIRS =\
 dir1{i386,ia64,amd64} \
 dir2{i386}

In this example, dir1 is built for all three common architectures, while dir2 is only built under a Windows Driver Kit (WDK) x86 build environment. If the WDK build environment is ia64 or amd64, only dir1 is built.

Subdirectories can also be built based on a specified type by using the following Type keywords:

  • Test
    Specifies one or more subdirectories that are built for components not related to the driver package. For example, you may want to mark a subdirectory with the Test keyword for components that are being tested and may be merged into the driver package later.

  • Tool
    Specifies one or more subdirectories that contain tools related to the driver package.

  • Product
    Specifies one or more subdirectories that contain the components of the driver package.

Each subdirectory can only be decorated with one Type keyword. For example:

OPTIONAL_DIRS =\
 dir1{Test} \
 dir2{Tool} \
 dir3{Product}

Use the DirInclude command-line parameter of the Build utility to build subdirectories based on the Type keyword. For example:

will build only those subdirectories decorated with the Test or Tool keywords.

Example

The following example instructs the Build utility to build the subdirectories in the order in which they are specified by the DIRS macro:

DIRS=\
      directoryA \
      directoryB \
      directoryC

See Also

Dirs File

Driver Package

 

 

Send comments about this topic to Microsoft

Build date: 5/3/2011