all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Tad <tadfisher@gmail.com>
To: Andrea Corallo <akrl@sdf.org>
Cc: 44726@debbugs.gnu.org
Subject: bug#44726: 28.0.50; [feature/native-comp] Provide a mechanism to populate comp-eln-load-path from the environment
Date: Thu, 19 Nov 2020 14:50:39 -0800	[thread overview]
Message-ID: <CA+Bndfvg7PoPjaHJJ=PCF2GBo90XygC6UL9Yt4Mnr70U7sZF3g@mail.gmail.com> (raw)
In-Reply-To: <xjfwnyh9lao.fsf@sdf.org>

On Thu, Nov 19, 2020 at 11:52 AM Andrea Corallo <akrl@sdf.org> wrote:

> Last question, what is specific need to filter out empty strings after
> splitting?

NixOS has code which appends an extra path separator[1], which looks
like:

    # It turns out, that the trailing : is actually required
    # see https://www.gnu.org/software/emacs/manual/html_node/elisp/Library-Search.html
    export EMACSLOADPATH="$lispDir:${EMACSLOADPATH-}"

The link to the Emacs manual leads to a section containing the text:

    An empty element in the value of the environment variable, whether
    trailing (as in the above example), leading, or embedded, is
    replaced by the default value of load-path as determined by the
    standard initialization procedure. If there are no such empty
    elements, then EMACSLOADPATH specifies the entire load-path. You
    must include either an empty element, or the explicit path to the
    directory containing the standard Lisp files, else Emacs will not
    function. (Another way to modify load-path is to use the -L
    command-line option when starting Emacs; see below.)

As the code I posted above simply prepends the value of this variable to
`comp-eln-load-path', which is already initialized with appropriate
default values, I didn't believe the special handling of empty path
entries was warranted in site-start.el. It would be consistent for
`comp' to implement the behavior as is done for `EMACSLOADPATH',
however.

[1] https://github.com/NixOS/nixpkgs/blob/bf486f784ddd969c03243dba4c93d0e8e861173e/pkgs/build-support/emacs/setup-hook.sh#L4-L6





  reply	other threads:[~2020-11-19 22:50 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-18 21:05 bug#44726: 28.0.50; [feature/native-comp] Provide a mechanism to populate comp-eln-load-path from the environment Tad
2020-11-18 21:15 ` Andrea Corallo via Bug reports for GNU Emacs, the Swiss army knife of text editors
2020-11-18 21:20   ` Tad
2020-11-18 21:41     ` Andrea Corallo via Bug reports for GNU Emacs, the Swiss army knife of text editors
2020-11-18 21:45       ` Tad
2020-11-19 19:52         ` Andrea Corallo via Bug reports for GNU Emacs, the Swiss army knife of text editors
2020-11-19 22:50           ` Tad [this message]
2020-11-20 10:03             ` Andrea Corallo via Bug reports for GNU Emacs, the Swiss army knife of text editors
2020-11-30 23:25               ` Andrea Corallo via Bug reports for GNU Emacs, the Swiss army knife of text editors
2020-11-20 14:43 ` Stefan Monnier

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CA+Bndfvg7PoPjaHJJ=PCF2GBo90XygC6UL9Yt4Mnr70U7sZF3g@mail.gmail.com' \
    --to=tadfisher@gmail.com \
    --cc=44726@debbugs.gnu.org \
    --cc=akrl@sdf.org \
    /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.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.