summaryrefslogtreecommitdiff
path: root/utils/readsoname.c
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2005-01-12 01:22:59 +0000
committerEric Andersen <andersen@codepoet.org>2005-01-12 01:22:59 +0000
commit8f6b29e669ac593f07c7b8f4eb1507aa12c14983 (patch)
treecc814a8ac48da641a9c6296c24c23751ac4746c2 /utils/readsoname.c
parent7faa798bed2130a7cebc49f4c055b9873e19a768 (diff)
cleanup, and prevent failures due to including architecture specific
header files into ldconfig when building for the host.
Diffstat (limited to 'utils/readsoname.c')
-rw-r--r--utils/readsoname.c63
1 files changed, 0 insertions, 63 deletions
diff --git a/utils/readsoname.c b/utils/readsoname.c
deleted file mode 100644
index 813710c98..000000000
--- a/utils/readsoname.c
+++ /dev/null
@@ -1,63 +0,0 @@
-/* adapted from Eric Youngdale's readelf program */
-
-#include <stdio.h>
-#include <string.h>
-#include <sys/stat.h>
-#include <sys/mman.h>
-#include <link.h>
-#include <unistd.h>
-#include <sys/types.h>
-#include "dl-elf.h"
-#include "readsoname.h"
-
-void warn(char *fmt, ...);
-char *xstrdup(char *);
-
-struct needed_tab
-{
- char *soname;
- int type;
-};
-
-struct needed_tab needed_tab[] = {
- { "libc.so.0", LIB_ELF_LIBC0 },
- { "libm.so.0", LIB_ELF_LIBC0 },
- { "libdl.so.0", LIB_ELF_LIBC0 },
- { "libc.so.5", LIB_ELF_LIBC5 },
- { "libm.so.5", LIB_ELF_LIBC5 },
- { "libdl.so.1", LIB_ELF_LIBC5 },
- { "libc.so.6", LIB_ELF_LIBC6 },
- { "libm.so.6", LIB_ELF_LIBC6 },
- { "libdl.so.2", LIB_ELF_LIBC6 },
- { NULL, LIB_ELF }
-};
-
-char *readsoname(char *name, FILE *infile, int expected_type,
- int *type, int elfclass)
-{
- char *res;
-
- if (elfclass == ELFCLASS32)
- res = readsoname32(name, infile, expected_type, type);
- else
- {
- res = readsoname64(name, infile, expected_type, type);
-#if 0
- *type |= LIB_ELF64;
-#endif
- }
-
- return res;
-}
-
-#undef __ELF_NATIVE_CLASS
-#undef readsonameXX
-#define readsonameXX readsoname32
-#define __ELF_NATIVE_CLASS 32
-#include "readsoname2.c"
-
-#undef __ELF_NATIVE_CLASS
-#undef readsonameXX
-#define readsonameXX readsoname64
-#define __ELF_NATIVE_CLASS 64
-#include "readsoname2.c"