mirror of
https://github.com/python/cpython.git
synced 2025-10-15 03:10:29 +00:00
Issue #12326: don't test the major version of sys.platform
Use startswith, instead of ==, when testing sys.platform to support new platforms like Linux 3 or OpenBSD 5.
This commit is contained in:
parent
c77239613b
commit
9c3de4a883
8 changed files with 48 additions and 52 deletions
5
setup.py
5
setup.py
|
@ -1381,9 +1381,8 @@ class PyBuildExt(build_ext):
|
|||
# End multiprocessing
|
||||
|
||||
# Platform-specific libraries
|
||||
if (platform in ('linux2', 'freebsd4', 'freebsd5', 'freebsd6',
|
||||
'freebsd7', 'freebsd8')
|
||||
or platform.startswith("gnukfreebsd")):
|
||||
if any(platform.startswith(prefix)
|
||||
for prefix in ("linux", "freebsd", "gnukfreebsd")):
|
||||
exts.append( Extension('ossaudiodev', ['ossaudiodev.c']) )
|
||||
else:
|
||||
missing.append('ossaudiodev')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue