Windows System Software -- Consulting, Training, Development -- Unique Expertise, Guaranteed Results

Home NTDEV

Before Posting...

Please check out the Community Guidelines in the Announcements and Administration Category.

More Info on Driver Writing and Debugging


The free OSR Learning Library has more than 50 articles on a wide variety of topics about writing and debugging device drivers and Minifilters. From introductory level to advanced. All the articles have been recently reviewed and updated, and are written using the clear and definitive style you've come to expect from OSR over the years.


Check out The OSR Learning Library at: https://www.osr.com/osr-learning-library/


Using WDK 10 in VS 2022

Mauro_LeggieriMauro_Leggieri Member Posts: 110

After some time far from writing drivers, found VS 2022 only supports that new WDK that does not allow to build x86 drivers nor target win7. And downloading the 15GB!!!! EWDK is ridiculous.

So:

  1. Install SDK & WDK 10.0.19041.0
  2. In C:\Program Files (x86)\Windows Kits\10\bin, create a folder named 10.0.19041.0 and copy the contents of the whole bin directory inside.
  3. In C:\Program Files (x86)\Windows Kits\10\DesignTime\CommonConfiguration\Neutral\WDK\ create a folder named 10.0.19041.0 and copy the two WDK*.props inside.
  4. Extract from WDK 11 22H2, Microsoft.DriverKit.Build.Tasks.17.0.dll and Microsoft.DriverKit.Build.Tasks.PackageVerifier.17.0.dll. Copy them into C:\Program Files (x86)\Windows Kits\10\build\10.0.19041.0\bin. (You should find them in ...\Windows Kits\10\build\10.0.22621.0\bin)
  5. Restart VS 2022 if open.

Now you can select WDK 10 to compile.

I know, it is a hack hack, Peter Viscarola will hang me and probably some things won't work as expected. But at least you will be able to compile a driver targeting any OS/platform.

Comments

  • Mark_RoddyMark_Roddy Member - All Emails Posts: 4,605

    I'm confused about why the EWDK iso at 15GB is a hack compared to VS tools, which are also approximately 15GB (actually larger). The EWDK is really easy to use and is simply mounted on the build system, or on a SMB share. Shared over the net it can be used by multiple build systems.

  • Mauro_LeggieriMauro_Leggieri Member Posts: 110

    The EWDK it not a hack. I simply dislike to install two VS tools just because MS decided to break compatibility and make kits strongly dependent of the tools.

    Hope they make a new WDK. Else I'll probably end rolling back to VS 2019.

  • Mark_RoddyMark_Roddy Member - All Emails Posts: 4,605

    My point is that you don't have to install anything to use the EWDK. Literally nothing. It is a self contained toolset on an iso. All you have to do is mount the thing somewhere.

  • Mauro_LeggieriMauro_Leggieri Member Posts: 110

    I know and understand. Mine is: you have VS, SDK and WDK installed like we always used to, but now you need an extra 15GB development environment just because MS decided to break things.

    It is also funny the WDK & EWDK contains the x86 libraries for filter manager.... but you cannot target it.

  • Peter_Viscarola_(OSR)Peter_Viscarola_(OSR) Administrator Posts: 9,065

    VS 2022 only supports that new WDK that does not allow to build x86 drivers nor target win7

    Hmmm... so, use VS 2019 and the old WDK? How does that not solve your problem?

    Did you not read the "announcement" in this forum about VS 2022 and the WDK?

    Peter

    Peter Viscarola
    OSR
    @OSRDrivers

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. Sign in or register to get started.

Upcoming OSR Seminars
OSR has suspended in-person seminars due to the Covid-19 outbreak. But, don't miss your training! Attend via the internet instead!
Kernel Debugging 30 January 2023 Live, Online
Developing Minifilters 20 March 2023 Live, Online
Internals & Software Drivers 17 April 2023 Live, Online
Writing WDF Drivers 22 May 2023 Live, Online