Some progress towards libunwind compiling
* Add main Jamfile * Add x86_64 Jamfile * Add config.h for Haiku * Add defines missing from elf.h * Don't include some missing files
This commit is contained in:
parent
18941b085c
commit
7a541d13ed
@ -11,6 +11,7 @@ SubInclude HAIKU_TOP src libs gnu ;
|
||||
SubInclude HAIKU_TOP src libs icon ;
|
||||
SubInclude HAIKU_TOP src libs iconv ;
|
||||
SubInclude HAIKU_TOP src libs libtelnet ;
|
||||
SubInclude HAIKU_TOP src libs libunwind ;
|
||||
SubInclude HAIKU_TOP src libs linprog ;
|
||||
SubInclude HAIKU_TOP src libs mapm ;
|
||||
SubInclude HAIKU_TOP src libs pdflib ;
|
||||
|
8
src/libs/libunwind/Jamfile
Normal file
8
src/libs/libunwind/Jamfile
Normal file
@ -0,0 +1,8 @@
|
||||
SubDir HAIKU_TOP src libs libunwind ;
|
||||
|
||||
SubInclude HAIKU_TOP src libs libunwind $(TARGET_ARCH) ;
|
||||
SubInclude HAIKU_TOP src libs libunwind mi ;
|
||||
SubInclude HAIKU_TOP src libs libunwind unwind ;
|
||||
|
||||
UseLibraryHeaders libunwind ;
|
||||
SubDirCcFlags [ FDefines HAVE_CONFIG_H=1 ] ;
|
232
src/libs/libunwind/config.h
Normal file
232
src/libs/libunwind/config.h
Normal file
@ -0,0 +1,232 @@
|
||||
/* include/config.h. Generated from config.h.in by configure. */
|
||||
/* include/config.h.in. Generated from configure.ac by autoheader. */
|
||||
|
||||
/* Block signals before mutex operations */
|
||||
#define CONFIG_BLOCK_SIGNALS /**/
|
||||
|
||||
/* Enable Debug Frame */
|
||||
/* #undef CONFIG_DEBUG_FRAME */
|
||||
|
||||
/* Support for Microsoft ABI extensions */
|
||||
/* #undef CONFIG_MSABI_SUPPORT */
|
||||
|
||||
/* Define to 1 if you want every memory access validated */
|
||||
#define CONSERVATIVE_CHECKS 1
|
||||
|
||||
/* Define to 1 if you have the <asm/ptrace_offsets.h> header file. */
|
||||
/* #undef HAVE_ASM_PTRACE_OFFSETS_H */
|
||||
|
||||
/* Define to 1 if you have the <atomic_ops.h> header file. */
|
||||
/* #undef HAVE_ATOMIC_OPS_H */
|
||||
|
||||
/* Define to 1 if you have the <byteswap.h> header file. */
|
||||
/* #undef HAVE_BYTESWAP_H */
|
||||
|
||||
/* Define to 1 if you have the declaration of `PTRACE_CONT', and to 0 if you
|
||||
don't. */
|
||||
#define HAVE_DECL_PTRACE_CONT 0
|
||||
|
||||
/* Define to 1 if you have the declaration of `PTRACE_POKEDATA', and to 0 if
|
||||
you don't. */
|
||||
#define HAVE_DECL_PTRACE_POKEDATA 0
|
||||
|
||||
/* Define to 1 if you have the declaration of `PTRACE_POKEUSER', and to 0 if
|
||||
you don't. */
|
||||
#define HAVE_DECL_PTRACE_POKEUSER 0
|
||||
|
||||
/* Define to 1 if you have the declaration of `PTRACE_SINGLESTEP', and to 0 if
|
||||
you don't. */
|
||||
#define HAVE_DECL_PTRACE_SINGLESTEP 0
|
||||
|
||||
/* Define to 1 if you have the declaration of `PTRACE_SYSCALL', and to 0 if
|
||||
you don't. */
|
||||
#define HAVE_DECL_PTRACE_SYSCALL 0
|
||||
|
||||
/* Define to 1 if you have the declaration of `PTRACE_TRACEME', and to 0 if
|
||||
you don't. */
|
||||
#define HAVE_DECL_PTRACE_TRACEME 0
|
||||
|
||||
/* Define to 1 if you have the declaration of `PT_CONTINUE', and to 0 if you
|
||||
don't. */
|
||||
#define HAVE_DECL_PT_CONTINUE 0
|
||||
|
||||
/* Define to 1 if you have the declaration of `PT_GETFPREGS', and to 0 if you
|
||||
don't. */
|
||||
#define HAVE_DECL_PT_GETFPREGS 0
|
||||
|
||||
/* Define to 1 if you have the declaration of `PT_GETREGS', and to 0 if you
|
||||
don't. */
|
||||
#define HAVE_DECL_PT_GETREGS 0
|
||||
|
||||
/* Define to 1 if you have the declaration of `PT_IO', and to 0 if you don't.
|
||||
*/
|
||||
#define HAVE_DECL_PT_IO 0
|
||||
|
||||
/* Define to 1 if you have the declaration of `PT_STEP', and to 0 if you
|
||||
don't. */
|
||||
#define HAVE_DECL_PT_STEP 0
|
||||
|
||||
/* Define to 1 if you have the declaration of `PT_SYSCALL', and to 0 if you
|
||||
don't. */
|
||||
#define HAVE_DECL_PT_SYSCALL 0
|
||||
|
||||
/* Define to 1 if you have the declaration of `PT_TRACE_ME', and to 0 if you
|
||||
don't. */
|
||||
#define HAVE_DECL_PT_TRACE_ME 0
|
||||
|
||||
/* Define to 1 if you have the <dlfcn.h> header file. */
|
||||
#define HAVE_DLFCN_H 1
|
||||
|
||||
/* Define to 1 if you have the `dlmodinfo' function. */
|
||||
/* #undef HAVE_DLMODINFO */
|
||||
|
||||
/* Define to 1 if you have the `dl_iterate_phdr' function. */
|
||||
/* #undef HAVE_DL_ITERATE_PHDR */
|
||||
|
||||
/* Define to 1 if you have the `dl_phdr_removals_counter' function. */
|
||||
/* #undef HAVE_DL_PHDR_REMOVALS_COUNTER */
|
||||
|
||||
/* Define to 1 if you have the <elf.h> header file. */
|
||||
#define HAVE_ELF_H 1
|
||||
|
||||
/* Define to 1 if you have the <endian.h> header file. */
|
||||
#define HAVE_ENDIAN_H 1
|
||||
|
||||
/* Define to 1 if you have the <execinfo.h> header file. */
|
||||
/* #undef HAVE_EXECINFO_H */
|
||||
|
||||
/* Define to 1 if you have the `getunwind' function. */
|
||||
/* #undef HAVE_GETUNWIND */
|
||||
|
||||
/* Define to 1 if you have the <ia64intrin.h> header file. */
|
||||
/* #undef HAVE_IA64INTRIN_H */
|
||||
|
||||
/* Define to 1 if you have the <inttypes.h> header file. */
|
||||
#define HAVE_INTTYPES_H 1
|
||||
|
||||
/* Define to 1 if you have the `uca' library (-luca). */
|
||||
/* #undef HAVE_LIBUCA */
|
||||
|
||||
/* Define to 1 if you have the <link.h> header file. */
|
||||
/* #undef HAVE_LINK_H */
|
||||
|
||||
/* Define if you have liblzma */
|
||||
/* #undef HAVE_LZMA */
|
||||
|
||||
/* Define to 1 if you have the <memory.h> header file. */
|
||||
#define HAVE_MEMORY_H 1
|
||||
|
||||
/* Define to 1 if you have the `mincore' function. */
|
||||
/* #undef HAVE_MINCORE */
|
||||
|
||||
/* Define to 1 if you have the <signal.h> header file. */
|
||||
#define HAVE_SIGNAL_H 1
|
||||
|
||||
/* Define to 1 if you have the <stdint.h> header file. */
|
||||
#define HAVE_STDINT_H 1
|
||||
|
||||
/* Define to 1 if you have the <stdlib.h> header file. */
|
||||
#define HAVE_STDLIB_H 1
|
||||
|
||||
/* Define to 1 if you have the <strings.h> header file. */
|
||||
#define HAVE_STRINGS_H 1
|
||||
|
||||
/* Define to 1 if you have the <string.h> header file. */
|
||||
#define HAVE_STRING_H 1
|
||||
|
||||
/* Define to 1 if `dlpi_subs' is a member of `struct dl_phdr_info'. */
|
||||
/* #undef HAVE_STRUCT_DL_PHDR_INFO_DLPI_SUBS */
|
||||
|
||||
/* Define to 1 if the system has the type `struct elf_prstatus'. */
|
||||
/* #undef HAVE_STRUCT_ELF_PRSTATUS */
|
||||
|
||||
/* Define to 1 if the system has the type `struct prstatus'. */
|
||||
/* #undef HAVE_STRUCT_PRSTATUS */
|
||||
|
||||
/* Defined if __sync atomics are available */
|
||||
/* #undef HAVE_SYNC_ATOMICS */
|
||||
|
||||
/* Define to 1 if you have the <sys/elf.h> header file. */
|
||||
/* #undef HAVE_SYS_ELF_H */
|
||||
|
||||
/* Define to 1 if you have the <sys/endian.h> header file. */
|
||||
/* #undef HAVE_SYS_ENDIAN_H */
|
||||
|
||||
/* Define to 1 if you have the <sys/link.h> header file. */
|
||||
/* #undef HAVE_SYS_LINK_H */
|
||||
|
||||
/* Define to 1 if you have the <sys/procfs.h> header file. */
|
||||
/* #undef HAVE_SYS_PROCFS_H */
|
||||
|
||||
/* Define to 1 if you have the <sys/ptrace.h> header file. */
|
||||
/* #undef HAVE_SYS_PTRACE_H */
|
||||
|
||||
/* Define to 1 if you have the <sys/stat.h> header file. */
|
||||
#define HAVE_SYS_STAT_H 1
|
||||
|
||||
/* Define to 1 if you have the <sys/types.h> header file. */
|
||||
#define HAVE_SYS_TYPES_H 1
|
||||
|
||||
/* Define to 1 if you have the <sys/uc_access.h> header file. */
|
||||
/* #undef HAVE_SYS_UC_ACCESS_H */
|
||||
|
||||
/* Define to 1 if you have the `ttrace' function. */
|
||||
/* #undef HAVE_TTRACE */
|
||||
|
||||
/* Define to 1 if you have the <unistd.h> header file. */
|
||||
#define HAVE_UNISTD_H 1
|
||||
|
||||
/* Defined if __builtin_unreachable() is available */
|
||||
/* #undef HAVE__BUILTIN_UNREACHABLE */
|
||||
|
||||
/* Defined if __builtin___clear_cache() is available */
|
||||
/* #undef HAVE__BUILTIN___CLEAR_CACHE */
|
||||
|
||||
/* Define to 1 if __thread keyword is supported by the C compiler. */
|
||||
/* #undef HAVE___THREAD */
|
||||
|
||||
/* Define to the sub-directory in which libtool stores uninstalled libraries.
|
||||
*/
|
||||
#define LT_OBJDIR ".libs/"
|
||||
|
||||
/* Name of package */
|
||||
#define PACKAGE "libunwind"
|
||||
|
||||
/* Define to the address where bug reports for this package should be sent. */
|
||||
#define PACKAGE_BUGREPORT "libunwind-devel@nongnu.org"
|
||||
|
||||
/* Define to the full name of this package. */
|
||||
#define PACKAGE_NAME "libunwind"
|
||||
|
||||
/* Define to the full name and version of this package. */
|
||||
#define PACKAGE_STRING "libunwind 1.1"
|
||||
|
||||
/* Define to the one symbol short name of this package. */
|
||||
#define PACKAGE_TARNAME "libunwind"
|
||||
|
||||
/* Define to the home page for this package. */
|
||||
#define PACKAGE_URL ""
|
||||
|
||||
/* Define to the version of this package. */
|
||||
#define PACKAGE_VERSION "1.1"
|
||||
|
||||
/* The size of `off_t', as computed by sizeof. */
|
||||
#define SIZEOF_OFF_T 8
|
||||
|
||||
/* Define to 1 if you have the ANSI C header files. */
|
||||
#define STDC_HEADERS 1
|
||||
|
||||
/* Version number of package */
|
||||
#define VERSION "1.1"
|
||||
|
||||
/* Define to empty if `const' does not conform to ANSI C. */
|
||||
/* #undef const */
|
||||
|
||||
/* Define to `__inline__' or `__inline' if that's what the C compiler
|
||||
calls it, or to nothing if 'inline' is not supported under any name. */
|
||||
#ifndef __cplusplus
|
||||
/* #undef inline */
|
||||
#endif
|
||||
|
||||
/* Define to `unsigned int' if <sys/types.h> does not define. */
|
||||
/* #undef size_t */
|
@ -42,6 +42,19 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
# define elf_w(x) _Uelf64_##x
|
||||
#endif
|
||||
|
||||
#ifdef __HAIKU__
|
||||
# define ELFMAG ELF_MAGIC
|
||||
#endif
|
||||
#ifndef SELFMAG
|
||||
# define SELFMAG 4
|
||||
#endif
|
||||
#ifndef EV_NONE
|
||||
# define EV_NONE 0
|
||||
#endif
|
||||
#ifndef EV_CURRENT
|
||||
# define EV_CURRENT 1
|
||||
#endif
|
||||
|
||||
extern int elf_w (get_proc_name) (unw_addr_space_t as,
|
||||
pid_t pid, unw_word_t ip,
|
||||
char *buf, size_t len,
|
||||
|
@ -27,7 +27,7 @@ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
|
38
src/libs/libunwind/x86_64/Jamfile
Normal file
38
src/libs/libunwind/x86_64/Jamfile
Normal file
@ -0,0 +1,38 @@
|
||||
SubDir HAIKU_TOP src libs libunwind x86_64 ;
|
||||
|
||||
UseLibraryHeaders libunwind ;
|
||||
SubDirHdrs [ FDirName $(SUBDIR) $(DOTDOT) ] ;
|
||||
SubDirCcFlags [ FDefines HAVE_CONFIG_H=1 ] ;
|
||||
|
||||
MergeObject libunwind_x86_64.o :
|
||||
Gcreate_addr_space.c
|
||||
Gget_proc_info.c
|
||||
Gget_save_loc.c
|
||||
Gglobal.c
|
||||
Ginit.c
|
||||
Ginit_local.c
|
||||
Ginit_remote.c
|
||||
Gregs.c
|
||||
Gresume.c
|
||||
Gstash_frame.c
|
||||
Gstep.c
|
||||
Gtrace.c
|
||||
Lcreate_addr_space.c
|
||||
Lget_proc_info.c
|
||||
Lget_save_loc.c
|
||||
Lglobal.c
|
||||
Linit.c
|
||||
Linit_local.c
|
||||
Linit_remote.c
|
||||
Lregs.c
|
||||
Lresume.c
|
||||
Lstash_frame.c
|
||||
Lstep.c
|
||||
Ltrace.c
|
||||
getcontext.S
|
||||
is_fpreg.c
|
||||
longjmp.S
|
||||
regname.c
|
||||
setcontext.S
|
||||
siglongjmp.S
|
||||
;
|
@ -33,7 +33,9 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
#include <libunwind-x86_64.h>
|
||||
|
||||
#include "libunwind_i.h"
|
||||
#include <sys/ucontext.h>
|
||||
#ifndef __HAIKU__
|
||||
# include <sys/ucontext.h>
|
||||
#endif
|
||||
|
||||
/* DWARF column numbers for x86_64: */
|
||||
#define RAX 0
|
||||
|
Loading…
Reference in New Issue
Block a user