From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6342 invoked by alias); 11 Aug 2009 05:06:57 -0000 Received: (qmail 6063 invoked by uid 22791); 11 Aug 2009 05:06:55 -0000 X-SWARE-Spam-Status: No, hits=-0.5 required=5.0 tests=AWL,BAYES_50,SARE_MSGID_LONG40,SPF_PASS X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (216.239.33.17) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 11 Aug 2009 05:06:49 +0000 Received: from spaceape7.eur.corp.google.com (spaceape7.eur.corp.google.com [172.28.16.141]) by smtp-out.google.com with ESMTP id n7B56jXR029120 for ; Tue, 11 Aug 2009 06:06:46 +0100 Received: from qyk4 (qyk4.prod.google.com [10.241.83.132]) by spaceape7.eur.corp.google.com with ESMTP id n7B56heC006886 for ; Mon, 10 Aug 2009 22:06:43 -0700 Received: by qyk4 with SMTP id 4so2918975qyk.4 for ; Mon, 10 Aug 2009 22:06:42 -0700 (PDT) MIME-Version: 1.0 Received: by 10.224.74.8 with SMTP id s8mr3928691qaj.12.1249967202793; Mon, 10 Aug 2009 22:06:42 -0700 (PDT) In-Reply-To: <8ac60eac0908101320k6cc20e9age92656cba254a5d4@mail.gmail.com> References: <4A5F8D9E.1060307@Sun.COM> <200908041804.30240.thiago.bauermann@gmail.com> <20090805044504.GJ4370@adacore.com> <4A7ABAF0.7010004@Sun.COM> <4A7FFAB3.7080903@Sun.COM> <8ac60eac0908101320k6cc20e9age92656cba254a5d4@mail.gmail.com> Date: Tue, 11 Aug 2009 05:06:00 -0000 Message-ID: <8ac60eac0908102206l49972a96pfc306be0cf15d34b@mail.gmail.com> Subject: Re: status of Darwin support From: Paul Pluzhnikov To: Tom Tromey Cc: Christian Thalinger , Tristan Gingold , Joel Brobecker , Thiago Jung Bauermann , gdb@sourceware.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-System-Of-Record: true X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2009-08/txt/msg00060.txt.bz2 On Mon, Aug 10, 2009 at 1:20 PM, Paul Pluzhnikov wrote: > I will try to reproduce the Darwin failure, but I won't get to my Mac > until later tonight. I couldn't get GDB to even run the program: ../gdb ../a.out GNU gdb (GDB) 6.8.50.20090811-cvs ... (gdb) r Starting program: /Users/ppluzhnikov/gdb-cvs/build/gdb/a.out Unable to find Mach task port for process-id 98005: (os/kern) failure (0x5). (please check gdb is setgid procmod) (gdb) q This even if I make GDB suid-root (I also tried setgid procmod): ls -l ../gdb -rwsr-sr-x 1 root wheel 4075816 Aug 10 20:21 ../gdb Error 5 is EIO in /usr/include/sys/errno.h The stack trace for failure (/usr/bin/gdb *is* working): #0 error (string=0x22127c "Unable to find Mach task port for process-id %d: %s (0x%lx).\n (please check gdb is setgid procmod)") at ../../src/gdb/utils.c:814 #1 0x000125d6 in darwin_attach_pid (inf=0x63e3f0) at ../../src/gdb/darwin-nat.c:1325 #2 0x0001623e in darwin_ptrace_him (pid=97994) at ../../src/gdb/darwin-nat.c:1454 #3 0x00010204 in fork_inferior (exec_file_arg=0x63dc20 "/Users/ppluzhnikov/gdb-cvs/build/gdb/a.out", allargs=0x63e0c0 "", env=0x61a0f0, traceme_fun=0x12830 , init_trace_fun=0x16220 , pre_trace_fun=0x12910 , shell_file_arg=0x0) at ../../src/gdb/fork-child.c:415 #4 0x000129cc in darwin_create_inferior (ops=0x604470, exec_file=0x22127c "Unable to find Mach task port for process-id %d: %s (0x%lx).\n (please check gdb is setgid procmod)", allargs=0x22127c "Unable to find Mach task port for process-id %d: %s (0x%lx).\n (please check gdb is setgid procmod)", env=0x22127c, from_tty=1) at ../../src/gdb/darwin-nat.c:1470 #5 0x000fa86c in target_create_inferior (exec_file=0x63dc20 "/Users/ppluzhnikov/gdb-cvs/build/gdb/a.out", args=0x63e0c0 "", env=0x61a0f0, from_tty=1) at ../../src/gdb/target.c:429 #6 0x000c083b in run_command_1 (args=0x0, from_tty=6545600, tbreak_at_main=) at ../../src/gdb/infcmd.c:557 #7 0x0017e695 in execute_command (p=0x600311 "", from_tty=1) at ../../src/gdb/top.c:442 #8 0x000e139e in command_handler (command=0x600310 "") at ../../src/gdb/event-top.c:511 #9 0x000e16f2 in command_line_handler (rl=0x63de40 "??c") at ../../src/gdb/event-top.c:735 #10 0x001b33bd in rl_callback_read_char () at ../../src/readline/callback.c:205 #11 0x000e0c62 in rl_callback_read_char_wrapper (client_data=0x0) at ../../src/gdb/event-top.c:178 #12 0x000dfe25 in handle_file_event (data={ptr = 0x0, integer = 0}) at ../../src/gdb/event-loop.c:812 #13 0x000dfa25 in process_event () at ../../src/gdb/event-loop.c:394 #14 0x000e09bb in gdb_do_one_event (data=0x0) at ../../src/gdb/event-loop.c:459 #15 0x000d9452 in catch_errors (func=0xe0750 , func_args=0x0, errstring=0x26fa00 "", mask=2232956) at ../../src/gdb/exceptions.c:510 #16 0x00049452 in tui_command_loop (data=0x0) at ../../src/gdb/tui/tui-interp.c:153 #17 0x000d9e0c in current_interp_command_loop () at ../../src/gdb/interps.c:291 #18 0x000da592 in captured_command_loop (data=0x0) at ../../src/gdb/main.c:226 #19 0x000d9452 in catch_errors (func=0xda580 , func_args=0x0, errstring=0x26fa00 "", mask=2232956) at ../../src/gdb/exceptions.c:510 #20 0x000dae0f in captured_main (data=0xbffff8a0) at ../../src/gdb/main.c:902 #21 0x000d9452 in catch_errors (func=0xda5d0 , func_args=0xbffff8a0, errstring=0x26fa00 "", mask=2232956) at ../../src/gdb/exceptions.c:510 #22 0x000db8bf in gdb_main (args=0x0) at ../../src/gdb/main.c:911 #23 0x000018b4 in main (argc=2232956, argv=0x22127c) at ../../src/gdb/gdb.c:33 Clues? (I don't do any development on Mac, so I am completely clueless.) Thanks, -- Paul Pluzhnikov