diff --git a/crates/linker/src/pe.rs b/crates/linker/src/pe.rs index 74069d1696..e05e81b941 100644 --- a/crates/linker/src/pe.rs +++ b/crates/linker/src/pe.rs @@ -364,6 +364,7 @@ pub(crate) fn surgery_pe(executable_path: &Path, metadata_path: &Path, roc_app_b } = app_relocation; if let Some(destination) = md.exports.get(name) { + dbg!(&name); match relocation.kind() { object::RelocationKind::Relative => { // we implicitly only do 32-bit relocations @@ -383,6 +384,8 @@ pub(crate) fn surgery_pe(executable_path: &Path, metadata_path: &Path, roc_app_b // we implicitly only do 32-bit relocations debug_assert_eq!(relocation.size(), 32); + dbg!(&name); + let delta = destination - section_virtual_address as i64 - *offset_in_section as i64 + relocation.addend(); @@ -411,6 +414,8 @@ pub(crate) fn surgery_pe(executable_path: &Path, metadata_path: &Path, roc_app_b ); } + dbg!(&name); + match relocation.kind() { object::RelocationKind::Relative => { // we implicitly only do 32-bit relocations