Windows C and C++ routine compile and link options
The compile and link
options for building C and C++ routines, such as stored procedures
and user-defined functions, on Windows operating
systems with the Microsoft Visual
C++ compiler are available in the
bldrtn.bat
batch
file.
Compile and link options for bldrtn
Compile
options:
%BLDCOMP%
- Variable for the compiler. The default is
cl
, the Microsoft Visual C++ compiler. It can be also set toicl
, the Intel C++ Compiler for 32-bit and 64-bit applications, orecl
, the Intel C++ Compiler for Itanium 64-bit applications. -Zi
- Enable debugging information
-Od
- Disable optimization.
-c
- Perform compile only; no link. Compile and link are separate steps.
-W2
- Output warning, error, and severe and unrecoverable error messages.
-DWIN32
- Compiler option necessary for Windows operating systems.
-MD
- Link using MSVCRT.LIB
Link options:
link
- Use the linker to link.
-debug
- Include debugging information.
-out:%1.dll
- Build a .DLL file.
%1.obj
- Include the object file.
db2api.lib
- Link with the Db2® library.
-def:%1.def
- Module definition file.
Refer to your compiler documentation for additional compiler options.