Thanks. I tried this on FreeBSD 4.2-Release (because I do not have a
stable or current), but I failed:

# make

Warning: Object directory not changed from original
/usr/src/gnu/usr.bin/binutils/gdb


cc: ../libbfd/libbfd.a: No such file or directory
cc: ../libopcodes/libopcodes.a: No such file or directory
cc: ../libiberty/libiberty.a: No such file or directory
*** Error code 1

Stop in /usr/src/gnu/usr.bin/binutils/gdb.

What should I do?

-Zhihui

On Wed, 6 Dec 2000, Brian Dean wrote:

> Index: freebsd-nat.c
> ===================================================================
> RCS file: 
>/usr00/FreeBSD/mirror/ncvs/src/gnu/usr.bin/binutils/gdb/i386/freebsd-nat.c,v
> retrieving revision 1.21.4.2
> diff -u -r1.21.4.2 freebsd-nat.c
> --- freebsd-nat.c     2000/08/22 12:28:19     1.21.4.2
> +++ freebsd-nat.c     2000/12/07 00:31:52
> @@ -478,14 +478,16 @@
>  {
>    struct dbreg dbr;
>    extern int inferior_pid;
> -  
> +
>    if (inferior_pid != 0 && core_bfd == NULL) 
>      {
>        int pid = inferior_pid & ((1 << 17) - 1);      /* XXX extract pid from tid */
> -  
> +
>        if (ptrace(PT_GETDBREGS, pid, (caddr_t)&dbr, 0) == -1)
>       {
> -       perror("ptrace(PT_GETDBREGS) failed");
> +          /* don't complain on ESRCH, assume we are debugging a remote target */
> +          if (errno != ESRCH) 
> +              perror("ptrace(PT_GETDBREGS) failed");
>         return 0;
>       }
>  #if WATCHPOINT_DEBUG > 1
> @@ -520,7 +522,10 @@
>  
>        if (ptrace(PT_GETDBREGS, pid, (caddr_t)&dbr, 0) == -1)
>       {
> -       perror("ptrace(PT_GETDBREGS) failed");
> +          /* don't complain on ESRCH, assume we are debugging a remote target */
> +          if (errno != ESRCH) 
> +              perror("ptrace(PT_GETDBREGS) failed");
> +              
>         return 0;
>       }
>  
> @@ -615,7 +620,9 @@
>    
>        if (ptrace(PT_GETDBREGS, pid, (caddr_t)&dbr, 0) == -1)
>       {
> -       perror("ptrace(PT_GETDBREGS) failed");
> +          /* don't complain on ESRCH, assume we are debugging a remote target */
> +          if (errno != ESRCH) 
> +              perror("ptrace(PT_GETDBREGS) failed");
>         return 0;
>       }
>  



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message

Reply via email to