![]() |
|
Message-ID: <20250415021730.GU1827@brightrain.aerifal.cx> Date: Mon, 14 Apr 2025 22:17:31 -0400 From: Rich Felker <dalias@...c.org> To: David Leonard <d@...ptive-enterprises.com> Cc: musl@...ts.openwall.com Subject: Re: [PATCH] arm: add support for R_ARM_REL32 relocations On Tue, Apr 15, 2025 at 09:50:37AM +1000, David Leonard wrote: > > This fixes an issue found after building libpcap.so with -Os: > > Error relocating /lib/libpcap.so.1: unsupported relocation type 3 > > $ readelf -Dr lib/libpcap.so.1.10.4 | grep R_ARM_REL32 > 00019058 0000be03 R_ARM_REL32 00037044 eproto_db > > > --- > arch/arm/reloc.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/arch/arm/reloc.h b/arch/arm/reloc.h > index d98eb8af..d055b68c 100644 > --- a/arch/arm/reloc.h > +++ b/arch/arm/reloc.h > @@ -17,6 +17,7 @@ > #define TPOFF_K 0 > > #define REL_SYMBOLIC R_ARM_ABS32 > +#define REL_OFFSET32 R_ARM_REL32 > #define REL_GOT R_ARM_GLOB_DAT > #define REL_PLT R_ARM_JUMP_SLOT > #define REL_RELATIVE R_ARM_RELATIVE > -- > 2.43.0 Are you sure this is correct, and can you figure out how a relocation of this type was emitted by the linker? Usually this kind of error comes from non-PIC-compatible code getting linked into a shared library, and adding a mapping for the reloc type may just paper over an error that's going to make something crash later on. Rich
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.