From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Marco Antoniotti Newsgroups: gmane.emacs.help Subject: Re: Retrieving the "include" directory for Emacs Modules Date: Sat, 21 Dec 2024 21:04:43 +0100 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="10480"; mail-complaints-to="usenet@ciao.gmane.io" To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Sat Dec 21 21:05:46 2024 Return-path: Envelope-to: geh-help-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 1tP5jN-0002Xi-9w for geh-help-gnu-emacs@m.gmane-mx.org; Sat, 21 Dec 2024 21:05:45 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tP5id-0000lu-S8; Sat, 21 Dec 2024 15:04:59 -0500 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 1tP5ic-0000lh-4N for help-gnu-emacs@gnu.org; Sat, 21 Dec 2024 15:04:58 -0500 Original-Received: from mail-yb1-xb36.google.com ([2607:f8b0:4864:20::b36]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tP5ia-0006YK-4R for help-gnu-emacs@gnu.org; Sat, 21 Dec 2024 15:04:57 -0500 Original-Received: by mail-yb1-xb36.google.com with SMTP id 3f1490d57ef6-e46e574847aso327690276.0 for ; Sat, 21 Dec 2024 12:04:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1734811494; x=1735416294; darn=gnu.org; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=LXsn3kB49bLfVQnIQO5GyonzQIoCDxgRq0exzQ+O/lA=; b=Hz8juvnj8foh37fLAhS4DWQmRqjHPFmeL4Ug8ehl/oC/8T3QQfjpx0Tss8+ntfaCy+ 4E+q3MFPr2PsdbMDNvhsF2biyChNEjbm+6aQXxuVe15Q8IVsH28t7OWvpUk5LumgbvkH Es7gcLcNVjl5VNgJOyuEwDHMjiU5ZoXJyDE4tq1KIFzpNm2QgYNEfTB+AkVhlBoEs9tn 4WuXytaNFIwU+bSfpCh9z221wZfn648ExxOPSNZZLFv4DCMLZPWrJeZi2tP9jckF8S82 wmHOsptkHFEjiH6aV7WuLki562ps9gx3dhxvXYz7j51zmKdkcUypKY+KWkQJyvU97S83 qF6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734811494; x=1735416294; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=LXsn3kB49bLfVQnIQO5GyonzQIoCDxgRq0exzQ+O/lA=; b=Ced03Mo5iSQ34gQapT9qLD7dSlm+ZEko4dCYS9Yzes7nzS+9Rusko2FBiAVnWUPfSS 7mr5K2/0kDnlFKI3n0NokiRM/LSRMEG9DY9CAobubu+tUO9P0e/SzdVyhr5cfXOtb5Th OLRgLUbU4r/RMquWOR+tRdLozPrzpV+weuoZT81En2hBNFIDGVexegGxExrvmQ/zm9MZ lRctBO8OZ9ZSeo4h01pIFdSzZUVkAb6h90v+V7USygpWrwW1fJqfwcOXrBtbri7ZZ38h zHpmofr0m/aFF3y8++WvYVf8tZz6SNLj/NNHfsg/zjV5uKPL/h2HnW5rjnKmb74mbH6q 3ESw== X-Gm-Message-State: AOJu0YxYRNxzYOAVaDLvaR6LsTc4AQ/+2WrBXz8nx7lC1KdqGtq5U4B/ cYkWIQX9BnWziLZ6vIthoFGcM9QFqVnMfyrl20q9jRTxvv28YA+LkFDkGvbcac4TRSSjm5/vUUe YJRgyJWG+DbAVvp1NbEK6IlMbCf64cMgN X-Gm-Gg: ASbGncv4/Z7NgPFSNmupXLPurEqRKyguSCPYN53vRBMPhaMEU/5qi99XhQXWuo7wEZo yR5YdhoNapRbTsvV8iN0uBHoBvj2m+RMnTBkwXg== X-Google-Smtp-Source: AGHT+IFVI5a7vb00Tj6JXDfJRWGgEoUfWSjsd13qyngRKlQAe7mPeswrUjThC2ghGpEuebk8Oo81cBwZoZeejlKLZcw= X-Received: by 2002:a05:6902:18c6:b0:e4c:e9b8:eb36 with SMTP id 3f1490d57ef6-e538c1f2d4fmr2124934276.1.1734811494277; Sat, 21 Dec 2024 12:04:54 -0800 (PST) In-Reply-To: Received-SPF: pass client-ip=2607:f8b0:4864:20::b36; envelope-from=marcoxa@gmail.com; helo=mail-yb1-xb36.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.help:148913 Archived-At: On Fri, Dec 20, 2024 at 6:02=E2=80=AFPM wr= ote: > > Message: 2 > Date: Fri, 20 Dec 2024 10:41:08 -0500 > From: Stefan Monnier > To: Bj=C3=B6rn Bidar > Cc: Stefan Monnier via Users list for the GNU Emacs text editor > > Subject: Re: Retrieving the "include" directory for Emacs Modules > Message-ID: > Content-Type: text/plain > > >> That's OK: the sole purpose of the change is to let ELPA packages call > >> `gcc` with such a `-I`! > > Which is wrong for Unix-like systems except on macOS. > > In which sense would it be wrong? > I can see an argument that such a `-I` would tend to be redundant on > systems where Emacs was "installed properly", but even on those systems > I fail to see what would be "wrong" about it. > I obviously agree. I would also contend that "Emacs installed properly" should mean "installed according to the standards of the platform". Now, on Windows this means (usually) "C:/Program Files/Emacs/emacs-MM.mm/", with subdirs bin, include, lib. libexec and share. This is not so far-off UN*X; it is "standard" (as per Microsoft) and yet it is not what UN*X people, and, it appears, some Emacs people, would consider "proper". On Mac OS, https://emacsformacosx.com/ does a very good job of providing batteries-included Emacs. Its installation is, per Apple's ukazes, in /Applicatiions/Emacs.app/Contents/Resources. Note that this is a "simplified" Apple installation, but surely it is "proper" under Mac OS. Let me weigh in on another topic. I teach and I have students come in (second year CS) with all sorts of editors installed, Sublime, VSCode, Vim, Eclipse, Notepad, whatever; no one uses Emacs. First thing I do is to tell them to "install Emacs". Do you (Bj=C3=B6rn) think that, apart from the very hard core "I-already-know-Rust-and-C-sucks-because-I-recompiled-the-Linux-kernel-when= -I-was-9-yo-on-my-Rasperry-pi" three or four guys (they are obviously male) the majority is going to "compile and install Emacs"? They go to https://emacsformacosx.com/ and to the https://www.gnu.org/software/emacs/download.html sites and download the installers. Or they use homebrew, snap or apt. Bottom line, if you want our beloved editor to be used, lighten up. (Yes, I am patronizing; sorry; I am a boomer: TOWANDA :) ). > It's debatable if packages should compile their native modules > > themselves > > IME it's what most users expect when they install (via `package.el`) > packages that come with a module, and it's also what most of the > developers of those packages want to offer to their users. > I have no intention to impose such an approach as the only supported way > to install a module, but I don't see what's debatable about providing > good support for packages to be able to compile their own modules. > Exactly. Two thumbs up! TRT is to make the system as "open" as possible, by playing ball with the platforms out there (at least Windows and Mac OS). People will find all sorts of ways to use the C compiler that they have at hand; and no, these days the C compiler is not necessarily gcc, and you should not assume it is. That is why you need to expose the "Emacs configuration"; which means, at a minimum, the 'include' directory for the header file(s) to build dynamic Emacs modules. Having a bunch of 'emacs-*' elisp variables/constants that can be queried would be very helpful (hint: data-directory could be aliased to emacs-data-directory). I know this should move to the development list. All the best Marco PS Sorry Stefan, the "you" in the answer is not you personally; I believe you are a French speaker, if you are, you know about 'tu' and 'vous' :) --=20 Marco Antoniotti Somewhere over the Rainbow