Fix OSX detection
Extract /var/run into a variable