llvm-project/lldb/source/Plugins/Process/Linux
Todd Fiala dda6194399 lldb - problem with some PTRACE_* constants in NativeProcessLinux.cpp file
See http://reviews.llvm.org/D4366 for details.

Change by Paul Paul Osmialowski

Today this is the only problem that I'm facing trying to cross-compile lldb for AArch64 using Linaro's toolchain.

PTRACE_GETREGS, PTRACE_SETREGS, PTRACE_GETFPREGS, PTRACE_SETFPREGS are not defined for AArch64
These things can be defined different ways for other architectures, e.g. for x86_64 Linux, asm/ptrace-abi.h defines them as preprocessor constants while sys/ptrace.h defines them in enum along with corresponding PT_* preprocessor constants
NativeProcessLinux.cpp includes sys/ptrace.h
To avoid accidental redefinition of enums with preprocessor constants, I'm proposing this patch which first checks for PT_* preprocessor constants then checks for PTRACE_* constants then when it still can not find them, it defines preprocessor constants.
Similar approach was already used for PTRACE_GETREGSET and PTRACE_SETREGSET constants; in this case however it was easier, since enum values in sys/ptrace.h and preprocessor constants shared all exactly the same names (e.g. there's no additional PT_GETREGSET name defined).

llvm-svn: 212225
2014-07-02 21:34:04 +00:00
..
CMakeLists.txt Fixup Windows build breaks for the llgs upstream. 2014-06-30 23:51:35 +00:00
LinuxThread.cpp FreeBSD hardware watchpoint implementation 2014-02-19 18:34:06 +00:00
LinuxThread.h FreeBSD hardware watchpoint implementation 2014-02-19 18:34:06 +00:00
Makefile This patch combines common code from Linux and FreeBSD into 2012-01-05 19:17:38 +00:00
NativeProcessLinux.cpp lldb - problem with some PTRACE_* constants in NativeProcessLinux.cpp file 2014-07-02 21:34:04 +00:00
NativeProcessLinux.h Add lldb-gdbserver support for Linux x86_64. 2014-06-30 21:05:18 +00:00
NativeRegisterContextLinux_x86_64.cpp Fixup Windows build breaks for the llgs upstream. 2014-06-30 23:51:35 +00:00
NativeRegisterContextLinux_x86_64.h Fixup Windows build breaks for the llgs upstream. 2014-06-30 23:51:35 +00:00
NativeThreadLinux.cpp Fixup Windows build breaks for the llgs upstream. 2014-06-30 23:51:35 +00:00
NativeThreadLinux.h Add lldb-gdbserver support for Linux x86_64. 2014-06-30 21:05:18 +00:00
ProcFileReader.cpp Factored out Linux proc file reading into separate class. 2014-06-30 04:14:13 +00:00
ProcFileReader.h Factored out Linux proc file reading into separate class. 2014-06-30 04:14:13 +00:00
ProcessLinux.cpp Fix Linux by partially reverting 196787 2013-12-11 20:43:27 +00:00
ProcessLinux.h Add lldb-gdbserver support for Linux x86_64. 2014-06-30 21:05:18 +00:00
ProcessMonitor.cpp Use native ::pid_t in Linux ProcessMonitor (local debugging). 2014-07-01 16:30:53 +00:00
ProcessMonitor.h Implement ProcessMonitor::Kill for Linux 2014-04-01 18:14:06 +00:00