From unknown Mon Aug 11 18:18:59 2025 X-Loop: help-debbugs@gnu.org Subject: bug#37632: [PATCH] Support GNU make error messages in compile mode. Resent-From: Paul Smith Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 05 Oct 2019 13:39:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 37632 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch To: 37632@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.157028271816907 (code B ref -1); Sat, 05 Oct 2019 13:39:01 +0000 Received: (at submit) by debbugs.gnu.org; 5 Oct 2019 13:38:38 +0000 Received: from localhost ([127.0.0.1]:43934 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iGkGb-0004Od-Pw for submit@debbugs.gnu.org; Sat, 05 Oct 2019 09:38:38 -0400 Received: from lists.gnu.org ([209.51.188.17]:48359) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iGkGZ-0004OU-Ha for submit@debbugs.gnu.org; Sat, 05 Oct 2019 09:38:35 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59891) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iGkGY-0006Eo-6A for bug-gnu-emacs@gnu.org; Sat, 05 Oct 2019 09:38:35 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.2 required=5.0 tests=ALL_TRUSTED,BAYES_50 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:470:142:3::e]:40034) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1iGkGY-0004Sg-38 for bug-gnu-emacs@gnu.org; Sat, 05 Oct 2019 09:38:34 -0400 Received: from pool-98-118-0-140.bstnma.fios.verizon.net ([98.118.0.140]:59732 helo=homebase.bo2.nuodb.com) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1iGkGX-0000WC-NO for bug-gnu-emacs@gnu.org; Sat, 05 Oct 2019 09:38:33 -0400 From: Paul Smith Date: Sat, 5 Oct 2019 09:38:11 -0400 Message-Id: <20191005133811.12302-1-psmith@gnu.org> X-Mailer: git-send-email 2.18.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * lisp/progmodes/compile.el (compilation-error-regexp-alist-alist): Match GNU make error messages. * test/lisp/progmodes/compile-tests.el (compile-tests--test-regexps-data): Test GNU make error message matching. (compile-test-error-regexps): Update count of infos found. --- lisp/progmodes/compile.el | 6 ++++++ test/lisp/progmodes/compile-tests.el | 8 +++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index 83efb3e029..50370a4f3a 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -274,6 +274,12 @@ compilation-error-regexp-alist-alist (ruby-Test::Unit "^[\t ]*\\[\\([^(].*\\):\\([1-9][0-9]*\\)\\(\\]\\)?:in " 1 2) + (gmake + ;; Set GNU make error messages as INFO level. + ;; It starts with the name of the make program which is variable, + ;; so don't try to match it. + ": \\*\\*\\* \\[\\(\\(.+?\\):\\([0-9]+\\): .+\\)\\]" 2 3 nil 0 1) + (gnu ;; The first line matches the program name for diff --git a/test/lisp/progmodes/compile-tests.el b/test/lisp/progmodes/compile-tests.el index 8e59a5401b..08a369e7b5 100644 --- a/test/lisp/progmodes/compile-tests.el +++ b/test/lisp/progmodes/compile-tests.el @@ -180,6 +180,12 @@ compile-tests--test-regexps-data 1 0 31 "/usr/include/c++/3.3/backward/iostream.h") (" from test_clt.cc:1:" 1 nil 1 "test_clt.cc") + ;; gmake + ("make: *** [Makefile:20: all] Error 2" 12 nil 20 "Makefile" 0) + ("make[4]: *** [sub/make.mk:19: all] Error 127" 15 nil 19 "sub/make.mk" 0) + ("gmake[4]: *** [sub/make.mk:19: all] Error 2" 16 nil 19 "sub/make.mk" 0) + ("gmake-4.3[4]: *** [make.mk:1119: all] Error 2" 20 nil 1119 "make.mk" 0) + ("Make-4.3: *** [make.INC:1119: dir/all] Error 2" 16 nil 1119 "make.INC" 0) ;; gnu ("foo.c:8: message" 1 nil 8 "foo.c") ("../foo.c:8: W: message" 1 nil 8 "../foo.c") @@ -409,7 +415,7 @@ compile-test-error-regexps (mapc #'compile--test-error-line compile-tests--test-regexps-data) (should (eq compilation-num-errors-found 87)) (should (eq compilation-num-warnings-found 32)) - (should (eq compilation-num-infos-found 21))))) + (should (eq compilation-num-infos-found 26))))) (ert-deftest compile-test-grep-regexps () "Test the `grep-regexp-alist' regexps. -- 2.18.0 From debbugs-submit-bounces@debbugs.gnu.org Sat Oct 05 09:58:34 2019 Received: (at control) by debbugs.gnu.org; 5 Oct 2019 13:58:34 +0000 Received: from localhost ([127.0.0.1]:44964 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iGkZt-000586-UY for submit@debbugs.gnu.org; Sat, 05 Oct 2019 09:58:34 -0400 Received: from eggs.gnu.org ([209.51.188.92]:53128) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iGkZr-00057r-IP for control@debbugs.gnu.org; Sat, 05 Oct 2019 09:58:32 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:40409) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1iGkZm-00061b-9a for control@debbugs.gnu.org; Sat, 05 Oct 2019 09:58:26 -0400 Received: from [176.228.60.248] (port=4355 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1iGkZl-00062E-0F for control@debbugs.gnu.org; Sat, 05 Oct 2019 09:58:25 -0400 Date: Sat, 05 Oct 2019 16:58:12 +0300 Message-Id: <83bluv47m3.fsf@gnu.org> From: Eli Zaretskii To: control@debbugs.gnu.org In-reply-to: <20191005133811.12302-1-psmith@gnu.org> (message from Paul Smith on Sat, 5 Oct 2019 09:38:11 -0400) Subject: Re: bug#37632: [PATCH] Support GNU make error messages in compile mode. References: <20191005133811.12302-1-psmith@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) merge 37632 37484 thanks