I'm trying to develop a device driver using SerCx2, but I have trouble compiling the driver.
I'm using VS2019 and have installed the latest SDK and WDK, and have created a sample KMDF driver project. This builds just fine and is working.
But when I try to use SerCx2, i run into some issues.
First of all, #include <sercx.h> doesn't work, I get "file not found" when compiling.
I can include the header using #include <sercx/2.0/sercx.h>, then the compiler does find it. But instead, I get linker errors like this:
Error LNK1120 2 unresolved externals KMDF Driver1 C:\Users\dev\source\repos\KMDF Driver1\x64\Debug\KMDFDriver1.sys 1
Error LNK2001 unresolved external symbol SercxDriverGlobals KMDF Driver1 C:\Users\dev\source\repos\KMDF Driver1\KMDF Driver1\Driver.obj 1
Error LNK2001 unresolved external symbol SercxFunctions KMDF Driver1 C:\Users\dev\source\repos\KMDF Driver1\KMDF Driver1\Driver.obj 1
I.e the linker doesn't find the required files.
Seems as the SerCx2 isn't included in the project. Do I need to add it to the project somehow?
I found some different settings in Properties -> Driver Settings, where you can enable "Link to the xxxxxxxxx Class Extension", but none of them are related to SerCx2.