[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: ns build symlinks all libexec programs into bin directory
From: |
Jan Djärv |
Subject: |
Re: ns build symlinks all libexec programs into bin directory |
Date: |
Sun, 13 May 2012 08:27:58 +0200 |
Hello.
12 maj 2012 kl. 20:18 skrev Glenn Morris:
>
> Why does a --with-ns build do this (in install-arch-dep):
>
> cd nextstep/Emacs.app/bin
> ls -l
> hexl -> ../libexec/hexl
> movemail -> ../libexec/movemail
> profile -> ../libexec/profile
> rcs2log -> ../libexec/rcs2log
> update-game-score -> ../libexec/update-game-score
> vcdiff -> ../libexec/vcdiff
>
> Ie, create symlinks to the libexec programs in the bin directory?
>
> These programs are supposed to be for internal Emacs use only, which is
> why they get installed in libexec in the first place.
Short answer: So Emacs can find them :-)
Long answer:
The path to libexec is in PATH_EXEC epaths.h from epaths.in and then added to
exec-path.
epaths.h is created at make time by the top level Makefile.
make install for --with-ns installs to nextstep/Emacs.app in the emacs tree.
Emacs.app can then be copied to its final place, which can be anywhere or
another machine.
Thus, PATH_EXEC points to libexec in nextstep/Emacs.app, but when Emacs.app is
installed (say on another machine), that values is not valid. Hence the links
into bin as bin is in exec-path (derived from invocation directory and not by
a compile time constant).
The idea is that Emacs.app is self contained and can be relocated anywhere as
is how app-bundles are supposed to work. A more intelligent search for libexec
would also solve it. For NS we know it is in the same place as bin, so we
could just add libexec to exe-path the same way as bin. But I guess nobody
thought of this as a problem.
Jan D.