Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions objdiff-core/src/obj/read.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use alloc::{
use core::{cmp::Ordering, num::NonZeroU64};

use anyhow::{Context, Result, anyhow, bail, ensure};
use object::{Object as _, ObjectSection as _, ObjectSymbol as _};
use object::{Architecture, Object as _, ObjectSection as _, ObjectSymbol as _};

use crate::{
arch::{Arch, RelocationOverride, RelocationOverrideTarget, new_arch},
Expand Down Expand Up @@ -133,7 +133,9 @@ fn map_symbol(
if symbol.is_weak() {
flags |= SymbolFlag::Weak;
}
if file.format() == object::BinaryFormat::Elf && symbol.scope() == object::SymbolScope::Linkage
if file.format() == object::BinaryFormat::Elf
&& symbol.scope() == object::SymbolScope::Linkage
&& (file.architecture() != Architecture::Arm || !symbol.is_global())
{
flags |= SymbolFlag::Hidden;
}
Expand Down
Loading