gentoo linux-headers package no longer installs asm/user.h, asm/page.h and i386-asm/user.h. mono-debugger requires 3 struct definitions in i386-asm/user.h which requires the other two header files. Reproducible: Always Steps to Reproduce: 1. emerge mono-debugger Actual Results: i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../.. -D_REENTRANT -pthread -I/usr/lib/pkgconfig/../../include/mono-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -D_GNU_SOURCE -MT library.lo -MD -MP -MF .deps/library.Tpo -c library.c -fPIC -DPIC -o .libs/library.o i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../.. -D_REENTRANT -pthread -I/usr/lib/pkgconfig/../../include/mono-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -D_GNU_SOURCE -MT library.lo -MD -MP -MF .deps/library.Tpo -c library.c -o library.o >/dev/null 2>&1 if /bin/sh ../../libtool --tag=CC --mode=compile i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../.. -D_REENTRANT -pthread -I/usr/lib/pkgconfig/../../include/mono-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -D_GNU_SOURCE -MT x86-ptrace.lo -MD -MP -MF ".deps/x86-ptrace.Tpo" -c -o x86-ptrace.lo x86-ptrace.c; \ then mv -f ".deps/x86-ptrace.Tpo" ".deps/x86-ptrace.Plo"; else rm -f ".deps/x86-ptrace.Tpo"; exit 1; fi i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../.. -D_REENTRANT -pthread -I/usr/lib/pkgconfig/../../include/mono-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -D_GNU_SOURCE -MT x86-ptrace.lo -MD -MP -MF .deps/x86-ptrace.Tpo -c x86-ptrace.c -fPIC -DPIC -o .libs/x86-ptrace.o In file included from x86-arch.h:41, from x86-linux-ptrace.h:4, from x86-ptrace.c:36: i386-arch.h:10:22: error: asm/user.h: No such file or directory In file included from x86-ptrace.c:36: x86-linux-ptrace.h:7: warning: 'struct user_regs_struct' declared inside parameter list x86-linux-ptrace.h:7: warning: its scope is only this definition or declaration, which is probably not what you want x86-linux-ptrace.h:10: warning: 'struct user_regs_struct' declared inside parameter list x86-linux-ptrace.h:13: warning: 'struct user_i387_struct' declared inside parameter list x86-linux-ptrace.h:16: warning: 'struct user_i387_struct' declared inside parameter list In file included from x86-linux-ptrace.h:39, from x86-ptrace.c:36: x86-ptrace.h:32: warning: 'struct user_regs_struct' declared inside parameter list x86-ptrace.h:32: error: conflicting types for '_server_ptrace_get_registers' x86-linux-ptrace.h:7: error: previous declaration of '_server_ptrace_get_registers' was here x86-ptrace.h:33: warning: 'struct user_regs_struct' declared inside parameter list x86-ptrace.h:33: error: conflicting types for '_server_ptrace_set_registers' x86-linux-ptrace.h:10: error: previous declaration of '_server_ptrace_set_registers' was here x86-ptrace.h:34: warning: 'struct user_i387_struct' declared inside parameter list x86-ptrace.h:34: error: conflicting types for '_server_ptrace_get_fp_registers' x86-linux-ptrace.h:13: error: previous declaration of '_server_ptrace_get_fp_registers' was here x86-ptrace.h:35: warning: 'struct user_i387_struct' declared inside parameter list x86-ptrace.h:35: error: conflicting types for '_server_ptrace_set_fp_registers' x86-linux-ptrace.h:16: error: previous declaration of '_server_ptrace_set_fp_registers' was here In file included from x86-ptrace.c:497: x86-linux-ptrace.c:2: warning: 'struct user_regs_struct' declared inside parameter list x86-linux-ptrace.c:3: error: conflicting types for '_server_ptrace_get_registers' x86-ptrace.h:32: error: previous declaration of '_server_ptrace_get_registers' was here x86-linux-ptrace.c:17: warning: 'struct user_regs_struct' declared inside parameter list x86-linux-ptrace.c:18: error: conflicting types for '_server_ptrace_set_registers' x86-ptrace.h:33: error: previous declaration of '_server_ptrace_set_registers' was here x86-linux-ptrace.c:32: warning: 'struct user_i387_struct' declared inside parameter list x86-linux-ptrace.c:33: error: conflicting types for '_server_ptrace_get_fp_registers' x86-ptrace.h:34: error: previous declaration of '_server_ptrace_get_fp_registers' was here x86-linux-ptrace.c:47: warning: 'struct user_i387_struct' declared inside parameter list x86-linux-ptrace.c:48: error: conflicting types for '_server_ptrace_set_fp_registers' x86-ptrace.h:35: error: previous declaration of '_server_ptrace_set_fp_registers' was here x86-linux-ptrace.c: In function '_server_ptrace_set_dr': x86-linux-ptrace.c:93: error: invalid use of undefined type 'struct user' x86-linux-ptrace.c: In function '_server_ptrace_get_dr': x86-linux-ptrace.c:109: error: invalid use of undefined type 'struct user' x86-linux-ptrace.c: In function 'server_ptrace_get_application': x86-linux-ptrace.c:440: warning: assignment from incompatible pointer type In file included from x86-ptrace.c:505: i386-arch.c: At top level: i386-arch.c:20: error: field 'current_regs' has incomplete type i386-arch.c:21: error: field 'current_fpregs' has incomplete type i386-arch.c: In function 'x86_arch_child_stopped': i386-arch.c:445: warning: passing argument 2 of '_server_ptrace_set_registers' from incompatible pointer type i386-arch.c:448: warning: passing argument 2 of '_server_ptrace_set_fp_registers' from incompatible pointer type i386-arch.c:496: warning: passing argument 2 of '_server_ptrace_set_registers' from incompatible pointer type i386-arch.c:499: warning: passing argument 2 of '_server_ptrace_set_fp_registers' from incompatible pointer type i386-arch.c: In function 'server_ptrace_abort_invoke': i386-arch.c:939: warning: passing argument 2 of '_server_ptrace_set_registers' from incompatible pointer type i386-arch.c:942: warning: passing argument 2 of '_server_ptrace_set_fp_registers' from incompatible pointer type x86-ptrace.c: At top level: x86-ptrace.c:535: warning: initialization from incompatible pointer type make[3]: *** [x86-ptrace.lo] Error 1 make[3]: Leaving directory `/var/tmp/portage/dev-util/mono-debugger-0.50/work/mono-debugger-0.50/backend/server' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/var/tmp/portage/dev-util/mono-debugger-0.50/work/mono-debugger-0.50/backend' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/dev-util/mono-debugger-0.50/work/mono-debugger-0.50' make: *** [all] Error 2 !!! ERROR: dev-util/mono-debugger-0.50 failed. Call stack: ebuild.sh, line 1637: Called dyn_compile ebuild.sh, line 983: Called qa_call 'src_compile' ebuild.sh, line 44: Called src_compile ebuild.sh, line 657: Called die !!! emake failed !!! If you need support, post the topmost build error, and the call stack if relevant. !!! A complete build log is located at '/var/tmp/portage/dev-util/mono-debugger-0.50/temp/build.log'.
Kindly review http://bugs.gentoo.org/page.cgi?id=fields.html#bug_severity
Created attachment 123162 [details, diff] patch to add struct definitions to backend/server/i386-arch.h adds missing struct definitions from i386-asm/user.h
(In reply to comment #1) > Kindly review http://bugs.gentoo.org/page.cgi?id=fields.html#bug_severity > Sorry about that. Guess it should be normal severity...
I suppose you're using ~keyworded linux-headers (>=2.6.19)? With stable 2.6.17 this is bug does not occur
(In reply to comment #4) > I suppose you're using ~keyworded linux-headers (>=2.6.19)? With stable 2.6.17 > this is bug does not occur > Yes, ~x86, which is how mono-debugger-0.50 is keyworded. linux-headers-2.6.21 kernel 2.6.21-suspend2-r6
Agreed, but using ~keyworded mono-debugger does not imply using ~keyworded linux-headers (or any other dependencies). Your patch looks good but nevertheless you should add some conditional code to it (e.g. based on '#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,19)')
Created attachment 123173 [details, diff] cleaned up i386-arch.h patch Cleaned up the original patch. Added code for conditional compilation on machines with linux-headers >= 2.6.19. Earlier versions will still #include <asm/user.h>.
Fixed in CVS, thanks
(In reply to comment #8) > Fixed in CVS, thanks > My pleasure.