ukify: Add workarounds for older stubs
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Tue, 28 Mar 2023 11:32:03 +0000 (13:32 +0200)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Tue, 28 Mar 2023 16:17:59 +0000 (18:17 +0200)
commitac3412c379fe028aa62a6aec2c302b9deab44c64
tree9ecbfd781b6646abadf23194cf6180fe63ed6caa
parent61648c697668c6082bca294ca9cd2d5399337b67
ukify: Add workarounds for older stubs

Older stubs are either not stripped, causing their total size to be
unaligned because of an unaligned symbol table at the end, or stripped,
causing the raw data pointers and sizes to be unaligned because strip
does not follow the PE spec correctly when stripping. Let's add
workarounds for both issues, so that we can use ukify with older stubs
as well.
src/ukify/ukify.py