diff options
author | Yonatan Goldschmidt <yon.goldschmidt@gmail.com> | 2018-06-09 02:48:29 +0300 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2018-06-12 13:50:11 +1000 |
commit | 6630354ffe9f33d2af8154fbac003cb4db0cc348 (patch) | |
tree | d6d9dde5517b6a8d0bab2e6997b0f0cad3be47c3 /py | |
parent | 38682d4629c0c87d3a20330dcb10cb4e01e09aed (diff) |
extmod/moduhashlib: Allow to disable the sha256 class.
Via the config value MICROPY_PY_UHASHLIB_SHA256. Default to enabled to
keep backwards compatibility.
Also add default value for the sha1 class, to at least document its
existence.
Diffstat (limited to 'py')
-rw-r--r-- | py/mpconfig.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/py/mpconfig.h b/py/mpconfig.h index a85b22128..08d100549 100644 --- a/py/mpconfig.h +++ b/py/mpconfig.h @@ -1155,6 +1155,14 @@ typedef double mp_float_t; #define MICROPY_PY_UHASHLIB (0) #endif +#ifndef MICROPY_PY_UHASHLIB_SHA1 +#define MICROPY_PY_UHASHLIB_SHA1 (0) +#endif + +#ifndef MICROPY_PY_UHASHLIB_SHA256 +#define MICROPY_PY_UHASHLIB_SHA256 (1) +#endif + #ifndef MICROPY_PY_UBINASCII #define MICROPY_PY_UBINASCII (0) #endif |