I'm in the process of porting some applications from Maverick 10.10 to Precise 12.04. Some of the system headers do not seem to be in the same place. This is giving me some headaches since it doesn't seem to matter that i add the include paths.
In particular, on Maverick, there was a file in /usr/include/sys/ucontext.h, and this file defines the constant REG_EIP. Now, on Precise, this file has moved to /usr/include/x86_64-linux-gnu/sys/ucontext.h, but g++ 4.6 nor 4.7 have that include path:
`gcc -print-prog-name=cc1plus` -v
ignoring nonexistent directory "/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../x86_64-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
/usr/include/c++/4.6
/usr/include/c++/4.6/x86_64-linux-gnu
/usr/include/c++/4.6/backward
/usr/lib/gcc/x86_64-linux-gnu/4.6/include
/usr/local/include
/usr/lib/gcc/x86_64-linux-gnu/4.6/include-fixed
/usr/include
End of search list.
the consequence of this is that when including #include <ucontext.h>, REG_EIP is not defined
I've tried adding #include <sys/ucontext.h> but i still get the error:
error: 'REG_EIP' was not declared in this scope
Any idea how to fix this?
