wrap windows heartbeat code in #ifdef for linux to compile