I must be missing something basic here.
-
I reboot a VM running XP-32. It has the latest DDK installed.
-
I use the start menu to open a cmd window with x86 free build environment.
-
I build the command-line tool as specified by the html instructions:
C:\WinDDK\6001.18001\src\setup\DIFxAPI\DIFxCmd>build -cZ
… -
I build a sample:
C:\WinDDK\6001.18001\src\network\ndis\ndisprot>build -ceZ
… -
I collect the pieces together:
Directory of C:\tmp
10/11/2010 08:44 AM
.10/11/2010 08:44 AM ..
11/02/2006 07:21 AM 319,456 DIFxAPI.dll
10/11/2010 08:36 AM 12,288 DIFxCmd.exe
10/11/2010 09:05 AM 2,752 ndisprot.inf
10/11/2010 08:39 AM 21,888 ndisprot.sys
6. I run the sample, it fails:
C:\tmp>difxcmd /i ndisprot.inf 16
DIFxAPI Sampe Program
INFO: Option "/i"
INFO: Input file "C:\tmp\ndisprot.inf"
INFO: Flags 0x10 (16)
TEST: installing driver package.
LOG Event: 1, ENTER: DriverPackageInstallW
LOG Event: 1, Installing INF file 'C:\WINDOWS\system32\DRVSTORE\ndisprot_9639EB185DCBF1B359F0E31593C29CBB0606C865\ndisprot.inf' of Type 6.
LOG Event: 1, Looking for Model Section [MSFT.NTx86]...
LOG Event: 1, No matching devices found in INF "C:\WINDOWS\system32\DRVSTORE\ndisprot_9639EB185DCBF1B359F0E31593C29CBB0606C865\ndisprot.inf" on the Machine.
LOG Event: 1, No drivers installed. No devices found that match driver(s) contained in 'C:\WINDOWS\system32\DRVSTORE\ndisprot_9639EB185DCBF1B359F0E31593C29CBB0606C865\ndisprot.inf'.
LOG Event: 0, Installation completed with code 0xE000020B.
LOG Event: 1, RETURN: DriverPackageInstallW (0xE000020B)
INFO: There aren't any live devnodes with the DeviceId contained in the INF.
7. I add
[version]
DriverPackageType = Networks
as required by the DriverPackageInstall Function, see
http://msdn.microsoft.com/en-us/library/ff544813%28VS.85%29.aspx
http://msdn.microsoft.com/en-us/library/ff552334%28v=VS.85%29.aspx
(you'd think MS would have updated their .inf files)
and run again:
C:\tmp>difxcmd /i ndisprot.inf 16
DIFxAPI Sampe Program
INFO: Option "/i"
INFO: Input file "C:\tmp\ndisprot.inf"
INFO: Flags 0x10 (16)
TEST: installing driver package.
LOG Event: 1, ENTER: DriverPackageInstallW
LOG Event: 1, Copied 'ndisprot.inf' to driver store...
LOG Event: 1, Commiting queue...
LOG Event: 1, Copied file: 'C:\tmp\ndisprot.sys' -> 'C:\WINDOWS\system32\DRVSTORE\ndisprot_AF120FA26C33FDC52476FA364B843FA329A8829A\ndisprot.sys'.
LOG Event: 3, Could not obtain installer information for driver C:\WINDOWS\system32\DRVSTORE\ndisprot_AF120FA26C33FDC52476FA364B843FA329A8829A\ndisprot.inf
LOG Event: 3, Error = 13, The driver installation failed. Attempting to undo system changes ...
LOG Event: 1, Driver Store entry '' removed.
LOG Event: 1, RETURN: DriverPackageInstallW (0xD)
ERROR: failed with error code 0xD
[error 13 is ERROR_INVALID_DATA]
8. I repeat the process with passthru.sys with the same results: fails with 0xE000020B then 0xD after adding DriverPackageType.
9. So quite clearly I am missing something simple. Google does not show other people complaining about this. Does anyone have a clue as to where I am going wrong?