Problems with INF and WDK 14393 (for Win10 1607)

Hello
I have a driver using VS 2022 and newest SDK/WDK that works on Win11. Then I needed to make it work on Win10 2004. For this I used VS 2019 and matching SDK/WDK. Turns out now that some people are still using Win10 1607, so I have to use VS 2015 and SDK/WDK 14393 (KMDF 1.19). The compilation works but I have problems with the INF file.

While building I get these errors:
1> Building ‘indelpcie-drv’ with toolset ‘WindowsKernelModeDriver10.0’ and the ‘Universal’ target platform.
1> Using version information from C:\Program Files (x86)\Windows Kits\10\Include\10.0.14393.0\shared\ntverp.h
1> Could not open version header file C:\Program Files (x86)\Windows Kits\10\Include\10.0.14393.0\shared\bldnump.h. (0x00000002)
1> Could not determine version information. Please specify using -v option.
1> Updates common INF file directives
1>
1> USAGE: (etc)

There’s nowhere a bldnump.h in any directory. I tried fiddling around with the parameters but I always get this error.

Then I thought there might be something wrong with the INF file (which came from old NT days and also works for current systems).
But infverif won’t even look at it. It always prints the usage, and the ERRORLEVEL is 87, meaning incorrect parameters.

C:\projects\common\libindelpcie-drv>“C:\Program Files (x86)\Windows Kits\10\Tools\x64\infverif.exe” *.inf (or full name, or full path etc)
Microsoft (R) Driver Package INF Verifier
USAGE: InfVerif.exe [/v] [/u | /universal] [/info] [/stampinf] [/l ] [/product ]

Here too any combination of parameters (/v /u /info…) always gives the same result.
How can I make the build work? Is this a problem with my project or with my environment?

Thanks

You shouldn’t need to change the Visual Studio version. You just need to tell it what version you are targeting. You can build for (almost) any release using the latest tools.

That’s what I tried first but I had problems because the build was looking for tools in newer SDK or WDK paths than installed. So I tried with a fresh Win10 machine and installed just the recommended tools/kits.
Anyway I don’t think that’s my problem here. I’m calling the WDK’s stampinf or infverif directly (command line) and they still don’t seem to work. As I don’t see much information about these errors on the internet then I’m probably doing something wrong, I just don’t know what that could be. There are only so many things you can do wrong calling a command line tool.

Can anybody tell me if that bldnump.h file should exist at all? If yes then my WDK installation might be bad, even though I tried it twice and never got that file.

Seems other have/had the same problems
https://community.osr.com/discussion/292228/infverif-exe-does-not-work-wdk-10-0-14393-795

I believe the WDK to be defective so I want to try an earlier version. However on microsoft.com the first version for Win10 is 1607, but no 1511. So is it possible to use version 1703 to create a driver that runs on Win10 1607?
Thanks and sorry for my many posts.

Please make sure you use the combination of Windows 10, WDK, SDK and Visual Studio specified here https://learn.microsoft.com/en-us/windows-hardware/drivers/other-wdk-downloads

You might have conflicts if you use different combinations. Its possible there is a problem with your inf file. Can you run infverif and post the errors here?

@fcenedese said:
I believe the WDK to be defective so I want to try an earlier version. However on microsoft.com the first version for Win10 is 1607, but no 1511. So is it possible to use version 1703 to create a driver that runs on Win10 1607?
Thanks and sorry for my many posts.

Sorry, I had a bug in the standalone exe in 14393 that caused it to always fail parameter validation :frowning: You can use infverif from a later kit though

Please read my first post. infverif didn’t work with 14393 (for 1607). I’m now using the version for 1703. That seems to work just as well on 1607 as long as I don’t use any new functions that didn’t exist before.
stampinf and infverif work better but still not according to the given parameters. But as the driver and inf work I can focus on software for now.

Oops, my post was directed at “limitedge”, I didn’t see the post from “Zac_Lockard” before. Thanks for the confirmation that I’m not crazy (at least not in this case :slight_smile:

@fcenedese said:
Oops, my post was directed at “limitedge”, I didn’t see the post from “Zac_Lockard” before. Thanks for the confirmation that I’m not crazy (at least not in this case :slight_smile:

My bad, I didn’t understand your earlier posts

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.