summaryrefslogtreecommitdiff
path: root/include/libelfu/elfops.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/libelfu/elfops.h')
-rw-r--r--include/libelfu/elfops.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/include/libelfu/elfops.h b/include/libelfu/elfops.h
new file mode 100644
index 0000000..a57069d
--- /dev/null
+++ b/include/libelfu/elfops.h
@@ -0,0 +1,20 @@
+#ifndef __LIBELFU_ELFOPS_H_
+#define __LIBELFU_ELFOPS_H_
+
+#include <libelf.h>
+#include <gelf.h>
+
+#include <libelfu/types.h>
+
+size_t elfu_scnSizeFile(const GElf_Shdr *shdr);
+
+char* elfu_sectionName(Elf *e, Elf_Scn *scn);
+Elf_Scn* elfu_sectionByName(Elf *e, char *name);
+
+int elfu_segmentContainsSection(GElf_Phdr *phdr, GElf_Shdr *shdr);
+Elf_Scn* elfu_firstSectionInSegment(Elf *e, GElf_Phdr *phdr);
+Elf_Scn* elfu_lastSectionInSegment(Elf *e, GElf_Phdr *phdr);
+
+void elfu_fixupPhdrSelfRef(Elf *e);
+
+#endif