This is the mail archive of the gdb-prs@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

gdb/414: Unable to build GDB 5.1.1 for PowerPC on Linux/Intex



>Number:         414
>Category:       gdb
>Synopsis:       Unable to build GDB 5.1.1 for PowerPC on Linux/Intex
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Mar 12 09:48:01 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     Bill Yoder
>Release:        gdb-5.1.tar.gz (from http://www.gnu.org/software/gdb/gdb.html)
>Organization:
>Environment:
'uname -a' sez:
Linux footpad.cs.utexas.edu 2.2.19 #1 SMP Thu Mar 29 11:13:53 CST 2001 i686 unknown
(Please see attached file for other environmental details.)
>Description:
I'm unable to build the GNU 5.1.1 debugger for the PowerPC on a 
Debian Linux/Intel platform.  

Maybe this is not a bug but a simple limitation of cross-platform
support for GDB.

Please see the attached file for more information.
>How-To-Repeat:
It's pretty easy once you have installed the release on
a Linux/Intel box and configured GDB for a ppc build.  

A simple 'make' will do the trick.
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: text/plain; name="gdbbugsubmit.txt"
Content-Disposition: inline; filename="gdbbugsubmit.txt"

I'm unable to build the GNU 5.1.1 debugger for the PowerPC on a 
Debian Linux/Intel platform.  

Maybe this is not a bug but a simple limitation of cross-platform
support for GDB.

My development environment is set up as follows:

    Tar package of GDB 5.1, downloaded from 
    http://www.gnu.org/software/gdb/gdb.html
                |
                |
                |
                v
    Building on Debian Linux 2.2.19 with the 
    GNU 3.0.3 C Compiler (gcc)
                |
                |
                |
                v
    Running on an Intel 800Mhz 
    Pentium III with 256KB cache, etc.

The problem occurs after the system is set up to build the Power PC version
of the debugger and during the "make" of gdb:

% cd /projects/trips/arch/projects/gdb/gdb-5.1
% ./configure ppc-elf-aix

     .......... lots of output, all successful .......

% cd /projects/trips/arch/projects/gdb/gdb-5.1/gdb 
% make
     ........... lots of output .........
     ........... and then ...............

gcc -c -g -O2    -I. -I. -I./config -DHAVE_CONFIG_H -I./../include/opcode -I./../readline/.. -I../bfd -I./../bfd  -I./../include -I../intl -I./../intl  -DMI_OUT=1 -DUI_OUT=1 -Wimplicit -Wreturn-type -Wcomment -Wtrigraphs -Wformat -Wparentheses -Wpointer-arith -Wuninitialized  rs6000-nat.c
rs6000-nat.c:49:22: sys/core.h: No such file or directory
rs6000-nat.c:52:21: sys/ldr.h: No such file or directory
rs6000-nat.c:53:27: sys/systemcfg.h: No such file or directory
rs6000-nat.c:80: field `r64' has incomplete type
rs6000-nat.c:82: field `r32' has incomplete type
rs6000-nat.c:83: confused by earlier errors, bailing out
make: *** [rs6000-nat.o] Error 1

On the other hand, when I build the debugger for the Intel platform, then
everything works fine:

% cd /projects/trips/arch/projects/gdb/gdb-5.1 
% make clean
% ./configure i686-pc-linux
     .......... lots of output .......

% make
     ........... lots of output .........
     ........... and all is well--no errors .........

Finally, when I try to build the Power PC debugger to run on Linux,
this situation occurs:

% cd /projects/trips/arch/projects/gdb/gdb-5.1 
% make clean
% ./configure ppc-elf-linux
     .......... lots of output .......

% make
     ........... lots of output .........
     ........... and then .........

gcc -c -g -O2    -I. -I. -I./config -DHAVE_CONFIG_H -I./../include/opcode -I./../readline/.. -I../bfd -I./../bfd  -I./../include -I../intl -I./../intl  -DMI_OUT=1 -DUI_OUT=1 -Wimplicit -Wreturn-type -Wcomment -Wtrigraphs -Wformat -Wparentheses -Wpointer-arith -Wuninitialized  ppc-linux-nat.c
ppc-linux-nat.c:46: `PT_R0' undeclared here (not in a function)
ppc-linux-nat.c:46: initializer element is not constant
ppc-linux-nat.c:46: (near initialization for `regmap[0]')
ppc-linux-nat.c:46: `PT_R1' undeclared here (not in a function)
ppc-linux-nat.c:51: (near initialization for `regmap[40]')
ppc-linux-nat.c:53: initializer element is not constant

............. (you get the idea)...................

ppc-linux-nat.c:54: initializer element is not constant
ppc-linux-nat.c:54: (near initialization for `regmap[70]')
ppc-linux-nat.c: In function `fill_fpregset':
ppc-linux-nat.c:124: invalid operands to binary +
ppc-linux-nat.c:116: warning: `to' might be used uninitialized in this function
make: *** [ppc-linux-nat.o] Error 1

Perhaps this is my mistake.  Perhaps IBM/GNU doesn't support the GNU debugger
in a cross-development environment.   Perhaps it's only possible to build
the PowerPC debugger on an IBM PowerPC platform?   I thought it would work,
because I had success last week building the GNU Assembler and Linker
for PowerPC on the Intel platform.

Anyway, thanks for your help.

Bill Yoder

Department of Computer Sciences
Austin, TX 78712-1188
512-232-7464
http://www.cs.utexas.edu/users/byoder


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]