From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ihor Radchenko Newsgroups: gmane.emacs.bugs Subject: bug#62762: 'make' often errors with "Org version mismatch" after pulling a new version of the code Date: Thu, 13 Apr 2023 14:20:05 +0000 Message-ID: <87h6tjeuei.fsf@localhost> References: <17b74a48-94e1-9106-cc79-d31972313910@gutov.dev> <837cujaqzq.fsf@gnu.org> <87wn2ilwed.fsf@localhost> <83zg7ealrd.fsf@gnu.org> <87pm8a8dx4.fsf@localhost> <8335569rs7.fsf@gnu.org> <87jzyi8cu2.fsf@localhost> <83wn2i8bht.fsf@gnu.org> <875ya18oaz.fsf@localhost> <83zg7d78wv.fsf@gnu.org> <87fs94faes.fsf@localhost> <83zg7c41qq.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="8146"; mail-complaints-to="usenet@ciao.gmane.io" Cc: bzg@gnu.org, dmitry@gutov.dev, 62762@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Apr 13 16:18:32 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1pmxmR-0001vk-I3 for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 13 Apr 2023 16:18:31 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pmxm2-0003U6-Kn; Thu, 13 Apr 2023 10:18:06 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pmxlz-0003Ro-16 for bug-gnu-emacs@gnu.org; Thu, 13 Apr 2023 10:18:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pmxly-0001P8-Ox for bug-gnu-emacs@gnu.org; Thu, 13 Apr 2023 10:18:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pmxly-0002m1-64 for bug-gnu-emacs@gnu.org; Thu, 13 Apr 2023 10:18:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Ihor Radchenko Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 13 Apr 2023 14:18:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62762 X-GNU-PR-Package: emacs Original-Received: via spool by 62762-submit@debbugs.gnu.org id=B62762.168139547110644 (code B ref 62762); Thu, 13 Apr 2023 14:18:02 +0000 Original-Received: (at 62762) by debbugs.gnu.org; 13 Apr 2023 14:17:51 +0000 Original-Received: from localhost ([127.0.0.1]:44377 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pmxln-0002lc-1Y for submit@debbugs.gnu.org; Thu, 13 Apr 2023 10:17:51 -0400 Original-Received: from mout02.posteo.de ([185.67.36.66]:39121) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pmxli-0002lK-Cu for 62762@debbugs.gnu.org; Thu, 13 Apr 2023 10:17:49 -0400 Original-Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id 517D32403B8 for <62762@debbugs.gnu.org>; Thu, 13 Apr 2023 16:17:40 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1681395460; bh=OcClydrXnwseN+wotCpWXqUNZ4xUZ2nWwLOqzGZaILE=; h=From:To:Cc:Subject:Date:From; b=eVCXnEOCDKcRPIeXvr3o3v8y/i9STQFA82u9I7R1VLW8Vf6FGRNQvT/drrBOwXxLP VWMwv8tXEnE3RneWUpiACPXOUEBnV/o1E8d6C2ZltKgxRdKt1rUcDNcwb6tzLvL7kN ETcTuCrd9SArMHpDECY05LA+6Xsbcg1j/VhTkiwd7vtXtpX9UxZdF1uPdcVuLecm8h CR4IW94eEPnTshYMwPf8+3WU5jtBIIe8oqJ8bLl9JFvZyccPl/TEo6EvJmY14RjF+8 +jqD99w/7wpKCJBZcEwdDT5vVIsAtrezFMjXocZDUGt6VIZwI7ylqYjlrPzjOj4onl gjvTWjC/xqKFw== Original-Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4Py1r33Rcpz6tsf; Thu, 13 Apr 2023 16:17:39 +0200 (CEST) In-Reply-To: <83zg7c41qq.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:259854 Archived-At: --=-=-= Content-Type: text/plain Eli Zaretskii writes: > I think ELisp variable is better, since environment variables are > inherited by sub-processes in ways that are hard to control. See the attached. On Emacs side, `org--built-in-p' will need to be set during compilation. --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-org-assert-version-Skip-version-check-when-Org-is-a-.patch >From 89140b0d747aa127e7b06ed927c09286215e4824 Mon Sep 17 00:00:00 2001 Message-Id: <89140b0d747aa127e7b06ed927c09286215e4824.1681395507.git.yantar92@posteo.net> From: Ihor Radchenko Date: Thu, 13 Apr 2023 16:18:15 +0200 Subject: [PATCH] org-assert-version: Skip version check when Org is a part of Emacs * lisp/org-macs.el (org--built-in-p): New constant indicating if Org source is a part of Emacs source tree. (org-assert-version): Skip check when Org is built-in. --- lisp/org-macs.el | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lisp/org-macs.el b/lisp/org-macs.el index ad1d3cf14..b4a5d82c8 100644 --- a/lisp/org-macs.el +++ b/lisp/org-macs.el @@ -36,6 +36,9 @@ (require 'format-spec) ;;; Org version verification. +(defconst org--built-in-p nil + "When non-nil, assume that Org is a part of Emacs source. +See Emacs bug #62762.") (defmacro org-assert-version () "Assert compile time and runtime version match." ;; We intentionally use a more permissive `org-release' instead of @@ -45,7 +48,7 @@ (defmacro org-assert-version () ;; `org-assert-version' calls would fail using strict ;; `org-git-version' check because the generated Org version strings ;; will not match. - `(unless (equal (org-release) ,(org-release)) + `(unless (or org--built-in-p (equal (org-release) ,(org-release))) (warn "Org version mismatch. Org loading aborted. This warning usually appears when a built-in Org version is loaded prior to the more recent Org version. -- 2.40.0 --=-=-= Content-Type: text/plain -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at --=-=-=--