README.txt 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. About
  2. =====
  3. _decimal.c is a wrapper for the libmpdec library. libmpdec is a fast C
  4. library for correctly-rounded arbitrary precision decimal floating point
  5. arithmetic. It is a complete implementation of Mike Cowlishaw/IBM's
  6. General Decimal Arithmetic Specification.
  7. Build process for the module
  8. ============================
  9. As usual, the build process for _decimal.so is driven by setup.py in the top
  10. level directory. setup.py autodetects the following build configurations:
  11. 1) x64 - 64-bit Python, x86_64 processor (AMD, Intel)
  12. 2) uint128 - 64-bit Python, compiler provides __uint128_t (gcc)
  13. 3) ansi64 - 64-bit Python, ANSI C
  14. 4) ppro - 32-bit Python, x86 CPU, PentiumPro or later
  15. 5) ansi32 - 32-bit Python, ANSI C
  16. 6) ansi-legacy - 32-bit Python, compiler without uint64_t
  17. 7) universal - Mac OS only (multi-arch)
  18. It is possible to override autodetection by exporting:
  19. PYTHON_DECIMAL_WITH_MACHINE=value, where value is one of the above options.
  20. NOTE
  21. ====
  22. decimal.so is not built from a static libmpdec.a since doing so led to
  23. failures on AIX (user report) and Windows (mixing static and dynamic CRTs
  24. causes locale problems and more).