qemu/mpconfigport: Enable VFS reader, loading .mpy files and io.IOBase.

This allows importing from the VFS, and enables the following 7 additional
tests: builtin_execfile, io_iobase, json_dump_iobase, import_mpy_invalid,
import_mpy_native, import_mpy_native_gc, vfs_userfs.

Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
Damien George
2024-11-25 23:57:50 +11:00
parent ee8d8b3448
commit 46a37a09fd
2 changed files with 2 additions and 5 deletions

View File

@@ -71,10 +71,6 @@ void gc_collect(void) {
gc_collect_end();
}
mp_lexer_t *mp_lexer_new_from_file(qstr filename) {
mp_raise_OSError(MP_ENOENT);
}
void nlr_jump_fail(void *val) {
mp_printf(&mp_plat_print, "uncaught NLR\n");
exit(1);

View File

@@ -42,13 +42,14 @@
#endif
#define MICROPY_MALLOC_USES_ALLOCATED_SIZE (1)
#define MICROPY_PERSISTENT_CODE_LOAD (1)
#define MICROPY_MEM_STATS (1)
#define MICROPY_READER_VFS (1)
#define MICROPY_ENABLE_GC (1)
#define MICROPY_ENABLE_EMERGENCY_EXCEPTION_BUF (1)
#define MICROPY_LONGINT_IMPL (MICROPY_LONGINT_IMPL_MPZ)
#define MICROPY_FLOAT_IMPL (MICROPY_FLOAT_IMPL_FLOAT)
#define MICROPY_WARNINGS (1)
#define MICROPY_PY_IO_IOBASE (0)
#define MICROPY_PY_SYS_PLATFORM "qemu"
#define MICROPY_PY_SYS_STDIO_BUFFER (0)
#define MICROPY_PY_SELECT (0)