node-pcap / node_pcap

libpcap bindings for node
MIT License
930 stars 254 forks source link

npm install pcap doesn't work #252

Open GkqqNkKC opened 5 years ago

GkqqNkKC commented 5 years ago

C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.22.27905\include\xkeycheck.h(255,1): warning C4005: 'inline': macro redefinition (compi ling source file ..\pcap_binding.cc) [D:\business\x\node_modules\pcap\build\pcap_binding.vcxproj]

C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.22.27905\include\pcap-stdinc.h(69): message : see previous definition of 'inline' (comp iling source file ..\pcap_binding.cc) [D:\business\x\node_modules\pcap\build\pcap_binding.vcxproj]

C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.22.27905\include\xkeycheck.h(257,1): error C1189: #error: The C++ Standard Library for bids macroizing the keyword "inline". Enable warning C4005 to find the forbidden define. (compiling source file ..\pcap_binding.cc) [D:\business\x\node_modules\pcap\build\pcap_binding.vcxproj]

D:\business\x\node_modules\pcap\pcap_session.cc(3,10): error C1083: Cannot open include file: 'sys/ioctl.h': No such file or directo ry [D:\business\x\node_modules\pcap\build\pcap_binding.vcxproj]

bnonni commented 4 years ago

@GkqqNkKC just so you're aware, this is an ongoing discussion/issue here: 251

@jonahharris has taken ownership of the npm repo and plans to integrate his fix. Now, Idk if that addresses issues for WIN or not, but thought I would make you aware.

mildsunrise commented 4 years ago

if you're using windows, see https://github.com/node-pcap/node_pcap/issues/249#issuecomment-586201286