From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22840 invoked by alias); 30 Aug 2004 12:08:55 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 22833 invoked from network); 30 Aug 2004 12:08:54 -0000 Received: from unknown (HELO psmtp.com) (12.158.35.212) by sourceware.org with SMTP; 30 Aug 2004 12:08:54 -0000 Received: from source ([192.150.22.7]) by exprod6ob2.obsmtp.com ([12.158.35.250]) with SMTP; Mon, 30 Aug 2004 05:08:52 PDT Received: from inner-relay-3.corp.adobe.com (inner-relay-3 [153.32.251.51]) by smtp-relay-7.sea.adobe.com (8.12.10/8.12.10) with ESMTP id i7UC8pNf021029; Mon, 30 Aug 2004 05:08:51 -0700 (PDT) Received: from iplan-mn (iplan-mn.corp.adobe.com [130.248.25.5]) by inner-relay-3.corp.adobe.com (8.12.9/8.12.9) with ESMTP id i7UC8okq011306; Mon, 30 Aug 2004 05:08:51 -0700 (PDT) Received: from mn-eljay-a51m.adobe.com ([130.248.178.90]) by iplan-mn.corp.adobe.com (iPlanet Messaging Server 5.2 HotFix 1.21 (built Sep 8 2003)) with ESMTP id <0I39007E0DQOI1@iplan-mn.corp.adobe.com>; Mon, 30 Aug 2004 07:08:49 -0500 (CDT) Date: Mon, 30 Aug 2004 16:01:00 -0000 From: Eljay Love-Jensen Subject: Re: Upgrade "may not respond to" warning to error In-reply-to: <2ECF1286-F94D-11D8-8E7F-000A95891440@slamb.org> X-Sender: eljay@iplan-mn.corp.adobe.com To: Scott Lamb , gcc-help@gcc.gnu.org Message-id: <6.1.2.0.2.20040830065939.01f64ec0@iplan-mn.corp.adobe.com> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii; format=flowed Content-transfer-encoding: 7BIT References: <2ECF1286-F94D-11D8-8E7F-000A95891440@slamb.org> X-SW-Source: 2004-08/txt/msg00274.txt.bz2 Hi Scott, >What's the flag for this message? I'm not sure. (I haven't familiarized myself with Objective-C. Which is ironic, since I'm an OS X person.) Refer to ... http://gcc.gnu.org/onlinedocs/gcc-3.4.1/gcc/Objective-C-Dialect-Options.html http://gcc.gnu.org/onlinedocs/gcc-3.4.1/gcc/Warning-Options.html >Is it possible to do something like -Werror on just some warnings? No. It's possible to doing something similar, using one of three different strategies: 1) edit the GCC source code and make the identified warnings errors. Rebuild your custom GCC. 2) post-process the output (using sed, for instance) and "upgrade" warnings to errors. Not quite the same thing, doesn't abort the compile, but may be "good enough". You can use that in conjunction with grep to detect for the upgraded warnings, and abort a make file by returning a failing error code. 3) have your build process perform two passes. The first pass enables all the warnings you want to see, the second pass enable only the warnings you want to be elevated to errors and turn on the -Werror flag. Those are just a few ideas off the top of my head. HTH, --Eljay