📄 makefile
字号:
#----------------------------------------------------------------------------
#
# Device Driver MAKEFILE
#
# Author: Anthony A. Kempka
# Device Drivers International
#
#
#****************************************************************************
#----------------------------------------------------------------------------
# Compile flags for the Kernel Mode Driver
#
# general flags,
CFLAGS1 = /c /Gs /W3 /GF /Gz
# The following flags handle Pentium chip bugs
CFLAGS2 = /QIfdiv- /QI0f
# /Z7=Debug info flags, /Zel=Use MS extension-omit default library
CFLAGS3 = /Z7 /Zel
# /Od=Turn off ALL optimizations, /Oi=Inline functions
CFLAGS4 = /Od /Oi
# defines used by .H files and the like
CFLAGS5 = -cbstring -FIwarning.h -D_X86_=1 -Di386=1
#----------------------------------------------------------------------------
#****************************************************************************
#****************************************************************************
#----------------------------------------------------------------------------
# Flags for the User Mode EXE
#
#----------------------------------------------------------------------------
# COMPILE flags
ccommon = -c -W3 -DCRTAPI1=_cdecl -DCRTAPI2=_cdecl -nologo
cflags = $(ccommon) -D_X86_=1
cvars = -DWIN32 $(noansi) -D_WIN32
cdebug = -Z7 -Od
CCFLAGS = $(cflags) $(cvars) $(cdebug)
#----------------------------------------------------------------------------
# LINK Flags
libcmt = libcmt.lib oldnames.lib
baselibs = kernel32.lib advapi32.lib
libc = libc.lib oldnames.lib
linklibs = $(libc) $(baselibs)
linkdebug = -debug:full -debugtype:cv
lflags = /NODEFAULTLIB /INCREMENTAL:NO /PDB:NONE /RELEASE /NOLOGO
conlflags = $(lflags) -subsystem:console,4.0 -entry:mainCRTStartup
#----------------------------------------------------------------------------
#****************************************************************************
#****************************************************************************
#----------------------------------------------------------------------------
#
# The dependency list and build rules follows
whole_enchilada : rs485nt.sys\
q_test.exe
rs485nt.sym: rs485nt.map
MSYM rs485nt.MAP
rs485nt.map: rs485nt.sys
DBG2MAP rs485nt.SYS
#
# In the following,
# Use: RS485NT.LNR for a release link
# Use: RS485NT.LND for a debug build
#
rs485nt.sys: rs485nt.obj
LINK @RS485NT.LNR
rs485nt.obj: rs485nt.c\
rs485nt.h
CL $(CFLAGS1) $(CFLAGS2) $(CFLAGS3) $(CFLAGS4) $(CFLAGS5) $(CFLAGS6) RS485NT.C
q_test.obj: q_test.c
CL $(CCFLAGS) q_test.c
q_test.exe: q_test.obj
LINK $(linkdebug) $(conflags) -out:q_test.exe q_test.obj $(linklibs)
#****************************************************************************
#****************************************************************************
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -