Fix platform detection.  closes #9