--- Tools/Scripts/webkitpy/common/system/platforminfo.py.orig 2015-10-13 04:37:06 UTC +++ Tools/Scripts/webkitpy/common/system/platforminfo.py @@ -49,6 +49,8 @@ class PlatformInfo(object): self.os_name = self._determine_os_name(sys_module.platform) if self.os_name == 'linux': self.os_version = self._determine_linux_version() + if self.os_name == 'bsdsunix': + self.os_version = platform_module.release() if self.os_name == 'freebsd': self.os_version = platform_module.release() if self.os_name.startswith('mac'): @@ -69,6 +71,9 @@ class PlatformInfo(object): def is_linux(self): return self.os_name == 'linux' + def is_bsdsunix(self): + return self.os_name == 'bsdsunix' + def is_freebsd(self): return self.os_name == 'freebsd' @@ -119,6 +124,8 @@ class PlatformInfo(object): return 'linux' if sys_platform in ('win32', 'cygwin'): return 'win' + if sys_platform.startswith('bsdsunix'): + return 'bsdsunix' if sys_platform.startswith('freebsd'): return 'freebsd' raise AssertionError('unrecognized platform string "%s"' % sys_platform)