Added a platform-generic backend for polling.

This should allow for this program to be used on systems other that Linux.