Outils pour utilisateurs

Outils du site


lang:python:wheel

Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Les deux révisions précédentesRévision précédente
Prochaine révision
Révision précédente
lang:python:wheel [2025/11/10 11:32] – Ajout de cibuildwheel rootlang:python:wheel [2025/11/10 12:17] (Version actuelle) – Ajout de "abi3audit" root
Ligne 23: Ligne 23:
 =====cibuildwheel===== =====cibuildwheel=====
  
-Il permet de compiler le projet pour n'importe quelle version de Python [[https://cibuildwheel.pypa.io/en/stable/options/#build-skip|Options]].+[[https://cibuildwheel.pypa.io/en/stable/|Site web]] [[https://cibuildwheel.pypa.io/en/stable/options/#build-skip|Options]] 
 + 
 +Il permet de compiler le projet pour n'importe quelle version de Python.
  
 Ce n'est intéressant que si le module python contient du code compilé et doit être compilé pour toutes les versions de Python compatibles. Ce n'est intéressant que si le module python contient du code compilé et doit être compilé pour toutes les versions de Python compatibles.
Ligne 60: Ligne 62:
 </code> </code>
  
 +=====manylinux=====
 +
 +[[https://github.com/pypa/manylinux|Site web]]
 +
 +Fournit des images Docker avec toutes les versions de Python pour générer les wheel pour Linux avec la glibc et musl.
 +
 +Rien n'est automatisé. Les installations de Python sont dans ''/opt/python/*/bin/python'' au format ''cp38-cp38'' / ''cp314-cp314t'' / ''pp311-pypy311_pp73''.
 +
 +''cibuildwheel'' supporte ''manylinux'' mais je ne l'ai pas testé.
 +
 +=====abi3audit=====
 +
 +[[https://github.com/pypa/abi3audit/|Site web]]
 +
 +Vérifie que le fichier wheel généré est compatible ''abi3'' stable. ''free-threading'' n'est pas ''abi3''.
 +
 +Un wheel indique via son nom la version minimale de Python et s'il est ''abi'' stable. Le fichier ''nh3-0.3.2-cp38-abi3-win_arm64.whl'' est ''abi3'' stable avec une version minimale de Python de 3.8.
 +
 +Exemple :
 +
 +<code bash>
 + abi3audit toto-1.3.1-cp38-abi3-win32.whl --verbose
 +[11:38:42] 👎 toto-1.3.1-cp38-abi3-win32.whl: bindings.cp314t-win32.pyd has non-ABI3 symbols
 +           👎 toto-1.3.1-cp38-abi3-win32.whl: bindings.cp314t-win32.pyd uses the Python 3.13
 +           ABI, but is tagged for the Python 3.8 ABI
 +           ┌────────────────────────────┬──────────┐
 +           │ Symbol                     │ Version 
 +           ├────────────────────────────┼──────────┤
 +           │ PyUnstable_Module_SetGIL   │ not ABI3 │
 +           │ _Py_DecRefShared           │ not ABI3 │
 +           │ PyMutex_Lock               │ not ABI3 │
 +           │ PyFrame_GetBack            │ not ABI3 │
 +           │ PyMethod_Type              │ not ABI3 │
 +           │ PyInstanceMethod_New       │ not ABI3 │
 +           │ _PyObject_GetDictPtr       │ not ABI3 │
 +           │ PyThreadState_GetUnchecked │ not ABI3 │
 +           │ PyObject_ClearManagedDict  │ not ABI3 │
 +           │ _PyType_Lookup             │ not ABI3 │
 +           │ PyInstanceMethod_Type      │ not ABI3 │
 +           │ PyObject_LengthHint        │ not ABI3 │
 +           │ PyObject_VisitManagedDict  │ not ABI3 │
 +           │ PyMutex_Unlock             │ not ABI3 │
 +           │ _Py_MergeZeroLocalRefcount │ not ABI3 │
 +           │ PyFrame_GetLineNumber      │ 3.10     │
 +           │ PyUnicode_AsUTF8AndSize    │ 3.10     │
 +           │ PyObject_CheckBuffer       │ 3.11     │
 +           │ PyObject_GenericGetDict    │ 3.10     │
 +           │ PyDict_GetItemStringRef    │ 3.13     │
 +           │ PyObject_GetBuffer         │ 3.11     │
 +           │ PyBuffer_Release           │ 3.11     │
 +           │ PyFrame_GetCode            │ 3.10     │
 +           │ PyCMethod_New              │ 3.9      │
 +           │ PyInterpreterState_Get     │ 3.9      │
 +           └────────────────────────────┴──────────┘
 +           💁 toto-1.3.1-cp38-abi3-win32.whl: 1 extensions scanned; 1 ABI version mismatches and
 +           15 ABI violations found
 +</code>
lang/python/wheel.1762770748.txt.gz · Dernière modification : de root