diff --git a/source/CMakeLists.txt b/source/CMakeLists.txt index f98a2ec9..0932efb1 100755 --- a/source/CMakeLists.txt +++ b/source/CMakeLists.txt @@ -86,17 +86,15 @@ if (YOTTA_CFG_MICROBIT_CONFIGFILE) endif () if(CMAKE_COMPILER_IS_GNUCC) - file(REMOVE "asm/CortexContextSwitch.s") - configure_file("asm/CortexContextSwitch.s.gcc" "asm/CortexContextSwitch.s" COPYONLY) + set(YOTTA_AUTO_MICROBIT-DAL_S_FILES + "asm/TOOLCHAIN_GCC_ARM/CortexContextSwitch.s" + ) else() - file(REMOVE "asm/CortexContextSwitch.s") - configure_file("asm/CortexContextSwitch.s.armcc" "asm/CortexContextSwitch.s" COPYONLY) + set(YOTTA_AUTO_MICROBIT-DAL_S_FILES + "asm/TOOLCHAIN_ARM_STD/CortexContextSwitch.S" + ) endif() -set(YOTTA_AUTO_MICROBIT-DAL_S_FILES - "asm/CortexContextSwitch.s" -) - add_library(microbit-dal ${YOTTA_AUTO_MICROBIT-DAL_CPP_FILES} ${YOTTA_AUTO_MICROBIT-DAL_S_FILES} diff --git a/source/asm/CortexContextSwitch.s.armcc b/source/asm/TOOLCHAIN_ARM_STD/CortexContextSwitch.S similarity index 100% rename from source/asm/CortexContextSwitch.s.armcc rename to source/asm/TOOLCHAIN_ARM_STD/CortexContextSwitch.S diff --git a/source/asm/CortexContextSwitch.s.gcc b/source/asm/TOOLCHAIN_GCC_ARM/CortexContextSwitch.s similarity index 100% rename from source/asm/CortexContextSwitch.s.gcc rename to source/asm/TOOLCHAIN_GCC_ARM/CortexContextSwitch.s