Skip to content
Snippets Groups Projects
Commit 8efe8ef4 authored by Guillem Jover's avatar Guillem Jover
Browse files

Dpkg::Shlibs::Objdump: Encode the ELF ABI as a big-endian byte stream

This way when unpacking for output, the result gives meaningful results.
parent 0cdf7ebb
No related branches found
No related tags found
No related merge requests found
......@@ -6,6 +6,8 @@ dpkg (1.18.20) UNRELEASED; urgency=medium
Dpkg::Shlibs::Objdump. These do not define the ABI, and make the
objects not match when they should, when looking for shared libraries
from dpkg-shlibdeps.
- Encode the ELF ABI as a big-endian byte stream, so that decoding for
output gives meaningful results.
 
[ Updated scripts translations ]
* German (Helge Kreutzmann).
......
......@@ -180,8 +180,9 @@ sub get_format {
# Mask any processor flags that might not change the architecture ABI.
$elf{flags} &= $elf_flags_mask{$elf{mach}} // 0;
# Repack for easy comparison.
$format{$file} = pack 'C2SL', @elf{qw(bits endian mach flags)};
# Repack for easy comparison, as a big-endian byte stream, so that
# unpacking for output gives meaningful results.
$format{$file} = pack 'C2(SL)>', @elf{qw(bits endian mach flags)};
return $format{$file};
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment