codekingpro/portable-devtools
115k
1#ifndef _Py_PATCHLEVEL_H2#define _Py_PATCHLEVEL_H3/* Python version identification scheme.4 5 When the major or minor version changes, the VERSION variable in6 configure.ac must also be changed.7 8 There is also (independent) API version information in modsupport.h.9*/10 11/* Values for PY_RELEASE_LEVEL */12#define PY_RELEASE_LEVEL_ALPHA 0xA13#define PY_RELEASE_LEVEL_BETA 0xB14#define PY_RELEASE_LEVEL_GAMMA 0xC /* For release candidates */15#define PY_RELEASE_LEVEL_FINAL 0xF /* Serial should be 0 here */16 /* Higher for patch releases */17 18/* Version parsed out into numeric values */19/*--start constants--*/20#define PY_MAJOR_VERSION 321#define PY_MINOR_VERSION 1422#define PY_MICRO_VERSION 423#define PY_RELEASE_LEVEL PY_RELEASE_LEVEL_FINAL24#define PY_RELEASE_SERIAL 025 26/* Version as a string */27#define PY_VERSION "3.14.4"28/*--end constants--*/29 30 31#define _Py_PACK_FULL_VERSION(X, Y, Z, LEVEL, SERIAL) ( \32 (((X) & 0xff) << 24) | \33 (((Y) & 0xff) << 16) | \34 (((Z) & 0xff) << 8) | \35 (((LEVEL) & 0xf) << 4) | \36 (((SERIAL) & 0xf) << 0))37 38/* Version as a single 4-byte hex number, e.g. 0x010502B2 == 1.5.2b2.39 Use this for numeric comparisons, e.g. #if PY_VERSION_HEX >= ... */40#define PY_VERSION_HEX _Py_PACK_FULL_VERSION( \41 PY_MAJOR_VERSION, \42 PY_MINOR_VERSION, \43 PY_MICRO_VERSION, \44 PY_RELEASE_LEVEL, \45 PY_RELEASE_SERIAL)46 47// Public Py_PACK_VERSION is declared in pymacro.h; it needs <inttypes.h>.48 49#endif //_Py_PATCHLEVEL_H50 