Files
Alessandro Gatti e939d3ec76 tools/mpy_ld.py: Add RV64 natmod support.
This commit adds the ability to compile native modules for the RV64
platform, using "rv64imc" as its architecture name (eg.
"make ARCH=rv64imc" should build a RV64 natmod).

The rest of 64-bits relocations needed to build a native module are now
implemented, and all sample native modules build without errors or
warnings.  The same Picolibc caveats on RV32 also apply on RV64, thus
the documentation was updated accordingly.

RV64 native modules are also built as part of the CI process, but not
yet executed as the QEMU port is not yet able to load and run them.

Signed-off-by: Alessandro Gatti <a.gatti@frob.it>
2025-12-30 18:18:42 +01:00

18 lines
421 B
Makefile

# Location of top-level MicroPython directory
MPY_DIR = ../../..
# Name of module
MOD = features2
# Source files (.c or .py)
SRC = main.c prod.c test.py
# Architecture to build for (x86, x64, armv7m, xtensa, xtensawin, rv32imc, rv64imc)
ARCH = x64
# Link with libm.a and libgcc.a from the toolchain
LINK_RUNTIME = 1
# Include to get the rules for compiling and linking the module
include $(MPY_DIR)/py/dynruntime.mk