I want to compile my libpcap and winpcap based programms, but I noticed that other users also have to install WinPCAP among my programm. How can I compile all necessary files into one programm?
Short answer: You can't.
The long answer comes from some old wisdom in a WinPcap mailing list:
There is a way to make
packet.dllandwpcap.dllstatic: rebuild them as such. You just sacrifice the ability to do anything, since all the stuff inwpcap.dllrequirespacket.dll, and all the stuff inpacket.dllrequires the kernel driver. And the kernel driver won't exist without the full winpcap installation.It includes (among other things) a kernel driver that cannot be transformed to a static library.
There is no way on Windows to make a kernel driver part of a static library. (Or a
DLL, for that matter.) If the kernel driver is required, then it's hard to get anything done without it.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With