regarding kgdb in ppc
Anumolu Sudheer
urwithsudheer at gmail.com
Wed Nov 29 03:20:21 EST 2006
Hello All
I am in process of learning kgdb and facing some problem with gdbserver. I
am not able to "configure and make" the gdbserver . Sorry fot the long
mail.
Did anyone tried to compile the KGDB with this powerpc-eabi ?? Please
help me in solving this.
Setup datails are below..
Host: x86, RHEL-2.6.9-34.EL
Target Linux- 2.6.16.2
Target Processor: AMCC440SPe
The kgdb version : linux-2.6.15.5-kgdb-2.4
GDB version gdb-6.4-kgdb-2.4.tar.bz2
CrossCompiler - powerpc-eabi
I applied the patch to the kernel and cross compiled it.(modified to solve
the compilation errors as is not supported readymade).
I used the steps given in "http://www.kegel.com/linux/gdbserver.txt " to
build the gdb.
I compiled the gdb for host with following commands
#ls
gdb-6.4 gdb-6.4-kgdb-2.4.tar.bz2
#mkdir ppc440
#cd ppc440
#/bin/sh ../gdb-6.4/configure --target=powerpc-eabi
--with-solib-absolute-prefix=/opt/ppc440
#make
#cd ..
For gdbserver, if i give the "--target=powerpc-eabi" to "configure"
script, it says the target
is not supported by gdbserver and if i give "--target=powerpc-linux",
it doesnt show any error
but its output doesn't look fine . But when i do make. i get many
errors saying many files
are not found. (Adding few required header files didnt help.)
I cross compiled the gdbserver with following commands:
[root at localhost gdb]# mkdir cross-ppc440
[root at localhost gdb]# ls
cross-ppc440 gdb-6.4 gdb-6.4-kgdb-2.4.tar.bz2 ppc440
[root at localhost
gdb]# cd cross-ppc440/
[root at localhost cross-ppc440]#
[root at localhost cross-ppc440]# export CC=/usr/local/powerpc-eabi/bin/
[root at localhost cross-ppc440]# export CFLAGS="-mcpu=405 -D__PPC405__ -msim"
[root at localhost cross-ppc440]# export ac_cv_func_mmap_fixed_mapped=yes
[root at localhost cross-ppc440]# /bin/sh
../gdb-6.4/gdb/gdbserver/configure --target=powerpc-eabi --host=i386
configure: WARNING: If you wanted to set the --build type, don't use --host.
If a cross compiler is detected then cross compile mode will be used.
checking for i386-gcc... /usr/local/powerpc-eabi/bin /powerpc-eabi-gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... yes
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether /usr/local/powerpc-eabi/bin/powerpc-eabi-gcc accepts -g...
yes
checking for /usr/local/powerpc-eabi/bin/powerpc-eabi-gcc option to accept
ANSI C... none needed
checking build system type... i686-pc-linux-gnulibc1
checking host system type... i386-pc-none
checking target system type... powerpc-unknown-eabi
checking for a BSD-compatible install... /usr/bin/install -c
checking how to run the C preprocessor...
/usr/local/powerpc-eabi/bin/powerpc-eabi-gcc -E
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... no
checking for strings.h... no
checking for inttypes.h... no
checking for stdint.h... no
checking for unistd.h... yes
checking sgtty.h usability... no
checking sgtty.h presence... no
checking for sgtty.h... no
checking termio.h usability... no
checking termio.h presence... no
checking for termio.h... no
checking termios.h usability... no
checking termios.h presence... no
checking for termios.h... no
checking sys/reg.h usability... no
checking sys/reg.h presence... no
checking for sys/reg.h... no
checking for string.h... (cached) yes
checking proc_service.h usability... no
checking proc_service.h presence... no
checking for proc_service.h... no
checking sys/procfs.h usability... no
checking sys/procfs.h presence... no
checking for sys/procfs.h... no
checking thread_db.h usability... no
checking thread_db.h presence... no
checking for thread_db.h... no
checking linux/elf.h usability... no
checking linux/elf.h presence... no
checking for linux/elf.h... no
checking for stdlib.h... (cached) yes
checking for unistd.h... (cached) yes
checking whether strerror is declared... yes
checking for socklen_t... no
Error: target not supported by gdbserver.
[root at localhost cross-ppc440]#
[root at localhost cross-ppc440]# /bin/sh ../gdb-6.4/gdb/gdbserver/configure
--target=powerpc-linux --host=i386
configure: WARNING: If you wanted to set the --build type, don't use --host.
If a cross compiler is detected then cross compile mode will be used.
checking for i386-gcc... /usr/local/powerpc-eabi/bin/powerpc-eabi-gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... yes
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether /usr/local/powerpc-eabi/bin/powerpc-eabi-gcc accepts -g...
yes
checking for /usr/local/powerpc-eabi/bin/powerpc-eabi-gcc option to accept
ANSI C... none needed
checking build system type... i686-pc-linux-gnulibc1
checking host system type... i386-pc-none
checking target system type... powerpc-unknown-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking how to run the C preprocessor...
/usr/local/powerpc-eabi/bin/powerpc-eabi-gcc -E
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... no
checking for strings.h... no
checking for inttypes.h... no
checking for stdint.h... no
checking for unistd.h... yes
checking sgtty.h usability... no
checking sgtty.h presence... no
checking for sgtty.h... no
checking termio.h usability... no
checking termio.h presence... no
checking for termio.h... no
checking termios.h usability... no
checking termios.h presence... no
checking for termios.h... no
checking sys/reg.h usability... no
checking sys/reg.h presence... no
checking for sys/reg.h... no
checking for string.h... (cached) yes
checking proc_service.h usability... no
checking proc_service.h presence... no
checking for proc_service.h... no
checking sys/procfs.h usability... no
checking sys/procfs.h presence... no
checking for sys/procfs.h... no
checking thread_db.h usability... no
checking thread_db.h presence... no
checking for thread_db.h... no
checking linux/elf.h usability... no
checking linux/elf.h presence... no
checking for linux/elf.h... no
checking for stdlib.h... (cached) yes
checking for unistd.h... (cached) yes
checking whether strerror is declared... yes
checking for socklen_t... no
checking for PTRACE_GETREGS... no
checking for PTRACE_GETFPXREGS... no
checking for libthread_db... no
configure: WARNING: Could not find libthread_db.
configure: WARNING: Disabling thread support in gdbserver.
configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h
config.status: executing default commands
[root at localhost cross-ppc440]# ls
config.h config.log config.status Makefile
[root at localhost cross-ppc440]#
[root at localhost cross-ppc440]#
Please let me know if any details required.
Thanks in advance
Sudheer
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://ozlabs.org/pipermail/linuxppc-embedded/attachments/20061128/9cf31f72/attachment.htm
More information about the Linuxppc-embedded
mailing list