This patch add a "fake" attach waiting for a real implementation and
solve the build break due to the lack of this method.

It also propose a solution to the API changes in RegisterContext.

I upgraded also the the python version in the makefile. My linux
installation has python2.7 and AFAIK also the latest ubuntu
has this version of python so maybe is worth upgrading.

Patch by Marco Minutoli <mminutoli@gmail.com>

[Note: I had to hand merge in the diffs since patch thinks it is a corrupt patch.]

llvm-svn: 131313
diff --git a/lldb/source/Plugins/Process/Linux/ProcessMonitor.cpp b/lldb/source/Plugins/Process/Linux/ProcessMonitor.cpp
index 48a57a8..f482c01 100644
--- a/lldb/source/Plugins/Process/Linux/ProcessMonitor.cpp
+++ b/lldb/source/Plugins/Process/Linux/ProcessMonitor.cpp
@@ -20,6 +20,7 @@
 // C++ Includes
 // Other libraries and framework includes
 #include "lldb/Core/Error.h"
+#include "lldb/Core/RegisterValue.h"
 #include "lldb/Core/Scalar.h"
 #include "lldb/Host/Host.h"
 #include "lldb/Target/Thread.h"
@@ -221,7 +222,7 @@
 class ReadRegOperation : public Operation
 {
 public:
-    ReadRegOperation(unsigned offset, Scalar &value, bool &result)
+    ReadRegOperation(unsigned offset, RegisterValue &value, bool &result)
         : m_offset(offset), m_value(value), m_result(result)
         { }
 
@@ -229,7 +230,7 @@
 
 private:
     unsigned m_offset;
-    Scalar &m_value;
+    RegisterValue &m_value;
     bool &m_result;
 };
 
@@ -257,7 +258,7 @@
 class WriteRegOperation : public Operation
 {
 public:
-    WriteRegOperation(unsigned offset, const Scalar &value, bool &result)
+    WriteRegOperation(unsigned offset, const RegisterValue &value, bool &result)
         : m_offset(offset), m_value(value), m_result(result)
         { }
 
@@ -265,7 +266,7 @@
 
 private:
     unsigned m_offset;
-    const Scalar &m_value;
+    const RegisterValue &m_value;
     bool &m_result;
 };
 
@@ -274,7 +275,7 @@
 {
     lldb::pid_t pid = monitor->GetPID();
 
-    if (ptrace(PTRACE_POKEUSER, pid, m_offset, m_value.ULong()))
+    if (ptrace(PTRACE_POKEUSER, pid, m_offset, m_value.GetAsUInt64()))
         m_result = false;
     else
         m_result = true;
@@ -1097,7 +1098,7 @@
 }
 
 bool
-ProcessMonitor::ReadRegisterValue(unsigned offset, Scalar &value)
+ProcessMonitor::ReadRegisterValue(unsigned offset, RegisterValue &value)
 {
     bool result;
     ReadRegOperation op(offset, value, result);
@@ -1106,7 +1107,7 @@
 }
 
 bool
-ProcessMonitor::WriteRegisterValue(unsigned offset, const Scalar &value)
+ProcessMonitor::WriteRegisterValue(unsigned offset, const RegisterValue &value)
 {
     bool result;
     WriteRegOperation op(offset, value, result);