Improve support for hand-written asm source files in PIO
Closes: https://github.com/espressif/arduino-esp32/pull/6817 Co-Authored-By: Ivan Kravets <me@ikravets.com>
This commit is contained in:
parent
be120d32a2
commit
6b3443e5c5
2 changed files with 11 additions and 1 deletions
|
|
@ -11,7 +11,7 @@ idf_build_get_property(elf EXECUTABLE GENERATOR_EXPRESSION)
|
|||
|
||||
add_custom_command(
|
||||
OUTPUT "idf_libs"
|
||||
COMMAND ${CMAKE_SOURCE_DIR}/tools/copy-libs.sh ${IDF_TARGET} "${CONFIG_ESPTOOLPY_OCT_FLASH}" "${CONFIG_SPIRAM_MODE_OCT}"
|
||||
COMMAND ${CMAKE_SOURCE_DIR}/tools/copy-libs.sh ${IDF_TARGET} "${CONFIG_ESPTOOLPY_OCT_FLASH}" "${CONFIG_SPIRAM_MODE_OCT}" "${CONFIG_IDF_TARGET_ARCH_XTENSA}"
|
||||
DEPENDS ${elf}
|
||||
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
|
||||
VERBATIM
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
# config
|
||||
|
||||
IDF_TARGET=$1
|
||||
IS_XTENSA=$4
|
||||
OCT_FLASH=
|
||||
OCT_PSRAM=
|
||||
if [ "$2" = "y" ]; then
|
||||
|
|
@ -281,6 +282,15 @@ cat pio_start.txt > "$AR_PLATFORMIO_PY"
|
|||
rm pio_end.txt 1pio_start.txt pio_start.txt
|
||||
|
||||
echo " ASFLAGS=[" >> "$AR_PLATFORMIO_PY"
|
||||
if [ "$IS_XTENSA" = "y" ]; then
|
||||
echo " \"-mlongcalls\"" >> "$AR_PLATFORMIO_PY"
|
||||
else
|
||||
echo " \"-march=rv32imc\"" >> "$AR_PLATFORMIO_PY"
|
||||
fi
|
||||
echo " ]," >> "$AR_PLATFORMIO_PY"
|
||||
echo "" >> "$AR_PLATFORMIO_PY"
|
||||
|
||||
echo " ASPPFLAGS=[" >> "$AR_PLATFORMIO_PY"
|
||||
set -- $PIO_AS_FLAGS
|
||||
for item; do
|
||||
echo " \"$item\"," >> "$AR_PLATFORMIO_PY"
|
||||
|
|
|
|||
Loading…
Reference in a new issue