From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9790 invoked by alias); 15 Mar 2013 23:44:57 -0000 Received: (qmail 9781 invoked by uid 22791); 15 Mar 2013 23:44:57 -0000 X-SWARE-Spam-Status: No, hits=-2.0 required=5.0 tests=AWL,BAYES_00,RCVD_IN_HOSTKARMA_NO X-Spam-Check-By: sourceware.org Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 15 Mar 2013 23:44:51 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id A47DA1C7F09; Fri, 15 Mar 2013 19:44:50 -0400 (EDT) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id Ei7lYtdp45hp; Fri, 15 Mar 2013 19:44:50 -0400 (EDT) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id 5F3C61C7EEC; Fri, 15 Mar 2013 19:44:50 -0400 (EDT) Received: by joel.gnat.com (Postfix, from userid 1000) id 5014DC15D6; Fri, 15 Mar 2013 16:44:48 -0700 (PDT) Date: Sat, 16 Mar 2013 02:30:00 -0000 From: Joel Brobecker To: Yao Qi Cc: Tom Tromey , gdb-patches@sourceware.org Subject: Re: [PATCH 2/5] Save trace into CTF format Message-ID: <20130315234448.GA13624@adacore.com> References: <1361931459-3953-1-git-send-email-yao@codesourcery.com> <1361931459-3953-3-git-send-email-yao@codesourcery.com> <512F38CE.5030802@codesourcery.com> <87621avsam.fsf@fleche.redhat.com> <51332381.6010101@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <51332381.6010101@codesourcery.com> User-Agent: Mutt/1.5.21 (2010-09-15) Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2013-03/txt/msg00695.txt.bz2 > 2013-03-03 Hui Zhu > Yao Qi > > * Makefile.in (REMOTE_OBS): Add ctf.o. > (SFILES): Add ctf.c. > (HFILES_NO_SRCDIR): Add ctf.h. > * ctf.c, ctf.h: New files. > * tracepoint.c : Include 'ctf.h'. > (collect_pseudocommand): Remove static. > (trace_save_command): Parse option "-ctf". > Produce different trace file writers per option. > Adjust output message. > (trace_save_tfile, trace_save_ctf): New. > * tracepoint.h (trace_save_tfile, trace_save_ctf): Declare. > * mi/mi-main.c: Include 'ctf.h'. > (mi_cmd_trace_save): Handle option '-ctf'. Call either > trace_save_tfile or trace_save_ctf. [...] > + ctf_save_fwrite_format (handler->metadata_fd, metadata_fmt, > + CTF_SAVE_MAJOR, CTF_SAVE_MINOR, > + BYTE_ORDER == LITTLE_ENDIAN ? "le" : "be"); This is causing a build failure on ppc-aix, for instance, due to: /[...]ctf.c:223:28: error: 'BYTE_ORDER' undeclared (first use in this function) /[...]ctf.c:223:28: note: each undeclared identifier is reported only once for each function it appears in /[...]ctf.c:223:42: error: 'LITTLE_ENDIAN' undeclared (first use in this function) I don't know how to fix this, because I am not sure whether host or target endianness were meant. I asssume from the code that it was host, but not sure how the host endianess would make sense... What also worries me is that I don't seem to see approval for commit for this patch. I know both of you are very careful, so perhaps in a separate message not linked to this sub-thread? -- Joel