自已写了一个驱动程序,编译时提示:
#error NTVERSION symbol must be defined to one of the following: 400, 'WDM',错误出在vdw.h,我打开vdw.h看到有几行关于NTVERSION的:
#ifdef _IA64_
extern "C" void __cdecl __mf(void);
#pragma intrinsic(__mf)
#endif#ifndef __VDW_VERSION__
#define __VDW_VERSION__ 250#ifndef NTVERSION
#error NTVERSION symbol must be defined to one of the following: 400, 'WDM'
#endif#define _WDM_ (NTVERSION == 'WDM')
#define _NT400_ (NTVERSION == 400)不知有哪位碰到过类似的问题,请问如何解决。
#error NTVERSION symbol must be defined to one of the following: 400, 'WDM',错误出在vdw.h,我打开vdw.h看到有几行关于NTVERSION的:
#ifdef _IA64_
extern "C" void __cdecl __mf(void);
#pragma intrinsic(__mf)
#endif#ifndef __VDW_VERSION__
#define __VDW_VERSION__ 250#ifndef NTVERSION
#error NTVERSION symbol must be defined to one of the following: 400, 'WDM'
#endif#define _WDM_ (NTVERSION == 'WDM')
#define _NT400_ (NTVERSION == 400)不知有哪位碰到过类似的问题,请问如何解决。
解决方案 »
- 用VC++开发项目用unicode字符集还是多字节字符集呢?
- 关于button移动的问题
- 求一条XPATH语句
- 如何实现多个位图按钮(速度啊)
- 请教:如何取得VARIANT 类型变量中的数据??
- ado连接SQL SERVER问题
- 为什么无法包含gl/glut.h?
- 十万火急!小女子做数字图像处理,请各位大哥提示:如何找到将JPEG(JPG)文件格式转化成BMP文件格式的C源码?
- 用BackupRead()备份一个几十兆的文件,当我的缓冲区不够大时,我…………?
- 怎样在word中输入分数,要求不是2/3的格式,而是平常书写的形式(2在上,3在下)。
- 关于组件向注册表注册时的层次问题
- 500提问:如何实现CString类型到LPBYTE类型的转化???请各位大侠指教!!!
在你程序里加上
#define NTVERSION
#define _NT400_ (NTVERSION == 400)
你注释掉其中一句试试,它要求版本只有一种。
--------------------Configuration: Test_RegSample - Win32 Debug--------------------
Compiling...
RegSampleDevice.cpp
E:\NTDDK\INC\DDK\ntddk.h(7914) : error C2146: syntax error : missing ';' before identifier 'InterruptTime'
E:\NTDDK\INC\DDK\ntddk.h(7914) : error C2501: 'InterruptTime' : missing storage-class or type specifiers
E:\NTDDK\INC\DDK\ntddk.h(7928) : error C2146: syntax error : missing ';' before identifier 'SystemTime'
E:\NTDDK\INC\DDK\ntddk.h(7928) : error C2086: 'KSYSTEM_TIME' : redefinition
E:\NTDDK\INC\DDK\ntddk.h(7928) : error C2501: 'SystemTime' : missing storage-class or type specifiers
E:\NTDDK\INC\DDK\ntddk.h(7935) : error C2146: syntax error : missing ';' before identifier 'TimeZoneBias'
E:\NTDDK\INC\DDK\ntddk.h(7935) : error C2086: 'KSYSTEM_TIME' : redefinition
E:\NTDDK\INC\DDK\ntddk.h(7935) : error C2501: 'TimeZoneBias' : missing storage-class or type specifiers
E:\NTDDK\INC\DDK\ntddk.h(9101) : error C2146: syntax error : missing ';' before identifier 'ContextRecord'
E:\NTDDK\INC\DDK\ntddk.h(9101) : error C2501: 'PCONTEXT' : missing storage-class or type specifiers
E:\NTDDK\INC\DDK\ntddk.h(9101) : error C2501: 'ContextRecord' : missing storage-class or type specifiers
E:\NTDDK\INC\DDK\ntddk.h(10051) : error C2146: syntax error : missing ';' before identifier 'KeTickCount'
E:\NTDDK\INC\DDK\ntddk.h(10051) : fatal error C1004: unexpected end of file found
Error executing cl.exe.Test_RegSample.exe - 13 error(s), 0 warning(s)
我搜索了一个KSYSTEM_TIME这个类,发现在我的机器没有这个类。
不是这个问题,不知那位碰到过?