source文件: !IF 0Copyright (c) 1989 Microsoft CorporationModule Name: sources.Abstract: This file specifies the target component being built and the list of sources files needed to build that component. Also specifies optional compiler switches and libraries that are unique for the component being built. Author: NOTE: Commented description of this file is in \nt\bak\bin\sources.tpl!ENDIF TARGETNAME=SNOWTEAR TARGETPATH=obj TARGETTYPE=DRIVERTARGETLIBS=$(DDK_LIB_PATH)\ndis.lib C_DEFINES=$(C_DEFINES) -DNDIS40 -DNDIS_MINIPORT_DRIVER -DNDIS40_MINIPORTINCLUDES=..\..\incSOURCES= snowtear.c \ protocol.c \ miniport.c \MSC_WARNING_LEVEL=/W3 /WXPRECOMPILED_INCLUDE=precomp.h PRECOMPILED_PCH=precomp.pch PRECOMPILED_OBJ=precomp.obj makefile: # # DO NOT EDIT THIS FILE!!! Edit .\sources. if you want to add a new source # file to this component. This file merely indirects to the real make file # that is shared by all the components of NT # !INCLUDE $(NTMAKEENV)\makefile.def我的驱动程序就是用的这个默认MAKEFILE。 至于source文件,也是改的DDK里的
MAKEFILE文件: 考下去就可以用# # DO NOT EDIT THIS FILE!!! Edit .\sources. if you want to add a new source # file to this component. This file merely indirects to the real make file # that is shared by all the driver components of the Windows NT DDK #!INCLUDE $(NTMAKEENV)\makefile.def
Checked Build Environment
或Free Build Environment进入相关目录build即可
或者你用driver studio工具
然后用build就可以编译了
而我又不会写, 真不知道应该如何入手.
!IF 0Copyright (c) 1989 Microsoft CorporationModule Name: sources.Abstract: This file specifies the target component being built and the list of
sources files needed to build that component. Also specifies optional
compiler switches and libraries that are unique for the component being
built.
Author:
NOTE: Commented description of this file is in \nt\bak\bin\sources.tpl!ENDIF
TARGETNAME=SNOWTEAR
TARGETPATH=obj
TARGETTYPE=DRIVERTARGETLIBS=$(DDK_LIB_PATH)\ndis.lib
C_DEFINES=$(C_DEFINES) -DNDIS40 -DNDIS_MINIPORT_DRIVER -DNDIS40_MINIPORTINCLUDES=..\..\incSOURCES= snowtear.c \
protocol.c \
miniport.c \MSC_WARNING_LEVEL=/W3 /WXPRECOMPILED_INCLUDE=precomp.h
PRECOMPILED_PCH=precomp.pch
PRECOMPILED_OBJ=precomp.obj makefile:
#
# DO NOT EDIT THIS FILE!!! Edit .\sources. if you want to add a new source
# file to this component. This file merely indirects to the real make file
# that is shared by all the components of NT
#
!INCLUDE $(NTMAKEENV)\makefile.def我的驱动程序就是用的这个默认MAKEFILE。
至于source文件,也是改的DDK里的
照样做两个,
然后运行DDK的命令窗口,到你的驱动代码所在文件夹,键入:build -ceZ就可以了.
fxfilthook.c不知道怎么写啊!
考下去就可以用#
# DO NOT EDIT THIS FILE!!! Edit .\sources. if you want to add a new source
# file to this component. This file merely indirects to the real make file
# that is shared by all the driver components of the Windows NT DDK
#!INCLUDE $(NTMAKEENV)\makefile.def
TARGETPATH=obj
TARGETTYPE=DRIVER#TARGETLIBS= $(DDK_LIB_PATH)\ntdll.lib \
# $(DDK_LIB_PATH)\ndis.lib MSC_WARNING_LEVEL=-W3 -WXMSC_OPTIMIZATION=/OdiINCLUDES=./include 头文件路径,在同一目录下就没必要
SOURCES = fxfilthook.c
但现在的问题是 ifh 启动之后并没有截下 ICMP 包.
估计问题是我的驱动没有设置好正确的启动顺序.可有人知道在哪设置 驱动的启动顺序 ?调试成功一定 600 分相谢!