Export (0) Print
Expand All
Expand Minimize
This topic has not yet been rated - Rate this topic

/c (Compile Without Linking)

/c

This option prevents the automatic call to LINK. Compiling with /c creates .obj files only. You must call LINK explicitly with the proper files and options to perform the linking phase of the build.

Any internal project created in the development environment uses the /c option by default.

To set this compiler option in the Visual Studio development environment

This option is not available from within the development environment.

To set this compiler option programmatically

This compiler option cannot be changed programmatically.

Example

The following command line creates the object files FIRST.obj and SECOND.obj. THIRD.obj is ignored.

CL /c FIRST.C SECOND.C THIRD.OBJ

To create an executable file, you must invoke LINK:

LINK firsti.obj second.obj third.obj /OUT:filename.exe

See Also

Compiler Options | Setting Compiler Options

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.