PRB: NMAKE Invokes MASM Instead of the C CompilerLast reviewed: July 17, 1997Article ID: Q60746 |
1.01 1.10 1.11 1.12 1.13 1.20 1.30 1.40 | 1.01 1.11 1.12 1.13 1.21
MS-DOS | OS/2kbtool kbprb The information in this article applies to:
SYMPTOMSWhen using an NMAKE file in combination with adding /Fa to the compiler options within Programmer's WorkBench (PWB) or Visual Workbench, NMAKE will invoke the Microsoft Macro Assembler (MASM), if it is in the current search path. This does not occur the first time you build your application, but it does occur the second time, and thereafter, because of the generation of the .ASM created by the compiler.
CAUSEFiles with the .ASM extension have a predefined inference rule within NMAKE to invoke MASM. However, the inference rule for .ASM files takes place before the rule for files with the .C or .OBJ extension. Therefore, if you have a filename with the same base name, but one has an .ASM extension and the other has a .C extension (as is the case with the /FA switch), the .ASM file will be assembled before the .C file will be compiled. Since the assembly step generates an .OBJ file that is newer than the .C file, the .C file is never compiled.
RESOLUTIONUse the following procedures to work around this behavior:
|
Additional reference words: 1.10 1.20 1.30 1.40
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |