aboutsummaryrefslogtreecommitdiffstats
path: root/elfops.c
diff options
context:
space:
mode:
Diffstat (limited to 'elfops.c')
-rw-r--r--elfops.c25
1 files changed, 25 insertions, 0 deletions
diff --git a/elfops.c b/elfops.c
new file mode 100644
index 0000000..e9d74ef
--- /dev/null
+++ b/elfops.c
@@ -0,0 +1,25 @@
+/* The nasty work of reading 32 and 64-bit modules is in here. */
+#include <elf.h>
+#include <sys/types.h>
+#include <unistd.h>
+#include <stdlib.h>
+#include <string.h>
+#include <errno.h>
+#include "depmod.h"
+#include "util.h"
+#include "logging.h"
+#include "elfops.h"
+#include "tables.h"
+
+#define PERBIT(x) x##32
+#define ElfPERBIT(x) Elf32_##x
+#define ELFPERBIT(x) ELF32_##x
+#include "elfops_core.c"
+
+#undef PERBIT
+#undef ElfPERBIT
+#undef ELFPERBIT
+#define PERBIT(x) x##64
+#define ElfPERBIT(x) Elf64_##x
+#define ELFPERBIT(x) ELF64_##x
+#include "elfops_core.c"