_Hit_
驱动牛犊
驱动牛犊
  • 注册日期2002-11-20
  • 最后登录2007-10-08
  • 粉丝0
  • 关注0
  • 积分57分
  • 威望7点
  • 贡献值0点
  • 好评度5点
  • 原创分0分
  • 专家分0分
阅读:2116回复:3

向经常写驱动的大哥问个问题。

楼主#
更多 发布于:2004-09-20 20:52
请问各位大哥,在DDK或IFS Kit下,我如何在SOURCE文件中 添加
我的cl.exe和link.exe编译选项,例如: /G7 /O2 /GL 等等。
好像平时很少见大家用,为什么啊?
KMK
KMK
驱动大牛
驱动大牛
  • 注册日期2001-09-12
  • 最后登录2017-10-06
  • 粉丝2
  • 关注0
  • 积分42分
  • 威望404点
  • 贡献值2点
  • 好评度58点
  • 原创分1分
  • 专家分1分
  • 社区居民
沙发#
发布于:2004-09-21 04:17
BUILD: Version 4.22.3667

Usage: BUILD [-?] display this message
        [-#] force _objects.mac to be regenerated
        [-0] pass 0 generation only, no compile, no link
        [-2] same as old -Z (only do a 2 pass build - no pass 0)
        [-3] same as -Z
        [-a] allows synchronized blocks and drains during link pass
        [-b] displays full error message text (doesn't truncate)
        [-B [baseline]] Checks the build failures against a baseline
                If there is no baseline,terminates the build on the first error
        [-c] deletes all object files
        [-C] deletes all .lib files only
        [-D] check dependencies before building (on by default if BUILD_PRODUCT != NT)
        [-e] generates build.log, build.wrn & build.err files
        [-E] always keep the log/wrn/err files (use with -z)
        [-f] force rescan of all source and include files
        [-F] when displaying errors/warnings to stdout, print the full path
        [-g] Display warnings/errors/summary in color
        [-h] Hide console output
        [-G] enables target specific dirs files iff one target
        [-i] ignore extraneous dependency warning messages
        [-I] do not display thread index if multiprocessor build
        [-j filename] use 'filename' as the name for log files
        [-k] keep (don't delete) out-of-date targets
        [-l] link only, no compiles
        [-L] compile only, no link phase
        [-m] run build in the idle priority class
        [-M [n]] Multiprocessor build (for MP machines)
        [-n] No SYNCHRONIZE_BLOCK and SYNCHRONIZE_DRAIN directives
        [-o] display out-of-date files
        [-O] generate obj_objects.mac file for current directory
        [-p] pause' before compile and link phases
        [-P] Print elapsed time after every directory
        [-q] query only, don't run NMAKE
        [-r dirPath] restarts clean build at specified directory path
        [-s] display status line at top of display
        [-S] display status line with include file line counts
        [-t] display the first level of the dependency tree
        [-T] display the complete dependency tree
        [-$] display the complete dependency tree hierarchically
        [-u] display unused BUILD_OPTIONS
        [-v] enable include file version checking
        [-w] show warnings on screen
        [-x filename] exclude include file from dependency checks
        [-X] generates build.xml file
        [-Xv] generates verbose build.xml file
        [-y] show files scanned
        [-z] no dependency checking or scanning of source files -
                one pass compile/link
        [-Z] no dependency checking or scanning of source files -
                three passes
        [-why] list reasons for building targets

        [-386] build targets for 32-bit Intel
        [-x86] Same as -i386
        [-ia64] build targets for IA64
        [-amd64] build targets for AMD64
        [-arm] build targets for ARM

        [-jpath pathname] use 'pathname' as the path for log files instead of "."
        [-nmake arg] argument to pass to NMAKE
        [-clean] equivalent to '-nmake clean'
        Non-switch parameters specify additional source directories
        * builds all optional source directories
BUILD: Done
wowocock
VIP专家组
VIP专家组
  • 注册日期2002-04-08
  • 最后登录2016-01-09
  • 粉丝16
  • 关注2
  • 积分601分
  • 威望1651点
  • 贡献值1点
  • 好评度1227点
  • 原创分1分
  • 专家分0分
板凳#
发布于:2004-09-21 09:33
在DDK环境中BUILD /?自己看看.
花开了,然后又会凋零,星星是璀璨的,可那光芒也会消失。在这样 一瞬间,人降生了,笑者,哭着,战斗,伤害,喜悦,悲伤憎恶,爱。一切都只是刹那间的邂逅,而最后都要归入死亡的永眠
arthurtu
驱动巨牛
驱动巨牛
  • 注册日期2001-11-08
  • 最后登录2020-12-19
  • 粉丝0
  • 关注0
  • 积分26分
  • 威望161点
  • 贡献值0点
  • 好评度35点
  • 原创分0分
  • 专家分0分
  • 社区居民
地板#
发布于:2004-09-21 10:34
LINKER_FLAGS
Use the LINKER_FLAGS macro to override any default linker switch that will be passed to the linker.


C_DEFINES
Use the C_DEFINES environment variable to specify the switches you want passed to the C compiler and to the Microsoft interface description language compiler (MIDL).

Typically, these switches are compiler #define directives.

For example, to define DEBUG_BUILD to the compiler, you would specify:

C_DEFINES = /DDEBUG_BUILD

Within a sources file, you can add text to the C_DEFINES variable without losing its original content. For example, to define UNICODE to the compiler in addition to any existing C_DEFINES switches, you could specify:

C_DEFINES = $(C_DEFINES) /DUNICODE

There is no limit to what this #define can be, except that C_DEFINES gets passed to the compiler and it also gets passed to the resource compiler. Therefore, you cannot put compiler optimization or other machine-specific or tool-specific switches in the C_DEFINES environment variable. Instead, use one of the following macros in your sources file:

MSC_OPTIMIZATION
MSC_WARNING_LEVEL
USER_C_FLAGS
游客

返回顶部