From: "Björn Bidar" <bjorn.bidar@thaodan.de>
To: Marco Antoniotti <marcoxa@gmail.com>
Cc: help-gnu-emacs@gnu.org
Subject: Re: Retrieving the "include" directory for Emacs Modules
Date: Fri, 03 Jan 2025 23:06:54 +0200 [thread overview]
Message-ID: <32381.3624026783$1735938469@news.gmane.org> (raw)
In-Reply-To: <CAKmY7cXJ8+dOB4O-Bdw8GvndEe3HtKBxqE_jKSphCQu_n46q8w@mail.gmail.com> (Marco Antoniotti's message of "Fri, 3 Jan 2025 11:52:56 +0200")
Marco Antoniotti <marcoxa@gmail.com> writes:
> On Fri, Jan 3, 2025 at 1:12 AM Björn Bidar <bjorn.bidar@thaodan.de> wrote:
>
>> Marco Antoniotti <marcoxa@gmail.com> writes:
>>
>> > Hello and Happy New (Hacking) Year.
>> >
>> > apologies if I insist on this issue.
>> >
>> > On Sun, Dec 29, 2024 at 6:53 PM <help-gnu-emacs-request@gnu.org> wrote:
>> >
>> >> Message: 5
>> >> Date: Sun, 29 Dec 2024 03:03:53 +0200
>> >> From: Björn Bidar <bjorn.bidar@thaodan.de>
>> >> To: Stefan Monnier via Users list for the GNU Emacs text editor
>> >> <help-gnu-emacs@gnu.org>
>> >> Cc: Stefan Monnier <monnier@iro.umontreal.ca>
>> >> Subject: Re: Retrieving the "include" directory for Emacs Modules
>> >> Message-ID: <8734i7i9l2.fsf@>
>> >> Content-Type: text/plain
>> >>
>> >> Stefan Monnier via Users list for the GNU Emacs text editor
>> >> <help-gnu-emacs@gnu.org> writes:
>> >>
>> >> >> Those under /usr/lib are looked in by the relevant compilers (they
>> are
>> >> >> include directories private to those compilers, hard-coded into them
>> >> >> when they are built). Those under /usr/share are private to the
>> >> >> relevant packages, and are either examples or test suites (thus AFAIU
>> >> >> unrelated to the issue at hand here). Those under /usr/src are what
>> I
>> >> >> mentioned: private headers needed to build a package.
>> >> >
>> >> > Indeed, they each have their own reason to exist. And this is in
>> Debian,
>> >> > i.e. a distribution which is very careful to install things in the one
>> >> > central place where they belong.
>> >>
>> >> I'm on openSUSE which is entirely unrelated same policy. In fact all
>> >> Unixes have such a policy (macOS doesn't count in this context).
>> >>
>> >
>> > ... and why exactly MacOSX (and Windows) "don't count in this context"?
>> > And what is the "context"?
>>
>> I wrote macOS (the is no longer in the name) does not count in the
>> sentence as Unix as the NextStep/GNUStep build of Emacs uses an app
>> bundle which does not install into a prefix directory normally.
>>
>>
> It installs "normally" as far as Mac OS (X or not) is concerned.
Do you have Emacs.app or not? The normal way does not use Emacs.app.
>> >>
>> >> > Other relevant cases will look very different:
>> >> > Emacs.app, AppImages, Snap packages, etc...
>> >>
>> >> Who are proprietary platforms such as Snap relevant to Emacs? For these
>> >> where a sandbox is involved such as Snap or Flatpak it is not possible
>> >> to interact with external resources without breaking the security of the
>> >> sandbox.
>> >>
>> >
>> >> But anyway this is going off-topic.
>> >>
>> >>
>> > How exaclty does having
>> >
>> > include-directory
>> >
>> > (and the other variables) available, break the sandbox? Or anything
>> else?
>>
>> If Emacs is installed from Flatpak loading libraries outside of that
>> sandbox break the security of it. Building modules inherently requires
>> to call external binaries to link against external dependencies.
>>
>
> Oh come on! Emacs is not exactly the "safest" of environments. Your
> argument here boils down to "do not build Emacs Modules".
My point is if you use flatpak you should pull your dependencies from
Flatpak or you break the main purpose for using the Flatpak sandbox
completely, at that point you can also install Emacs without Flatpak and
have the same results with less issues.
>> The issue here is accommodating the wider world.
>>
>> It is but accommodating the wider world ultimately only mattered for
>> free open source platforms not on the non-free platforms supported by
>> Emacs.
>> I don't say that is what should happen here but the workarounds required
>> for some platforms should not affect others.
>>
>
> And how exposing 'include-directory' would affect you? Or VS Code (which,
> I remind you, is what the vast majority of incoming students uses)? Or
> FOSS platforms?
>
What does this have to do with VS Code? What is exposing
Include-directory?
If I understand correctly there should be include folder in the Windows
build and inside Emacs.app folder. Adding the include directory relative
to the prefix of the Emacs installation might be a ok workaround for
these platforms.
For the others where the compiler searches for the headers in the
default path where it was installed by the package manager it would
explicitly add the default include path to the list of folders to search
which might not be the users intention, i.e. it could have side effects.
I does not make sense to apply platform specific workarounds to all platforms.
>> > Personal historical note. I first used Emacs on a Zentih z8000. The
>> first
>> > GNU Emacs I used was on a Sun 3/60. I also used it on AIX and, if memory
>> > does not fail me, on a microVAX with VMS (this I may be wrong).
>> >
>> > These were (are) all proprietary platforms. "Unixy" but proprietary. As
>> > MacOSX.
>> >
>> > Do you want people to use Emacs? Let them have access to it without
>> > imposing needless constraints.
>> >
>>
>> The issue is something which was known before the module system was
>> added to Emacs, that requiring to compile native code for interfacing
>> with other libraries complicates things. Which is why XEmacs had helper
>> programs or function to automate much of this process.
>>
>> Native modules have their place but it was criticized that comparing to
>> native
>> modules FFI would have been simpler as no native code would have had to
>> be compiled just to interface with external libraries.
>>
>
> ... great. Now, let me ask you: why are we inflicted (I feel
> "inflicted" 😑 ) Python (a FOSS language) instead of writing lovely
> parentheses?
Python? Context?
next prev parent reply other threads:[~2025-01-03 21:06 UTC|newest]
Thread overview: 45+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.2990.1735491145.7082.help-gnu-emacs@gnu.org>
2025-01-02 7:01 ` Retrieving the "include" directory for Emacs Modules Marco Antoniotti
2025-01-02 23:12 ` Björn Bidar
[not found] ` <67771d72.170a0220.681ba.7fadSMTPIN_ADDED_BROKEN@mx.google.com>
2025-01-03 9:52 ` Marco Antoniotti
2025-01-03 21:06 ` Björn Bidar [this message]
2025-01-04 15:28 ` Stefan Monnier via Users list for the GNU Emacs text editor
[not found] <mailman.2138.1735192985.7155.help-gnu-emacs@gnu.org>
2024-12-26 9:01 ` Marco Antoniotti
[not found] <mailman.81.1734714033.1948.help-gnu-emacs@gnu.org>
2024-12-21 20:04 ` Marco Antoniotti
2024-12-23 20:15 ` Björn Bidar
[not found] ` <6769c4ea.170a0220.d60c5.1423SMTPIN_ADDED_BROKEN@mx.google.com>
2024-12-23 20:56 ` Marco Antoniotti
2024-12-24 5:58 ` Stefan Monnier via Users list for the GNU Emacs text editor
[not found] <mailman.87.1733936470.18564.help-gnu-emacs@gnu.org>
2024-12-13 11:43 ` Marco Antoniotti
2024-12-13 12:23 ` Eli Zaretskii
[not found] <mailman.624.1733687129.13738.help-gnu-emacs@gnu.org>
2024-12-09 9:58 ` Marco Antoniotti
2024-12-09 14:56 ` Eli Zaretskii
2024-12-09 15:50 ` Rudolf Schlatte
2024-12-09 22:10 ` Stefan Monnier via Users list for the GNU Emacs text editor
2024-12-10 3:29 ` Eli Zaretskii
2024-12-11 3:23 ` Stefan Monnier via Users list for the GNU Emacs text editor
2024-12-11 13:01 ` Eli Zaretskii
2024-12-19 23:50 ` Björn Bidar
[not found] ` <87ttazmdvc.fsf@>
2024-12-20 7:09 ` Eli Zaretskii
2024-12-20 9:01 ` Basile Starynkevitch
2024-12-23 0:47 ` Björn Bidar
2024-12-20 15:41 ` Stefan Monnier
2024-12-23 1:00 ` Björn Bidar
[not found] ` <871pxzxlfe.fsf@>
2024-12-24 5:06 ` Stefan Monnier
2024-12-24 12:36 ` Eli Zaretskii
2024-12-24 15:30 ` Stefan Monnier via Users list for the GNU Emacs text editor
2024-12-24 16:38 ` Eli Zaretskii
2024-12-24 20:39 ` Björn Bidar
2024-12-25 17:35 ` Stefan Monnier via Users list for the GNU Emacs text editor
2024-12-29 1:03 ` Björn Bidar
2024-12-22 22:17 ` Arsen Arsenović
[not found] <mailman.606.1733669386.12711.help-gnu-emacs@gnu.org>
2024-12-08 15:18 ` Marco Antoniotti
2024-12-08 15:29 ` Jean Louis
2024-12-08 15:36 ` Marco Antoniotti
2024-12-08 15:50 ` Stefan Monnier via Users list for the GNU Emacs text editor
2024-12-08 16:36 ` Eli Zaretskii
2024-12-08 16:30 ` Eli Zaretskii
[not found] <mailman.77.1733590872.28947.help-gnu-emacs@gnu.org>
2024-12-08 9:59 ` Marco Antoniotti
2024-12-08 11:40 ` Eli Zaretskii
2024-12-08 15:47 ` Stefan Monnier via Users list for the GNU Emacs text editor
2024-12-08 16:39 ` Eli Zaretskii
2024-12-08 16:48 ` Stefan Monnier via Users list for the GNU Emacs text editor
2024-12-08 17:46 ` Eli Zaretskii
2024-12-09 14:11 ` Stefan Monnier via Users list for the GNU Emacs text editor
2024-12-07 16:27 Marco Antoniotti
2024-12-07 16:43 ` Eli Zaretskii
2024-12-07 19:09 ` Björn Bidar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='32381.3624026783$1735938469@news.gmane.org' \
--to=bjorn.bidar@thaodan.de \
--cc=help-gnu-emacs@gnu.org \
--cc=marcoxa@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).