From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: "T.V Raman" Newsgroups: gmane.emacs.devel Subject: Re: Native Compilation And External Packages Date: Sat, 29 May 2021 18:58:52 -0700 Message-ID: References: <24754.27537.803673.706445@google.com> <83czt95wco.fsf@gnu.org> <838s3x5tnc.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=gb18030 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="374"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: Eli Zaretskii , emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun May 30 03:59:50 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 1lnAk1-000AWQ-Fz for ged-emacs-devel@m.gmane-mx.org; Sun, 30 May 2021 03:59:49 +0200 Original-Received: from localhost ([::1]:57468 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lnAk0-0006Oy-JE for ged-emacs-devel@m.gmane-mx.org; Sat, 29 May 2021 21:59:48 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57904) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lnAjC-0005j4-Hg for emacs-devel@gnu.org; Sat, 29 May 2021 21:58:58 -0400 Original-Received: from mail-pg1-x530.google.com ([2607:f8b0:4864:20::530]:38777) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lnAj9-0003Mx-Un for emacs-devel@gnu.org; Sat, 29 May 2021 21:58:58 -0400 Original-Received: by mail-pg1-x530.google.com with SMTP id 6so5604001pgk.5 for ; Sat, 29 May 2021 18:58:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=sj2RW69C5EtkgsHDXL2/gCXCbaGR1s3RR1H2FDhcIfE=; b=hFoFNr0/AtEI6cnRm3E30ulEWOIe/vmvMT5t16jJoIEnqH8lgOehImyQHrBckdFDtq Zx1ol9BHrJnOzP1eWtHWB3CbvU11/3i6aGMNVVEfPYt+v3+AsmGIAJc5zuFB8T5wq6Zt dunToUNrpRyrjJBfmyHh5SYfMYFwJ7Zu2VwHnsMikhEnz87rm3pu7dtfYpfu4A/ctIFT ZpCkwzzhoBDtGjAz55ojt6jRXdMX3BOJ/nYz9jkvRpSW3Rd8G86CS7o87VNNwVpVd7MT ym9aiu1n7GzlR4nyvPpcbXATct/KA/uY7pjDPaq9/rD4ckF+kcNzIqcdfIiHwWtfyzQ3 qJBw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=sj2RW69C5EtkgsHDXL2/gCXCbaGR1s3RR1H2FDhcIfE=; b=skbUTepvuiHs4IsG2Uhwpe9wTwZENcp82JvXFt/H/XB0EvdnsJIgZWwQWshbgb6DMR fHYAVW7Tiz2FVFfgfwZG6Y3yn1Q8hNyx/FEZRCwev385ZG6vCTQJCYl3q+jteBLEn33p pS5CS4yFVJEPS/YEFpCIA3UN91TyyAT2EiMZGGV9TPQjl7tKsJjZcaZPpEz34kEEjBMW tw1B3xNzm1C66R37BYncq+qPB/YDgyxVtUWi6QI2B76Xy+OBTiGTF5b4Naj5VlgJbCWc YQO/Ou+crbB2lyO1HpFGMxY5hEF0PcljcihW/YCl3CeA2sj6DgM2Ethl9d6EWh+3Gh2s 9S1g== X-Gm-Message-State: AOAM531K3bTLq5CZc5XQeRSnJHbgs7PXV5Z9PvCXfeW+cdLPK8cficS3 NYgw928tSlrNTTQR0QEBfbC2xg== X-Google-Smtp-Source: ABdhPJxFHvJWWAmAFJxicT9IcPyTRA/lacbJX/twmoKfyntGJgwGOp8s8c8rsKDgk2zn0PenmJu+tg== X-Received: by 2002:a62:148e:0:b029:2e4:e5a5:7e33 with SMTP id 136-20020a62148e0000b02902e4e5a57e33mr10703166pfu.9.1622339933991; Sat, 29 May 2021 18:58:53 -0700 (PDT) Original-Received: from raman-glaptop.localdomain (c-24-4-174-65.hsd1.ca.comcast.net. [24.4.174.65]) by smtp.gmail.com with ESMTPSA id t8sm2562330pfe.144.2021.05.29.18.58.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 May 2021 18:58:53 -0700 (PDT) Original-Received: by raman-glaptop.localdomain (Postfix, from userid 13930) id 1B3A7C20521; Sat, 29 May 2021 18:58:52 -0700 (PDT) In-Reply-To: (Stefan Monnier's message of "Sat, 29 May 2021 14:52:26 -0400") Received-SPF: pass client-ip=2607:f8b0:4864:20::530; envelope-from=raman@google.com; helo=mail-pg1-x530.google.com X-Spam_score_int: -175 X-Spam_score: -17.6 X-Spam_bar: ----------------- X-Spam_report: (-17.6 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_MED=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, ENV_AND_HDR_SPF_MATCH=-0.5, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, USER_IN_DEF_DKIM_WL=-7.5, USER_IN_DEF_SPF_WL=-7.5 autolearn=unavailable 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:270101 Archived-At: Stefan Monnier writes: I think you nailed it! Note that I dont rely on "any weird" dependency tricks, I do exactly what Emacs itself does by generating a loaddefs file that contains the right autoloads, so that that file can be pulled in during compile time for compiling the .elc file for each module. The emacspeak-preamble file contains Emacspeak's own core "require " statements as well as a couple of critical macros. Eli's suggestion to use the bootstrap related build function is something I'll try next -- that might well help. I'll see what emerges in the next couple of weeks, then write things up as appropriate --- Eli in a nutshell, what I'm trying to do is effectively now spread over a few threads from me -- TL;DR: "I'm trying to compile and use Emacspeak " which works, But at present it produces warnings that looks spurious and there may well be corner cases that are broken, though I've not found any. The Emacspeak codebase is strict with respect to byte-compiler warnings, I dont have *any* in the core --- and package-specification extensions compile with no warnings as long as the dependent package is installed. --Raman >>> The warnings are inconsistent as in: >>>=20 >>> Compiling at the command line using -f batch-byte-compile produces no >>> warnings; the same code produces warnings when native-emacs is run >> >> A Stefan says, these are real problems that you should report. they >> are not false warnings. > > IIUC he refers above to the case where his Makefiles only generate the > .elc and the .eln are auto-generated lazily later. This is a known > issue. > > IMO it should be fixed by making the lazy native compiler take the .elc > file as input instead of restarting from the .el file; those "extra > warnings" we get are due to dependencies not being loaded into the Emacs > session that does the native compilation and these missing dependencies > can cause macro-calls to be compiled as function calls, IOW we may end > up miscompiling the files. > > But of course, part of the blame is in the .el files themselves which > should not depend on special Makefile tricks to get the right files > preloaded, but it can require a fair bit of work to fix an existing > package w.r.t such problems. Also, this used to work so we should > strive to keep it working. > > > Stefan > > --=20 Thanks, --Raman(I Search, I Find, I Misplace, I Research) =817=A94 Id: kg:/m/0285kf1 =950=DC8