Change Log
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
Unreleased
v0.6.8 - 2019-04-02
Fixed
- Correct stack-pointer is selected on
HardFault - Linker template now takes and discard
*(.ARM.extab.*) - Misc. documentation fixes
Changed
- Architecture added:
armv8-m.main - Cortex-M team added to
authors - The nightly build is allowed to fail in CI
v0.6.7 - 2018-12-15
Fixed
- entry / exception / interrupt:
#[cfg]attributes used onstatic mutvariables are now properly handled.
v0.6.6 - 2018-12-06
Changed
-
Misuse of attributes now produce compiler errors with proper spans instead of panicking messages.
-
The
HardFaultsymbol has been renamed toHardFaultTrampoline; likewise theUserHardFaultsymbol has been renamed toHardFault. If you were using breakpoints onUserHardFaultto detect hard fault you should now put those breakpoints on theHardFaultsymbol.
Fixed
-
Attributes on local
static mutvariables (declared at the beginning ofentry/interrupt/exception) are now respected. -
The "GDB can now unwind HardFault callstacks" fix from the previous release broke
HardFault's'&ExceptionFrameargument (the pointer was off by 8 bytes). This release fixes that problem without compromising GDB's ability to unwindHardFaults.
v0.6.5 - 2018-10-23
Changed
- We now keep
.stack_sizesby default, for use with external tooling. - (macros) New
#[interrupt]attribute added, similar to#[exception]for use with device-specific interrupt handlers.
Fixed
- GDB can now unwind HardFault callstacks
v0.6.4 - 2018-09-25
Changed
- (macros) Improved the error message when any of the attribute is used on the wrong kind of item.
Fixed
-
(macros) The expansion of the
exceptionattribute now uses theextern "C"ABI which is what the hardware expects. -
(macros)
entryandexceptionnow respect the declared unsafety. That is#[entry] unsafe main() -> !won't requireunsafeblocks to useunsafeAPI.
v0.6.3 - 2018-09-09
Fixed
- Fixed the
randproblem for real.
v0.6.2 - 2018-09-09
Fixed
-
Worked around a Cargo limitation that broke builds that depend on
rand. -
Updated the documentation link in the README to point to working docs.
v0.6.1 - 2018-09-06
Changed
- Produce a better error message if two (or more) copies of
cortex-m-rtare going to be linked into a binary.
v0.6.0 - 2018-09-06
Changed
- [breaking-change] the
entry!,pre_init!andexception!macros have been replaced with attributes:#[entry],#[pre_init]and#[exception], respectively. This also changes the toolchain requirement to 1.30-beta or newer.
v0.5.3 - 2018-08-27
Changed
- This crate no longer depends on
arm-none-eabi-gcc.
v0.5.2 - 2018-08-11
Added
- A
pre_init!macro and related functionality to run a function immediately after reset, before memory initialisation
Changed
-
The
entry!andexception!macros now also accept a closure instead of a path. -
DefaultHandlerandUserHardFaultnow default to an infinite loop if left undefined.
Fixed
- Linked script modified to correctly detect
FLASHoverflow caused by.data
v0.5.1 - 2018-05-14
Fixed
- A recompilation problem where this
cortex-m-rtwould be recompiled every timecargo buildis invoked.
v0.5.0 - 2018-05-12
Added
-
An
entry!macro to set the entry point of the program. -
A
heap_startfunction that returns a pointer into the start of the heap region. -
A
devicefeature. When disabled this crate provides the interrupt vectors; when enabled the interrupt vectors are expected to be provided by another crate. Read the documentation for details.
Changed
-
This crate now compiles on the beta and stable channels.
-
[breaking-change] this crate now requires
arm-none-eabi-gccto be installed and available in$PATHto compile. -
[breaking-change] the
startlang item has been removed. The standardmaininterface won't work. Instead use#![no_main]and theentry!macro. See documentation for details. -
[breaking-change] the
default_handler!macro has been merged into theexception!macro. Useexception!(*, ..)to set the default exception handler. -
[breaking-change] there's no weak default handler so a default handler must be defined by the application, or one of its dependencies.
-
[breaking-change] the syntax of the third argument of the
exception!handler has changed. See the documentation of the macro for details. -
[breaking-change] the exception names that the
exception!macro accepts has changed to match the CMSIS specification. See the documentation of the macro for the list of names it accepts. -
[breaking-change] The number of symbol interfaces has been reduced. Check the advanced section of the documentation for details.
v0.4.0 - 2018-04-09
Added
- LLD support. The linker script provided by this crate has been tweaked to support both LLD and GNU
LD. To use LLD as a linker change
.cargo/configto look like this:
[target.thumbv7m-none-eabi]
rustflags = [
"-C", "link-arg=-Tlink.x",
- "-C", "linker=arm-none-eabi-ld",
- "-Z", "linker-flavor=ld",
+ "-C", "linker=lld",
+ "-Z", "linker-flavor=ld.lld",
]Removed
-
[breaking-change] Stack overflow protection has been removed. Unfortunately, supporting this feature produces totally wrong
arm-none-eabi-sizereports when LLD is used to link the program. If you need the stack overflow protection feature you can continue to use version v0.3.13+. -
[breaking-change] The "abort-on-panic" Cargo feature, which provided a
panic_fmtimplementation, has been removed. If you were using this feature you can instead use a panic implementation crate.
v0.3.15 - 2018-04-08
Fixed
- Support the newest nightly
v0.3.14 - 2018-04-01
Fixed
devchannel support
v0.3.13 - 2018-02-17
Added
-
Fictitious
.stackand.heaplinker sections that represent the locations of the stack and the heap in RAM. You can visualize these linker sections by runningarm-none-eabi-size -Axover your binary. -
Zero cost stack overflow protection when you use the
cortex-m-rt-ldlinker. Check documentation for details. -
A
_heap_sizesymbol that indicates how large the heap is. This symbol is only used whencortex-m-rt-ldis used as a linker.
v0.3.12 - 2018-01-17
Fixed
- Support for recent nightlies.
v0.3.11 - 2018-01-17 - YANKED
Changed
- Dynamically support recent nightlies, which have the
terminationlang item, and nightly-2017-09-22, which doesn't. That nightly version is used by the docs.rs builder. Supporting that version instead of rejecting it ensures this crate and its reverse-dependencies will get their documentation built by the docs.rs service.
v0.3.10 - 2018-01-17 - YANKED
Removed
- The nightly date check from build script that improved error messages for users of old, unsupported nightlies. Unfortunately the check was preventing this crate and reverse-dependencies from getting their documentation build on docs.rs
v0.3.9 - 2018-01-07
Fixed
cargo docwarnings
v0.3.8 - 2017-12-29
Added
Terminationlang item
Changed
- The
startlang item to match the new signature
v0.3.7 - 2017-12-23
Added
- Support for overriding the DEBUG_MONITOR exception handler on ARMv7-M.
v0.3.6 - 2017-10-03
Fixed
- Builds with multiple codegen units by forcing the linker to look harder for the exceptions vector table.
v0.3.5 - 2017-07-21
Fixed
- Remove duplication of default exception handlers. This saves 32 bytes of Flash memory (.text).
v0.3.4 - 2017-07-19
Changed
-
Align the end of .rodata to a 4-byte boundary. With this the sections that will go into Flash memory will be 4 byte aligned at the start and at the end. Which seems to be required (?) by Cortex-M0 devices.
-
.bss and .data are now padded so their sizes are multiple of 4 bytes. This improves the output of
objdump; before, the output showed "Address 0x20000004 is out of bounds". -
Linking now aborts if any of the input files contains a .got section. Dynamic relocations are not supported and Rust code is not relocatable by default. This error only occurs if C code that was compiled with the -fPIC flag is linked in. The error message will tell the user how to compile their C code without -fPIC.
v0.3.3 - 2017-07-14
Changed
- Updated the documentation: it's no longer necessary to use the
compiler-builtins repository since that crate landed in rust-lang/rust and
it's now available in the
rust-srccomponent.
v0.3.2 - 2017-07-07
Changed
- Tweaked documentation
v0.3.1 - 2017-07-07
Fixed
- A warning when compiling for x86_64 and the "abort-on-panic" feature is enabled.
v0.3.0 - 2017-07-07
Added
-
A
default_handler!macro to override the default exception handler. -
An
exception!macro to override the handler for a particular exception.
Changed
-
The FPU will now be enabled before
mainif the target has FPU support. -
[breaking-change] the features "panic-over-itm" and "panic-over-semihosting" has been removed. the
panic_fmtlanguage item is now not included by default. An opt-in feature named "abort-on-panic" can be enabled to make this crate provide apanic_fmtimplementation that simply aborts. -
[breaking-change] The sections
.rodata.{exceptions,interrupts}have been renamed to.vector_table.{exceptions,interrupts}. This break the old mechanism for registering exceptions (static EXCEPTIONS); use the new ones:default_handler!andexception!. -
The
_stack_startis now optional in thememory.xfile. If unspecified its value will be set toORIGIN(RAM) + LENGTH(RAM).
v0.2.4 - 2017-06-03
Added
- A non-allocatable
.stlogsection to support thestloglogging framework.
v0.2.3 - 2017-05-30
Added
- A
_stextsymbol which can be specified in the linker script to customize the location of the.textsection. If not specified the.textsection will be placed right after the.vector_tablesection.
v0.2.2 - 2017-05-27
Added
- A
_sheapsymbol where the heap can be located.
Changed
- The linker sections have renamed / reorder to make
arm-none-eabi-size -Amore useful. You'll now see something like this:
$ arm-none-eabi-size -A hello
hello :
section size addr
.vector_table 1024 134217728
.text 288 134218752
.rodata 14 134219040
-
cortex-m-rt::reset_handleris now the entry point of all programs that link tocortex-m-rt. This makes GDB'sloadcommand work correctly. It will now set the Program Counter toreset_handlerafter flashing the program so there's no need to reset the microcontroller after flashing. -
Renamed
__exceptionsand__interruptssymbols, which are only used internally, to_eexceptionsand_einterruptsrespectively for consistency.
Fixed
- Include input
.textand.rodatasections (note: no suffix as in.text.foo) in the output file. (C) Code compiled without the equivalent-ffunction-sections/-fdata-sectionsmay place stuff in those unsuffixed sections.
v0.2.1 - 2017-05-07
Fixed
- Do not load the
.debug_gdb_scriptsection in flash. It's only needed for debugging.
v0.2.0 - 2017-04-27
Changed
- [breaking-change] the
_stack_startsymbol is now required and must be provided in thememory.xfile when using the "linker-script" feature. This symbol indicates where in memory the call stack will be allocated.
v0.1.3 - 2017-04-25
Fixed
- A
rustdocwarning
v0.1.2 - 2017-04-22
Changed
- Unclutter the
reset_handlerfunction for a better debugging experience.
v0.1.1 - 2017-04-15
Changed
- Improved linker error messages
v0.1.0 - 2017-04-12
Initial release