updated to support Linux too