Skip to content

Commit

Permalink
fixed the alsr linker script
Browse files Browse the repository at this point in the history
  • Loading branch information
Athryx committed Mar 7, 2024
1 parent 332ab73 commit 91a16e8
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
3 changes: 2 additions & 1 deletion application_processor/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -215,8 +215,9 @@ fn main() {

println!("cargo:rustc-link-arg=--nmagic");

// Set the linker script to the one provided by cortex-m-rt.
// FIXME: make sure we are not accidently using cortex-m-rt linker script
println!("cargo:rustc-link-arg=-Tlink.x");
println!("cargo:rerun-if-changed=link.x");
}

let mut post_boot_build = cc::Build::new();
Expand Down
2 changes: 1 addition & 1 deletion application_processor/link.x
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ SECTIONS
__edata = .;

/* LMA of .data */
__sidata = LOADADDR(.data);
__sidata = LOADADDR(.data) + dataoffset;

/* ### .gnu.sgstubs
This section contains the TrustZone-M veneers put there by the Arm GNU linker. */
Expand Down
3 changes: 2 additions & 1 deletion component/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,9 @@ fn main() {

println!("cargo:rustc-link-arg=--nmagic");

// Set the linker script to the one provided by cortex-m-rt.
// FIXME: make sure we are not accidently using cortex-m-rt linker script
println!("cargo:rustc-link-arg=-Tlink.x");
println!("cargo:rerun-if-changed=link.x");
}

let mut post_boot_build = cc::Build::new();
Expand Down
2 changes: 1 addition & 1 deletion component/link.x
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ SECTIONS
__edata = .;

/* LMA of .data */
__sidata = LOADADDR(.data);
__sidata = LOADADDR(.data) + dataoffset;

/* ### .gnu.sgstubs
This section contains the TrustZone-M veneers put there by the Arm GNU linker. */
Expand Down

0 comments on commit 91a16e8

Please sign in to comment.