unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
* bug#27686: emacs-ess: Not installed in "${output}/share/emacs/site-lisp/guix.d"
@ 2017-07-13 12:20 Adonay Felipe Nogueira
  2017-07-18 13:52 ` Alex Kost
  0 siblings, 1 reply; 6+ messages in thread
From: Adonay Felipe Nogueira @ 2017-07-13 12:20 UTC (permalink / raw)
  To: 27686

It seems that Emacs ESS mode isn't installed in the same location as
other packages are.

Also note that emacs-ess doesn't use the Emacs build system. I don't
know if this is indeed the issue (and if we can force it to use such
build system), but I think this is an important note to make.

The user's profile does include the ESS files, but they are scattered in
"${GUIX_PROFILE}/share".

-- 
- [[https://libreplanet.org/wiki/User:Adfeno]]
- Palestrante e consultor sobre /software/ livre (não confundir com
  gratis).
- "WhatsApp"? Ele não é livre, por isso não uso. Iguais a ele prefiro
  GNU Ring, ou Tox. Quer outras formas de contato? Adicione o vCard
  que está no endereço acima aos teus contatos.
- Pretende me enviar arquivos .doc, .ppt, .cdr, ou .mp3? OK, eu
  aceito, mas não repasso. Entrego apenas em formatos favoráveis ao
  /software/ livre. Favor entrar em contato em caso de dúvida.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#27686: emacs-ess: Not installed in "${output}/share/emacs/site-lisp/guix.d"
  2017-07-13 12:20 bug#27686: emacs-ess: Not installed in "${output}/share/emacs/site-lisp/guix.d" Adonay Felipe Nogueira
@ 2017-07-18 13:52 ` Alex Kost
  2017-07-29 20:34   ` Alex Kost
                     ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Alex Kost @ 2017-07-18 13:52 UTC (permalink / raw)
  To: Adonay Felipe Nogueira; +Cc: 27686

[-- Attachment #1: Type: text/plain, Size: 1067 bytes --]

Adonay Felipe Nogueira (2017-07-13 09:20 -0300) wrote:

> It seems that Emacs ESS mode isn't installed in the same location as
> other packages are.
>
> Also note that emacs-ess doesn't use the Emacs build system. I don't
> know if this is indeed the issue (and if we can force it to use such
> build system), but I think this is an important note to make.

It's not a problem: we just need to install *.el files in
".../share/emacs/site-lisp/guix.d/ess" instead of
".../share/emacs/site-lisp/ess" as it is done by default.  The attached
patch should fix it.

A side note: this is one of the reasons why I don't like "guix.d"
sub-directory.  I think it is a useless extra level in the file
hierarchy.  If we used:

  .../share/emacs/site-lisp/<package>

instead of the current choice:

  .../share/emacs/site-lisp/guix.d/<package>

there would be no need to adjust 'emacs-ess', 'magit' and probably some
other packages to install *.el in "guix.d".  But this is for another
discussion :-), sorry:

  http://lists.gnu.org/archive/html/guix-devel/2016-05/msg00241.html


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-gnu-emacs-ess-Install-elisp-files-in-guix.d.patch --]
[-- Type: text/x-patch, Size: 1252 bytes --]

From 2b36a9a5de44d162b39b351c49ec2f35c8cab880 Mon Sep 17 00:00:00 2001
From: Alex Kost <alezost@gmail.com>
Date: Tue, 18 Jul 2017 16:44:22 +0300
Subject: [PATCH] gnu: emacs-ess: Install elisp files in "guix.d".

Fixes <http://bugs.gnu.org/27686>.
Reported by Adonay Felipe Nogueira <adfeno@openmailbox.org>

* gnu/packages/emacs.scm (emacs-ess)[arguments]: Add LISPDIR to make
flags to install *.el files into "guix.d" sub-directory.
---
 gnu/packages/emacs.scm | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 75122af8b..a4cf5afcb 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -3105,7 +3105,9 @@ E-Prime forbids the use of the \"to be\" form to strengthen your writing.")
     (build-system gnu-build-system)
     (arguments
      `(#:tests? #f ; There is no test suite.
-       #:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
+       #:make-flags (list (string-append "PREFIX=" %output)
+                          (string-append "LISPDIR=" %output
+                                         "/share/emacs/site-lisp/guix.d/ess"))
        #:phases
        (modify-phases %standard-phases
          (delete 'configure)
-- 
2.13.2


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* bug#27686: emacs-ess: Not installed in "${output}/share/emacs/site-lisp/guix.d"
  2017-07-18 13:52 ` Alex Kost
@ 2017-07-29 20:34   ` Alex Kost
  2017-08-15 14:38   ` Adonay Felipe Nogueira
  2017-08-15 16:08   ` Maxim Cournoyer
  2 siblings, 0 replies; 6+ messages in thread
From: Alex Kost @ 2017-07-29 20:34 UTC (permalink / raw)
  To: Adonay Felipe Nogueira; +Cc: 27686-done

Alex Kost (2017-07-18 16:52 +0300) wrote:

> Adonay Felipe Nogueira (2017-07-13 09:20 -0300) wrote:
>
>> It seems that Emacs ESS mode isn't installed in the same location as
>> other packages are.
>>
>> Also note that emacs-ess doesn't use the Emacs build system. I don't
>> know if this is indeed the issue (and if we can force it to use such
>> build system), but I think this is an important note to make.
>
> It's not a problem: we just need to install *.el files in
> ".../share/emacs/site-lisp/guix.d/ess" instead of
> ".../share/emacs/site-lisp/ess" as it is done by default.  The attached
> patch should fix it.

[...]
> From 2b36a9a5de44d162b39b351c49ec2f35c8cab880 Mon Sep 17 00:00:00 2001
> From: Alex Kost <alezost@gmail.com>
> Date: Tue, 18 Jul 2017 16:44:22 +0300
> Subject: [PATCH] gnu: emacs-ess: Install elisp files in "guix.d".
>
> Fixes <http://bugs.gnu.org/27686>.
> Reported by Adonay Felipe Nogueira <adfeno@openmailbox.org>
>
> * gnu/packages/emacs.scm (emacs-ess)[arguments]: Add LISPDIR to make
> flags to install *.el files into "guix.d" sub-directory.

Since there were no other comments, I committed this patch¹.  So ESS
elisp directory should be found in Emacs 'load-path' now.

¹ http://git.savannah.gnu.org/cgit/guix.git/commit/?id=b1a6a7068401785fbcc1f5e9df677bc57691674f

-- 
Alex

^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#27686: emacs-ess: Not installed in "${output}/share/emacs/site-lisp/guix.d"
  2017-07-18 13:52 ` Alex Kost
  2017-07-29 20:34   ` Alex Kost
@ 2017-08-15 14:38   ` Adonay Felipe Nogueira
  2017-08-15 16:08   ` Maxim Cournoyer
  2 siblings, 0 replies; 6+ messages in thread
From: Adonay Felipe Nogueira @ 2017-08-15 14:38 UTC (permalink / raw)
  To: Alex Kost; +Cc: 27686

Indeed, I also wonder if the "guix.d" directory is a good idea to keep
or not.

Thank you very much for the fix too. :)

-- 
- [[https://libreplanet.org/wiki/User:Adfeno]]
- Palestrante e consultor sobre /software/ livre (não confundir com
  gratis).
- "WhatsApp"? Ele não é livre. Por favor, use o GNU Ring ou o Tox.
- Contato: [[https://libreplanet.org/wiki/User:Adfeno#vCard]]
- Arquivos comuns aceitos (apenas sem DRM): Corel Draw, Microsoft
  Office, MP3, MP4, WMA, WMV.
- Arquivos comuns aceitos e enviados: CSV, GNU Dia, GNU Emacs Org, GNU
  GIMP, Inkscape SVG, JPG, LibreOffice (padrão ODF), OGG, OPUS, PDF
  (apenas sem DRM), PNG, TXT, WEBM.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#27686: emacs-ess: Not installed in "${output}/share/emacs/site-lisp/guix.d"
  2017-07-18 13:52 ` Alex Kost
  2017-07-29 20:34   ` Alex Kost
  2017-08-15 14:38   ` Adonay Felipe Nogueira
@ 2017-08-15 16:08   ` Maxim Cournoyer
  2017-08-19 18:32     ` Alex Kost
  2 siblings, 1 reply; 6+ messages in thread
From: Maxim Cournoyer @ 2017-08-15 16:08 UTC (permalink / raw)
  To: Alex Kost; +Cc: 27686, Adonay Felipe Nogueira

[-- Attachment #1: Type: text/plain, Size: 1752 bytes --]

Hi,

On Tue, Jul 18, 2017 at 9:52 AM, Alex Kost <alezost@gmail.com> wrote:

> Adonay Felipe Nogueira (2017-07-13 09:20 -0300) wrote:
>
> > It seems that Emacs ESS mode isn't installed in the same location as
> > other packages are.
> >
> > Also note that emacs-ess doesn't use the Emacs build system. I don't
> > know if this is indeed the issue (and if we can force it to use such
> > build system), but I think this is an important note to make.
>
> It's not a problem: we just need to install *.el files in
> ".../share/emacs/site-lisp/guix.d/ess" instead of
> ".../share/emacs/site-lisp/ess" as it is done by default.  The attached
> patch should fix it.
>
> A side note: this is one of the reasons why I don't like "guix.d"
> sub-directory.  I think it is a useless extra level in the file
> hierarchy.  If we used:
>
>   .../share/emacs/site-lisp/<package>
>

While I agree that packaging elisp files in their own folder is cleaner, it
also introduces some complexity such as the requirement to add some glue
code in the Emacs site-start.el for packages discovery. This mechanism is
only valid when working with a profile; at build time (say, you want to run
tests which depend on other Emacs packages), another hack is required +
manual fiddling.

By contrast, if all of our Emacs packages were laid out flat under the
usual share/emacs/site-lisp/ like it's done on other distributions, we
could simply define the EMACSLOADPATH `search-path' at the Emacs package
definition level, and the rest would be taken care of by Guix native
mechanisms (no hacks required).

IMHO, this would be more "Guixy".

Alternatively, we would need to extend the seacrh-path facility to be able
to deal with our own added complexity. I'm not sure if it's worth it.

[-- Attachment #2: Type: text/html, Size: 2338 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#27686: emacs-ess: Not installed in "${output}/share/emacs/site-lisp/guix.d"
  2017-08-15 16:08   ` Maxim Cournoyer
@ 2017-08-19 18:32     ` Alex Kost
  0 siblings, 0 replies; 6+ messages in thread
From: Alex Kost @ 2017-08-19 18:32 UTC (permalink / raw)
  To: Maxim Cournoyer; +Cc: 27686

Maxim Cournoyer (2017-08-15 12:08 -0400) wrote:

> On Tue, Jul 18, 2017 at 9:52 AM, Alex Kost <alezost@gmail.com> wrote:
[...]
>     A side note: this is one of the reasons why I don't like "guix.d"
>     sub-directory.  I think it is a useless extra level in the file
>     hierarchy.  If we used:
>
>       .../share/emacs/site-lisp/<package>
>
> While I agree that packaging elisp files in their own folder is
> cleaner, it also introduces some complexity such as the requirement
> to add some glue code in the Emacs site-start.el for packages
> discovery.
>
> This mechanism is only valid when working with a profile;
> at build time (say, you want to run tests which depend on other Emacs
> packages), another hack is required + manual fiddling.
>
> By contrast, if all of our Emacs packages were laid out flat under
> the usual share/emacs/site-lisp/ like it's done on other
> distributions,

I wonder how many emacs packages these distributions provide and whether
they have any name conflicts in "site-lisp" or not.

> we could simply define the EMACSLOADPATH `search-path'
> at the Emacs package definition level, and the rest would be taken
> care of by Guix native mechanisms (no hacks required).
>
> IMHO, this would be more "Guixy".

The only problem with this flat structure I see is the potential name
conflicts.  Federico (the author of the 'emacs-build-system') explained
it here:

  http://lists.gnu.org/archive/html/guix-devel/2015-06/msg00398.html

Although emacs-build-system removes such files as README or .gitignore
nowadays, name conflicts are still possible, especially for "complex"
emacs packages that provide additional non-elisp files, often placed in
sub-directories.  For example, 'emacs-slime' provides 'lib' and
'contrib' subdirs.  There may be other packages that have dirs with the
same names, and since there are thousands of Emacs packages out there,
name conflicts are possible in this case.

Otherwise, I agree that flat structure is much easier to use and handle.

> Alternatively, we would need to extend the seacrh-path facility to be
> able to deal with our own added complexity. I'm not sure if it's
> worth it.

-- 
Alex

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2017-08-19 18:33 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-13 12:20 bug#27686: emacs-ess: Not installed in "${output}/share/emacs/site-lisp/guix.d" Adonay Felipe Nogueira
2017-07-18 13:52 ` Alex Kost
2017-07-29 20:34   ` Alex Kost
2017-08-15 14:38   ` Adonay Felipe Nogueira
2017-08-15 16:08   ` Maxim Cournoyer
2017-08-19 18:32     ` Alex Kost

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

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).