Skip to content

Commit f9f3594

Browse files
committed
Platform tags: Adjust to centralize history
Move history to a dedicated section (consistent with other specs). In the main text, do not reference PEPs but just describe the current spec. Also sketch out a few missing details.
1 parent 9b735c9 commit f9f3594

File tree

1 file changed

+37
-30
lines changed

1 file changed

+37
-30
lines changed

source/specifications/platform-compatibility-tags.rst

Lines changed: 37 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,6 @@ Platform compatibility tags allow build tools to mark distributions as being
99
compatible with specific platforms, and allows installers to understand which
1010
distributions are compatible with the system they are running on.
1111

12-
The following PEPs contributed to this spec:
13-
14-
1. :pep:`425`
15-
2. :pep:`513`
16-
3. :pep:`571`
17-
4. :pep:`599`
18-
5. :pep:`600`
1912

2013
Overview
2114
========
@@ -92,10 +85,14 @@ decide how to best use the ABI tag.
9285
Platform Tag
9386
------------
9487

95-
The platform tag is simply ``sysconfig.get_platform()`` with all
96-
hyphens ``-`` and periods ``.`` replaced with underscore ``_``.
88+
-------------------
89+
Basic platform tags
90+
-------------------
91+
92+
In its simplest form, the platform tag is ``sysconfig.get_platform()`` with
93+
all hyphens ``-`` and periods ``.`` replaced with underscore ``_``.
9794
Until the removal of :ref:`distutils` in Python 3.12, this
98-
was ``distutils.util.get_platform()``.
95+
was ``distutils.util.get_platform()``. For example:
9996

10097
* win32
10198
* linux_i386
@@ -107,32 +104,30 @@ was ``distutils.util.get_platform()``.
107104
-------------
108105
.. _manylinux:
109106

110-
The scheme defined in :pep:`425` was insufficient for public distribution of
111-
wheel files (and \*nix wheel files in general) to Linux platforms, due to the
112-
large ecosystem of Linux platforms and subtle differences between them.
107+
The simple scheme above is insufficient for public distribution of wheel files
108+
to Linux platforms, due to the large ecosystem of Linux platforms and subtle
109+
differences between them.
113110

114-
Instead, :pep:`600` defines the ``manylinux`` standard, which represents a
115-
common subset of Linux platforms, and allows building wheels tagged with the
111+
Instead, for those platforms, the ``manylinux`` standard represents a common
112+
subset of Linux platforms, and allows building wheels tagged with the
116113
``manylinux`` platform tag which can be used across most common Linux
117114
distributions.
118115

119-
There were multiple iterations of the ``manylinux`` specification, each
120-
representing the common subset of Linux platforms at a given point in time:
116+
The current standard is the future-proof ``manylinux_x_y`` standard. It defines
117+
tags of the form ``manylinux_x_y_arch``, where ``x`` and ``y`` are glibc major
118+
and minor versions supported (e.g. ``manylinux_2_24_xxx`` should work on any
119+
distro using glibc 2.24+), and ``arch`` is the architecture, matching the value
120+
of ``sysconfig.get_platform()`` on the system as in the "simple" form above.
121121

122-
* ``manylinux1`` (:pep:`513`) supports ``x86_64`` and ``i686``
123-
architectures, and is based on a compatible Linux platform from 2007.
124-
* ``manylinux2010`` (:pep:`571`) supports ``x86_64`` and ``i686``
125-
architectures. and updates the previous specification to be based on a
126-
compatible Linux platform from 2010 instead.
127-
* ``manylinux2014`` (:pep:`599`) adds support for a number of
128-
additional architectures (``aarch64``, ``armv7l``, ``ppc64``, ``ppc64le``,
129-
and ``s390x``) and updates the base platform to a compatible Linux platform
130-
from 2014.
122+
The following older tags are still supported for backward compatibility:
131123

132-
``manylinux_x_y`` (:pep:`600`) supersedes all previous PEPs to define a
133-
future-proof standard. It defines ``x`` and ``y`` as glibc major an minor
134-
versions supported (e.g. ``manylinux_2_24`` should work on any distro using
135-
glibc 2.24+). Previous tags are still supported for backward compatibility.
124+
* ``manylinux1`` is based on a compatible Linux platform from 2007,
125+
and supports ``x86_64`` and ``i686`` architectures.
126+
* ``manylinux2010`` is based on a platform from 2010 and supports ``x86_64``
127+
and ``i686``.
128+
* ``manylinux2014`` is based on a platform from 2014 and supports
129+
``x86_64``, ``i686``, ``aarch64``, ``armv7l``, ``ppc64``, ``ppc64le``,
130+
and ``s390x``.
136131

137132
In general, distributions built for older versions of the specification are
138133
forwards-compatible (meaning that ``manylinux1`` distributions should continue
@@ -302,3 +297,15 @@ Why is the ABI tag (the second tag) sometimes "none" in the reference implementa
302297
implementation at the time of writing guesses "none". Ideally it
303298
would detect "py27(d|m|u)" analogous to newer versions of Python,
304299
but in the meantime "none" is a good enough way to say "don't know".
300+
301+
302+
History
303+
=======
304+
305+
The following PEPs contributed to this spec:
306+
307+
- :pep:`425`: initial definition of platform tags
308+
- :pep:`513`: defined ``manylinux1``
309+
- :pep:`571`: defined ``manylinux2010``
310+
- :pep:`599`: defined ``manylinux2014``
311+
- :pep:`600`: defined the ``manylinux_x_y`` scheme

0 commit comments

Comments
 (0)