From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: extraclean and admin/grammars [was Re: Git master head build failure?] Date: Thu, 01 Apr 2021 16:13:24 -0400 Message-ID: References: <875z16en2o.fsf@gmail.com> <83mtuih3en.fsf@gnu.org> <835z16gnkj.fsf@gnu.org> <83y2e2f22w.fsf@gnu.org> <83lfa1g4ns.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="21925"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: rgm@gnu.org, theophilusx@gmail.com, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Apr 01 22:14:08 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lS3hf-0005ZD-R8 for ged-emacs-devel@m.gmane-mx.org; Thu, 01 Apr 2021 22:14:07 +0200 Original-Received: from localhost ([::1]:49156 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lS3he-0006ZU-SJ for ged-emacs-devel@m.gmane-mx.org; Thu, 01 Apr 2021 16:14:06 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58062) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lS3h6-00069i-He for emacs-devel@gnu.org; Thu, 01 Apr 2021 16:13:32 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:11380) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lS3h4-0006bd-AB; Thu, 01 Apr 2021 16:13:31 -0400 Original-Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 01901440F98; Thu, 1 Apr 2021 16:13:29 -0400 (EDT) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 4FF884410CC; Thu, 1 Apr 2021 16:13:27 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1617308007; bh=AKIEvmsdWLzX095WhJg/bMwQwKGEIKfmpBNVylnlzLc=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=pXcoNBkeHXqfvg99Obs2macu1XRTJD+Ht0X6ZgEzVSL+Urmh8LG5AQ9KZb8Axf5I8 xc8bljPrtBVIISaZzTPZfuc4ldzX4jFvc3lH1ArtTVdZspH3r49kC0BsAxd0BZ7/Ye 1bjhoURcAKuMiEvoStr9fnIWfMgs2RKclRoP+cfcut475Gw7M/er6fQyg+NAyjjhHL 565I1duoH/gsPPjKLyJfPDR9Dg1VC5RdXbhrGSooiYbvuSr352bH15tUix+6GUCXKy lzydzkAObz2lwoLqcwXE5np9oWug+Qrm7yaCzIV2WdLlx3wbxWXwjp7sOEkOx/XlBo /p3HLJZRezPVA== Original-Received: from alfajor (104-222-126-84.cpe.teksavvy.com [104.222.126.84]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id B1431120246; Thu, 1 Apr 2021 16:13:26 -0400 (EDT) In-Reply-To: <83lfa1g4ns.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 01 Apr 2021 22:56:23 +0300") Received-SPF: pass client-ip=132.204.25.50; envelope-from=monnier@iro.umontreal.ca; helo=mailscanner.iro.umontreal.ca X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:267279 Archived-At: >> E.g. a first step could be to move `grammar-wy.el` to `grm-wy-boot.el` like we >> do with `ldefs-boot.el` (see patch below) to break the >> circular dependency. > > What patch? What do you mean "what patch"? *The* patch, of course. Stefan diff --git a/.gitignore b/.gitignore index b653ef215b..9fe8ecb594 100644 --- a/.gitignore +++ b/.gitignore @@ -88,6 +88,7 @@ lisp/cedet/semantic/wisent/javat-wy.el lisp/cedet/semantic/wisent/js-wy.el lisp/cedet/semantic/wisent/python-wy.el lisp/cedet/srecode/srt-wy.el +lisp/cedet/semantic/grammar-wy.el lisp/eshell/esh-groups.el lisp/finder-inf.el lisp/leim/ja-dic/ diff --git a/admin/grammars/Makefile.in b/admin/grammars/Makefile.in index aa09d9edf9..800e31762d 100644 --- a/admin/grammars/Makefile.in +++ b/admin/grammars/Makefile.in @@ -48,14 +48,11 @@ BOVINE = ${bovinedir}/make-by.el \ ${bovinedir}/scm-by.el -## FIXME Should include this one too: -## ${cedetdir}/semantic/grammar-wy.el -## but semantic/grammar.el (which is what we use to generate grammar-wy.el) -## requires it! -WISENT = \ - ${wisentdir}/javat-wy.el \ - ${wisentdir}/js-wy.el \ - ${wisentdir}/python-wy.el \ +WISENT = \ + ${cedetdir}/semantic/grammar-wy.el \ + ${wisentdir}/javat-wy.el \ + ${wisentdir}/js-wy.el \ + ${wisentdir}/python-wy.el \ ${cedetdir}/srecode/srt-wy.el ALL = ${BOVINE} ${WISENT} diff --git a/lisp/cedet/semantic/grammar.el b/lisp/cedet/semantic/grammar.el index dba289fdd7..782327e617 100644 --- a/lisp/cedet/semantic/grammar.el +++ b/lisp/cedet/semantic/grammar.el @@ -31,7 +31,12 @@ (require 'semantic/format) ;; FIXME this is a generated file, but we need to load this file to ;; generate it! -(require 'semantic/grammar-wy) +;; We need `semantic/grammar-wy.el' but we're also needed to generate +;; that file from `grammar.wy', so to break the dependency, we keep +;; a bootstrap copy of `grammar-wy.el' in `grm-wy-boot.el'. +(eval-and-compile + (unless (require 'semantic/grammar-wy nil t) + (load "semantic/grm-wy-boot"))) (require 'semantic/idle) (require 'help-fns) (require 'semantic/analyze) diff --git a/lisp/cedet/semantic/grammar-wy.el b/lisp/cedet/semantic/grm-wy-boot.el similarity index 100% rename from lisp/cedet/semantic/grammar-wy.el rename to lisp/cedet/semantic/grm-wy-boot.el