I am running a windows 7 virtual machine and both Socket::PF_PACKET and Socket::PF_LINK are undefined. I can confirm this in the constants list for Socket in irb.
irb(main):001:0> require 'socket'
=> true
irb(main):002:0> Socket.const_defined? :PF_LINK
=> false
irb(main):003:0> Socket.const_defined? :PF_PACKET
=> false
Is there another constant that will work instead or is there a reason why these constants may not be defined that is explainable that can lead to a solution?