00001 #ifndef CLASSLIB_SYSAPI_ELF_ABI_H
00002 # define CLASSLIB_SYSAPI_ELF_ABI_H
00003
00004
00005
00006 # include "classlib/sysapi/system.h"
00007 # ifndef _WIN32
00008 # if HAVE_LOADER_H
00009 # include <loader.h>
00010 # endif
00011 # if HAVE_LINK_H
00012 # include <link.h>
00013 # include <limits.h>
00014 # include <sys/stat.h>
00015 # include <unistd.h>
00016 # endif
00017 # if HAVE_SGIDEFS_H // irix n32, 64
00018 # include <sgidefs.h>
00019 # include <objlist.h>
00020 # include <obj_list.h>
00021 # include <obj.h>
00022 # endif
00023 # if HAVE_ELF_H
00024 # include <elf.h>
00025 # endif
00026 # endif // ! _WIN32
00027
00028
00029
00030 #if (defined ABI64 || defined _ABI64 || \
00031 (defined _MIPS_SIM && _MIPS_SIM == _MIPS_SIM_ABI64)) \
00032 || (defined sparcv9 || defined _sparcv9 \
00033 || defined __sparcv9 || defined __sparcv9__) \
00034 || (defined arch64 || defined _arch64 || \
00035 defined __arch64 || defined __arch64__)
00036 # define ELF_ABI 64
00037 #else
00038 # define ELF_ABI 32
00039 #endif
00040 #ifndef ElfW
00041 # define ElfW(type) ElfW1(Elf,ELF_ABI,type)
00042 # define ElfW1(e,w,t) ElfW2(Elf,w,_##t)
00043 # define ElfW2(e,w,t) e ## w ## t
00044 #endif
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054 #endif // CLASSLIB_SYSAPI_ELF_ABI_H