patchlevel.h 1.3 KB

1234567891011121314151617181920212223242526272829303132333435
  1. /* Python version identification scheme.
  2. When the major or minor version changes, the VERSION variable in
  3. configure.ac must also be changed.
  4. There is also (independent) API version information in modsupport.h.
  5. */
  6. /* Values for PY_RELEASE_LEVEL */
  7. #define PY_RELEASE_LEVEL_ALPHA 0xA
  8. #define PY_RELEASE_LEVEL_BETA 0xB
  9. #define PY_RELEASE_LEVEL_GAMMA 0xC /* For release candidates */
  10. #define PY_RELEASE_LEVEL_FINAL 0xF /* Serial should be 0 here */
  11. /* Higher for patch releases */
  12. /* Version parsed out into numeric values */
  13. /*--start constants--*/
  14. #define PY_MAJOR_VERSION 3
  15. #define PY_MINOR_VERSION 12
  16. #define PY_MICRO_VERSION 0
  17. #define PY_RELEASE_LEVEL PY_RELEASE_LEVEL_FINAL
  18. #define PY_RELEASE_SERIAL 0
  19. /* Version as a string */
  20. #define PY_VERSION "3.12.0"
  21. /*--end constants--*/
  22. /* Version as a single 4-byte hex number, e.g. 0x010502B2 == 1.5.2b2.
  23. Use this for numeric comparisons, e.g. #if PY_VERSION_HEX >= ... */
  24. #define PY_VERSION_HEX ((PY_MAJOR_VERSION << 24) | \
  25. (PY_MINOR_VERSION << 16) | \
  26. (PY_MICRO_VERSION << 8) | \
  27. (PY_RELEASE_LEVEL << 4) | \
  28. (PY_RELEASE_SERIAL << 0))