summaryrefslogtreecommitdiff
path: root/lib/elf_py.c
AgeCommit message (Collapse)Author
2022-04-04build: first header *must* be zebra.h or config.hDavid Lamparter
This has already been a requirement for Solaris, it is still a requirement for some of the autoconf feature checks to work correctly, and it will be a requirement for `-fms-extensions`. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2022-01-18lib/clippy: don't endian-convert twiceDavid Lamparter
elf_getdata_rawchunk() already endian-converts; doing it again is, uh, counterproductive. Fixes: #10051 Reported-by: Lucian Cristian <lucian.cristian@gmail.com> Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2021-11-10lib: fix elf_py TLS section handlingDavid Lamparter
... need to ignore TLS sections, their address is effectively meaningless but can overlap other sections we actually need to access. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2021-08-28lib/clippy: fix forgotten conditionalDavid Lamparter
This fixes some spurious warnings on *BSD, where `elffile_add_dynreloc` isn't used since `elf_getdata_rawchunk` is not available. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2021-04-08lib: add DT_REL to elf_py/clippy ELF codeDavid Lamparter
ARM (32-bit) needs DT_REL... and here I was hoping I could avoid the trouble. Fixes: #8355 Signed-off-by: David Lamparter <equinox@diac24.net>
2021-03-17*: require semicolon after DEFINE_<typesafe...>David Lamparter
Again, see previous commits. Signed-off-by: David Lamparter <equinox@diac24.net>
2021-02-23lib/clippy: add libelf wrapperDavid Lamparter
This adds _clippy.ELFFile, which provides a fast wrapper around libelf. The API is similar to / a subset of pyelfutils, which unfortunately is painfully slow (to the tune of minutes instead of seconds.) The idea is that xrefs can be read out of ELF files by reading out the "xref_array" section or "FRRouting/XREF" note. Signed-off-by: David Lamparter <equinox@diac24.net>