From unknown Sun Jun 22 00:52:45 2025 X-Loop: help-debbugs@gnu.org Subject: bug#6577: turn on -Wstrict-prototypes by default Resent-From: Dan Nicolaescu Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 07 Jul 2010 03:00:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 6577 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 6577@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.1278471596442 (code B ref -1); Wed, 07 Jul 2010 03:00:03 +0000 Received: (at submit) by debbugs.gnu.org; 7 Jul 2010 02:59:56 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OWKrc-000075-3E for submit@debbugs.gnu.org; Tue, 06 Jul 2010 22:59:56 -0400 Received: from mail.gnu.org ([199.232.76.166] helo=mx10.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OWKra-000070-1m for submit@debbugs.gnu.org; Tue, 06 Jul 2010 22:59:54 -0400 Received: from lists.gnu.org ([199.232.76.165]:33992) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1OWKrW-0006u7-LY for submit@debbugs.gnu.org; Tue, 06 Jul 2010 22:59:50 -0400 Received: from [199.232.76.173] (port=44764 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OWKrV-0005q2-VT for bug-gnu-emacs@gnu.org; Tue, 06 Jul 2010 22:59:49 -0400 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1OWKrU-0006u1-NH for bug-gnu-emacs@gnu.org; Tue, 06 Jul 2010 22:59:49 -0400 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on monty-python X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=AWL autolearn=ham version=3.1.0 Received: from fencepost.gnu.org ([140.186.70.10]:56443) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1OWKrU-0006tx-HO for bug-gnu-emacs@gnu.org; Tue, 06 Jul 2010 22:59:48 -0400 Received: from dann by fencepost.gnu.org with local (Exim 4.69) (envelope-from ) id 1OWKrU-00056X-Cw for bug-gnu-emacs@gnu.org; Tue, 06 Jul 2010 22:59:48 -0400 From: Dan Nicolaescu Date: Tue, 06 Jul 2010 22:59:48 -0400 Message-ID: User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-Spam-Score: -6.5 (------) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.5 (------) This patch turns on -Wstrict-prototypes to help transition to standard C. [Archived here so that it does not get lost]. The error and message declarations in lisp.h need to be converted to standard C (and the definition should use variable number of arguments), otherwise this patch results in many warnings. But if someone wants to check this in to speed up the process... === modified file 'configure.in' --- configure.in 2010-07-02 12:55:51 +0000 +++ configure.in 2010-07-02 19:31:41 +0000 @@ -757,6 +757,20 @@ CFLAGS="$SAVE_CFLAGS" unset has_option unset SAVE_CFLAGS +### Use -Wstrict-prototypes if the compiler supports it +AC_MSG_CHECKING([whether gcc understands -Wstrict-prototypes]) +SAVE_CFLAGS="$CFLAGS" +CFLAGS="$CFLAGS -Wstrict-prototypes" +AC_TRY_COMPILE([], [], has_option=yes, has_option=no,) +if test $has_option = yes; then + C_WARNINGS_SWITCH="-Wstrict-prototypes $C_WARNINGS_SWITCH" +fi +AC_MSG_RESULT($has_option) +CFLAGS="$SAVE_CFLAGS" +unset has_option +unset SAVE_CFLAGS + + #### Some other nice autoconf tests. dnl checks for programs From unknown Sun Jun 22 00:52:45 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.428 (Entity 5.428) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Dan Nicolaescu Subject: bug#6577: closed (Re: bug#6577: turn on -Wstrict-prototypes by default) Message-ID: References: <0t7gmlg79a.fsf@fencepost.gnu.org> X-Gnu-PR-Message: they-closed 6577 X-Gnu-PR-Package: emacs X-Gnu-PR-Keywords: patch Reply-To: 6577@debbugs.gnu.org Date: Wed, 06 Feb 2013 08:48:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1360140482-19802-1" This is a multi-part message in MIME format... ------------=_1360140482-19802-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #6577: turn on -Wstrict-prototypes by default which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 6577@debbugs.gnu.org. --=20 6577: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D6577 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1360140482-19802-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 6577-done) by debbugs.gnu.org; 6 Feb 2013 08:47:12 +0000 Received: from localhost ([127.0.0.1]:38716 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U30et-000587-RE for submit@debbugs.gnu.org; Wed, 06 Feb 2013 03:47:11 -0500 Received: from fencepost.gnu.org ([208.118.235.10]:53623) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U30er-00057z-NQ for 6577-done@debbugs.gnu.org; Wed, 06 Feb 2013 03:47:10 -0500 Received: from rgm by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1U30dd-0007Yx-HM; Wed, 06 Feb 2013 03:45:53 -0500 From: Glenn Morris To: 6577-done@debbugs.gnu.org Subject: Re: bug#6577: turn on -Wstrict-prototypes by default References: X-Spook: BATF AK-47 Axis of Evil rail gun passwd Fedayeen InfoSec X-Ran: SMW94qzp=>v-\I7mB&j:CGs1ZD\4J!>K*Yot!RU(1a{(R(uQ%t~('t=kH (Dan Nicolaescu's message of "Tue, 06 Jul 2010 22:59:48 -0400") Message-ID: <0t7gmlg79a.fsf@fencepost.gnu.org> User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -4.2 (----) X-Debbugs-Envelope-To: 6577-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -5.5 (-----) Version: 24.3 IIUC we now have this and much more via gnulib with the --enable-gcc-warnings option of configure. ------------=_1360140482-19802-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 7 Jul 2010 02:59:56 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OWKrc-000075-3E for submit@debbugs.gnu.org; Tue, 06 Jul 2010 22:59:56 -0400 Received: from mail.gnu.org ([199.232.76.166] helo=mx10.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OWKra-000070-1m for submit@debbugs.gnu.org; Tue, 06 Jul 2010 22:59:54 -0400 Received: from lists.gnu.org ([199.232.76.165]:33992) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1OWKrW-0006u7-LY for submit@debbugs.gnu.org; Tue, 06 Jul 2010 22:59:50 -0400 Received: from [199.232.76.173] (port=44764 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OWKrV-0005q2-VT for bug-gnu-emacs@gnu.org; Tue, 06 Jul 2010 22:59:49 -0400 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1OWKrU-0006u1-NH for bug-gnu-emacs@gnu.org; Tue, 06 Jul 2010 22:59:49 -0400 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on monty-python X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=AWL autolearn=ham version=3.1.0 Received: from fencepost.gnu.org ([140.186.70.10]:56443) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1OWKrU-0006tx-HO for bug-gnu-emacs@gnu.org; Tue, 06 Jul 2010 22:59:48 -0400 Received: from dann by fencepost.gnu.org with local (Exim 4.69) (envelope-from ) id 1OWKrU-00056X-Cw for bug-gnu-emacs@gnu.org; Tue, 06 Jul 2010 22:59:48 -0400 To: bug-gnu-emacs@gnu.org Subject: turn on -Wstrict-prototypes by default From: Dan Nicolaescu X-Debbugs-No-Ack: yes Date: Tue, 06 Jul 2010 22:59:48 -0400 Message-ID: User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-Spam-Score: -6.5 (------) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.5 (------) This patch turns on -Wstrict-prototypes to help transition to standard C. [Archived here so that it does not get lost]. The error and message declarations in lisp.h need to be converted to standard C (and the definition should use variable number of arguments), otherwise this patch results in many warnings. But if someone wants to check this in to speed up the process... === modified file 'configure.in' --- configure.in 2010-07-02 12:55:51 +0000 +++ configure.in 2010-07-02 19:31:41 +0000 @@ -757,6 +757,20 @@ CFLAGS="$SAVE_CFLAGS" unset has_option unset SAVE_CFLAGS +### Use -Wstrict-prototypes if the compiler supports it +AC_MSG_CHECKING([whether gcc understands -Wstrict-prototypes]) +SAVE_CFLAGS="$CFLAGS" +CFLAGS="$CFLAGS -Wstrict-prototypes" +AC_TRY_COMPILE([], [], has_option=yes, has_option=no,) +if test $has_option = yes; then + C_WARNINGS_SWITCH="-Wstrict-prototypes $C_WARNINGS_SWITCH" +fi +AC_MSG_RESULT($has_option) +CFLAGS="$SAVE_CFLAGS" +unset has_option +unset SAVE_CFLAGS + + #### Some other nice autoconf tests. dnl checks for programs ------------=_1360140482-19802-1--