py: Always give noop defines when MICROPY_ROM_TEXT_COMPRESSION disabled.
This commit provides a typedef for mp_rom_error_text_t, and a macro define for MP_COMPRESSED_ROM_TEXT, when MICROPY_ROM_TEXT_COMPRESSION is disabled. This simplifies the configuration (it no longer has a special case for MICROPY_ENABLE_DYNRUNTIME) and makes it work for other cases that don't use compression (eg examples/embedding). This commit also ensures MICROPY_ROM_TEXT_COMPRESSION is defined during qstr processing.
This commit is contained in:
@@ -38,8 +38,9 @@
|
||||
#include "py/gc.h"
|
||||
#include "py/mperrno.h"
|
||||
|
||||
// Extract the MP_MAX_UNCOMPRESSED_TEXT_LEN macro from "genhdr/compressed.data.h"
|
||||
#if MICROPY_ROM_TEXT_COMPRESSION
|
||||
#if MICROPY_ROM_TEXT_COMPRESSION && !defined(NO_QSTR)
|
||||
// Extract the MP_MAX_UNCOMPRESSED_TEXT_LEN macro from "genhdr/compressed.data.h".
|
||||
// Only need this if compression enabled and in a regular build (i.e. not during QSTR extraction).
|
||||
#define MP_MATCH_COMPRESSED(...) // Ignore
|
||||
#define MP_COMPRESSED_DATA(...) // Ignore
|
||||
#include "genhdr/compressed.data.h"
|
||||
|
||||
Reference in New Issue
Block a user