[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Should directory of unvompiled elisp file be added to load-path



Peter S Galbraith <p.galbraith@globetrotter.net> writes:

> Hi all,
>
> I wondering about load-path bloat and whether it matters.
>
> http://bugs.debian.org/189754 said that when help was listed about a
> function of mine, the user couldn't click on the function name to move
> point to the source code.
>
> That's because I add the compiled lisp directory to to load-path, but
> not the directory of the sources themselves.
>
> e.g.
>   (debian-pkg-add-load-path-item
>    (concat "/usr/share/" (symbol-name flavor) "/site-lisp/dpkg-dev-el"))
> but not
>   (debian-pkg-add-load-path-item "/usr/share/emacs/site-lisp/dpkg-dev-el")
>
> Is it worth adding it for that purpose?
> Or it it bloat?

In theory, you could ship the *.el in a dpkg-dev-el-doc package, but I
assume it isn't a large file so it would be bloat.

IMHO documentation is important.  Only installing *.elc is like
installing software without info manual or man pages.

Perhaps you don't need to byte compile the package?  Few elisp
packages really need it, and doing things this way would fix the
problem.  Compare the 'idn' package, it simply put files in
/usr/share/emacs/site-lisp/.  It also make Emacs generate better
debugging information, should users ever encounter a bug.  And it
doesn't bloat load-path.

You could also consider using autoload instead of bloating load-path
at all, although I'm not sure if Emacs is smart enough to locate
documentation this way.  If not, it should probably be regarded as a
bug, and reported.  If you need to byte compile the file, this is
probably the best solution.

Thanks for thinking about this issue, it appears to me that if more
emacs debian packages was modified in a similar spirit, the debian
emacs startup time wouldn't be prohibiting.



Reply to: