<div dir="ltr">Hey Paul,<div><br></div><div>It looks fine.  Let me give it a build/test and then I'll check it in.</div><div><br></div><div>Thanks!  I had thought I got most of those in the llgs branch but looks like I missed a few.</div>
<div><br></div><div>-Todd</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Jul 2, 2014 at 2:09 PM, Greg Clayton <span dir="ltr"><<a href="mailto:gclayton@apple.com" target="_blank">gclayton@apple.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Looks ok to me if Todd Fiala gives the ok as well.<br>
<div><div class="h5"><br>
> On Jul 2, 2014, at 1:46 PM, Paul Osmialowski <<a href="mailto:pawelo@king.net.pl">pawelo@king.net.pl</a>> wrote:<br>
><br>
> Today this is the only problem that I'm facing trying to cross-compile lldb for AArch64 using Linaro's toolchain.<br>
> - PTRACE_GETREGS, PTRACE_SETREGS, PTRACE_GETFPREGS, PTRACE_SETFPREGS are not defined for AArch64<br>
> - 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<br>

> - NativeProcessLinux.cpp includes sys/ptrace.h<br>
> - 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.<br>

> - 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).<br>

><br>
> <a href="http://reviews.llvm.org/D4366" target="_blank">http://reviews.llvm.org/D4366</a><br>
><br>
> Files:<br>
>  source/Plugins/Process/Linux/NativeProcessLinux.cpp<br>
><br>
> Index: source/Plugins/Process/Linux/NativeProcessLinux.cpp<br>
> ===================================================================<br>
> --- source/Plugins/Process/Linux/NativeProcessLinux.cpp<br>
> +++ source/Plugins/Process/Linux/NativeProcessLinux.cpp<br>
> @@ -53,12 +53,26 @@<br>
> #define DEBUG_PTRACE_MAXBYTES 20<br>
><br>
> // Support ptrace extensions even when compiled without required kernel support<br>
> +#ifndef PT_GETREGS<br>
> #ifndef PTRACE_GETREGS<br>
> -#define PTRACE_GETREGS 12<br>
> +  #define PTRACE_GETREGS 12<br>
> #endif<br>
> +#endif<br>
> +#ifndef PT_SETREGS<br>
> #ifndef PTRACE_SETREGS<br>
>   #define PTRACE_SETREGS 13<br>
> #endif<br>
> +#endif<br>
> +#ifndef PT_GETFPREGS<br>
> +#ifndef PTRACE_GETFPREGS<br>
> +  #define PTRACE_GETFPREGS 14<br>
> +#endif<br>
> +#endif<br>
> +#ifndef PT_SETFPREGS<br>
> +#ifndef PTRACE_SETFPREGS<br>
> +  #define PTRACE_SETFPREGS 15<br>
> +#endif<br>
> +#endif<br>
> #ifndef PTRACE_GETREGSET<br>
>   #define PTRACE_GETREGSET 0x4204<br>
> #endif<br>
</div></div>> <D4366.11033.patch>_______________________________________________<br>
> lldb-commits mailing list<br>
> <a href="mailto:lldb-commits@cs.uiuc.edu">lldb-commits@cs.uiuc.edu</a><br>
> <a href="http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits</a><br>
<br>
_______________________________________________<br>
lldb-commits mailing list<br>
<a href="mailto:lldb-commits@cs.uiuc.edu">lldb-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits</a><br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr"><table cellspacing="0" cellpadding="0" style="color:rgb(136,136,136);font-family:'Times New Roman'"><tbody><tr style="color:rgb(85,85,85);font-family:sans-serif;font-size:small">
<td nowrap style="border-top-style:solid;border-top-color:rgb(213,15,37);border-top-width:2px">Todd Fiala |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(51,105,232);border-top-width:2px"> Software Engineer |</td>
<td nowrap style="border-top-style:solid;border-top-color:rgb(0,153,57);border-top-width:2px"> <a href="mailto:tfiala@google.com" style="color:rgb(17,85,204)" target="_blank"><span style="background-color:rgb(255,255,204);color:rgb(34,34,34);background-repeat:initial initial">tfiala@google.com</span></a> |</td>
<td nowrap style="border-top-style:solid;border-top-color:rgb(238,178,17);border-top-width:2px"><font color="#1155cc"> <a>650-943-3180</a></font></td></tr></tbody></table><br></div>
</div>