1 Star 0 Fork 81

openeuler-embedded/python3

forked from src-openEuler/python3 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
python3-add-generic-os-support.patch 911 Bytes
一键复制 编辑 原始数据 按行查看 历史
tong_1001 提交于 2020-09-01 14:45 . update to 3.7.9
diff --git a/Lib/platform.py b/Lib/platform.py
index 6ab06b5..8d41a4b 100755
--- a/Lib/platform.py
+++ b/Lib/platform.py
@@ -297,7 +297,7 @@ _release_version = re.compile(r'([^0-9]+)'
# and http://www.die.net/doc/linux/man/man1/lsb_release.1.html
_supported_dists = (
- 'SuSE', 'debian', 'fedora', 'redhat', 'centos',
+ 'SuSE', 'debian', 'fedora', 'redhat', 'centos', 'generic_os',
'mandrake', 'mandriva', 'rocks', 'slackware', 'yellowdog', 'gentoo',
'UnitedLinux', 'turbolinux', 'arch', 'mageia')
@@ -367,6 +367,8 @@ def _linux_distribution(distname, version, id, supported_dists,
return distname, version, id
etc.sort()
for file in etc:
+ if os.path.islink(os.path.join(_UNIXCONFDIR, file)):
+ continue
m = _release_filename.match(file)
if m is not None:
_distname, dummy = m.groups()
--
2.23.0
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/openeuler-embedded/python3.git
[email protected]:openeuler-embedded/python3.git
openeuler-embedded
python3
python3
openEuler-embedded

搜索帮助