From patchwork Mon May 19 21:25:25 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joel Brobecker X-Patchwork-Id: 1017 Return-Path: X-Original-To: siddhesh@wilcox.dreamhost.com Delivered-To: siddhesh@wilcox.dreamhost.com Received: from homiemail-mx21.g.dreamhost.com (peon2454.g.dreamhost.com [208.113.200.127]) by wilcox.dreamhost.com (Postfix) with ESMTP id 5B9EA360098 for ; Mon, 19 May 2014 14:25:34 -0700 (PDT) Received: by homiemail-mx21.g.dreamhost.com (Postfix, from userid 14314964) id DC9021F57C1D; Mon, 19 May 2014 14:25:33 -0700 (PDT) X-Original-To: gdb@patchwork.siddhesh.in Delivered-To: x14314964@homiemail-mx21.g.dreamhost.com Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by homiemail-mx21.g.dreamhost.com (Postfix) with ESMTPS id 237EB1B2B6B7 for ; Mon, 19 May 2014 14:25:33 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:date:message-id; q=dns; s= default; b=Do3q+WhTlm+p5lsfOrtVz6y9J4ZpDlylUvh+5+Fag6QcC+S6jsX8B 8ULdHGllrKWIEyaqnzfdqvzG49u7ImfQKx4symxkjnfiVZ0h154qsqSRXhRAu0uX 6zozpF2yXc2nLh5X6vn36i2U3X5hO8QBSjoNAdx8kY3h3Z6oau/AL4= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:date:message-id; s=default; bh=d1hj4VwxGUXVoGkYKFqM2taxQKU=; b=SCtWWoK9Cd7mz9FQngkvTwPxbAU+ w8W+uvgFm4PtrzbnkV8cysF2jbTWz3XDNPHXVDBU+uwSic+NnByqPVG3xIXJqOKa lNQwEqvgLz/CB3typW6mjeXmXpSzte/Fv0T4oP8B0gMPA7+yRJ623gqlxqoC6J1h vz9Uv1j4q5GKXWA= Received: (qmail 15385 invoked by alias); 19 May 2014 21:25:31 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 15362 invoked by uid 89); 19 May 2014 21:25:30 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=AWL, BAYES_00, RP_MATCHES_RCVD, SPF_PASS autolearn=ham version=3.3.2 X-HELO: rock.gnat.com Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Mon, 19 May 2014 21:25:29 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id 5DBA8116180 for ; Mon, 19 May 2014 17:25:27 -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 A5SD4XA1kdiw for ; Mon, 19 May 2014 17:25:27 -0400 (EDT) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id 2C5ED1160BE for ; Mon, 19 May 2014 17:25:27 -0400 (EDT) Received: by joel.gnat.com (Postfix, from userid 1000) id 6F7B443848; Mon, 19 May 2014 14:25:26 -0700 (PDT) From: Joel Brobecker To: gdb-patches@sourceware.org Subject: [RFA] Do not build gdbserver with -Werror by default if development=false Date: Mon, 19 May 2014 14:25:25 -0700 Message-Id: <1400534725-931-1-git-send-email-brobecker@adacore.com> X-DH-Original-To: gdb@patchwork.siddhesh.in Hello, On GDB release branches, we change $development in gdb/development.sh to false, in order to build the GDB release without -Werror by default, thus avoiding harmless compiler warnings from breaking the build of someone who's only interested in building GDB rather than working on it. This patch implements the same strategy for gdbserver, using the exact same method. gdb/gdbserver/ChangeLog: * configure.ac: Only use -Werror by default when DEVELOPMENT is true. * configure: Regenerate. Tested on x86_64-linux, by rebuilding GDBserver first with development set to true, and then doing it again with development set to false. Werror was used in the first case, but not in the second. OK to commit? Thanks, diff --git a/gdb/gdbserver/configure b/gdb/gdbserver/configure index 6d8a6a7..101062f 100755 --- a/gdb/gdbserver/configure +++ b/gdb/gdbserver/configure @@ -5244,8 +5244,8 @@ if test "${enable_werror+set}" = set; then : fi -# Enable -Werror by default when using gcc -if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then +# Enable -Werror by default when using gcc. Turn it off for releases. +if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" && $development; then ERROR_ON_WARNING=yes fi diff --git a/gdb/gdbserver/configure.ac b/gdb/gdbserver/configure.ac index 0dfa4a9..89a8eea 100644 --- a/gdb/gdbserver/configure.ac +++ b/gdb/gdbserver/configure.ac @@ -143,8 +143,8 @@ AC_ARG_ENABLE(werror, *) AC_MSG_ERROR(bad value ${enableval} for --enable-werror) ;; esac]) -# Enable -Werror by default when using gcc -if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then +# Enable -Werror by default when using gcc. Turn it off for releases. +if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" && $development; then ERROR_ON_WARNING=yes fi