* [bug#63987] [PATCH] gnu: Add emacs-jinx.
@ 2023-06-09 23:00 mekeor
2023-06-18 11:34 ` [bug#63987] Should jinx-mod.so be installed into /.../lib or into /.../share/emacs/site-lisp/...? Mekeor Melire
` (3 more replies)
0 siblings, 4 replies; 9+ messages in thread
From: mekeor @ 2023-06-09 23:00 UTC (permalink / raw)
To: 63987
* gnu/packages/emacs-xyz.scm (emacs-jinx): New variable.
---
Hello Guix! I have some questions about this patch that I'm submitting:
- emacs-jinx needs gcc at build time. Should I use gcc-toolchain (or
rather the internal gcc) package?
- When using the module (gnu packages commencement), I first got the
following warning. That's why I decided to use it with a prefix
instead. What do you think about that?
WARNING: (gnu packages emacs-xyz): `canonical-package' imported from
both (gnu packages base) and (gnu packages commencement)
- I did not introduce any (revision "0") variable or so. I hope that's
okay. I'm not sure when to use it.
- I placed the package declaration right after other spelling related
Emacs packages. Unfortunately, the declaration of emacs-jit-spell is
not close. I could send another additional patch that moves all
spelling-related Emacs packages into an own section, if you'd like.
Like this:
;;;
;;; Spelling
;;;
Anyways. Cheers!
gnu/packages/emacs-xyz.scm | 73 ++++++++++++++++++++++++++++++++++++++
1 file changed, 73 insertions(+)
diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index 0ea9732bfa..7e4f1a1fea 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -148,6 +148,7 @@
(define-module (gnu packages emacs-xyz)
#:use-module ((guix licenses) #:prefix license:)
+ #:use-module ((gnu packages commencement) #:prefix commencement:)
#:use-module (guix packages)
#:use-module (guix cvs-download)
#:use-module (guix download)
@@ -265,6 +266,7 @@ (define-module (gnu packages emacs-xyz)
#:use-module (gnu packages virtualization)
#:use-module (gnu packages web-browsers)
#:use-module (gnu packages wget)
+ #:use-module (gnu packages enchant)
#:use-module (guix utils)
#:use-module (srfi srfi-1)
#:use-module (ice-9 match))
@@ -31922,6 +31924,77 @@ (define-public emacs-spell-fu
that runs from the syntax highlighter without starting external processes.")
(license license:gpl3+))))
+(define-public emacs-jinx
+ (package
+ (name "emacs-jinx")
+ (version "0.8")
+ (source
+ (origin
+ (method git-fetch)
+ (uri
+ (git-reference
+ (url "https://github.com/minad/jinx")
+ (commit "7fced90fdaca5a482cd08b80967e0eac5ee8d885")))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1y097rnf9zg26jf4vh74a0laddfp4x6pp1fjqs3xqgwc0cmdq59w"))))
+ (build-system emacs-build-system)
+ (propagated-inputs (list emacs-compat))
+ (native-inputs
+ (list
+ emacs-compat
+ enchant
+ commencement:gcc-toolchain
+ pkg-config
+ texinfo))
+ (inputs (list enchant))
+ (arguments
+ (list
+ #:phases
+ #~(modify-phases %standard-phases
+ ;; Compile the accompanying jinx-mod.c file with Emacs and
+ ;; jinx.el. This needs to happen after expand-load-path phase so
+ ;; that jinx.el is able to load emacs-compat.
+ (add-after 'expand-load-path 'compile-jinx-mod-c
+ (lambda _
+ (invoke
+ "emacs" "--batch" "-L" "."
+ "-l" "jinx.el"
+ "-f" "jinx--load-module")
+ (install-file "jinx-mod.so"
+ (string-append #$output "/lib"))))
+ ;; Patch Jinx.el to load the previously compiled jinx-mod.so from
+ ;; correct output path instead of attempting to compile it.
+ (add-after 'compile-jinx-mod-c 'use-compiled-jinx-mod-so
+ (lambda _
+ (let ((file "jinx.el"))
+ (make-file-writable file)
+ (emacs-substitute-sexps file
+ ("\"Compile and load dynamic module.\""
+ `(module-load
+ ,(string-append #$output "/lib/jinx-mod.so")))))))
+ (add-after 'install 'makeinfo
+ (lambda _
+ (invoke "emacs" "--batch"
+ "--eval=(require 'ox-texinfo)"
+ "--eval=(find-file \"README.org\")"
+ "--eval=(org-texinfo-export-to-info)")
+ (install-file "jinx.info"
+ (string-append #$output "/share/info")))))))
+ (home-page "https://github.com/minad/jinx")
+ (synopsis "Emacs Enchanted Spell Checker")
+ (description
+ "Jinx is a fast just-in-time spell-checker for Emacs. Jinx highlights
+misspelled words in the text of the visible portion of the buffer. For
+efficiency, Jinx highlights misspellings lazily, recognizes window boundaries
+and text folding, if any. For example, when unfolding or scrolling, only the
+newly visible part of the text is checked if it has not been checked before.
+Each misspelling can be corrected from a list of dictionary words presented as
+a completion menu. Jinx's high performance and low resource usage comes from
+directly calling the widely-used API of the Enchant library.")
+ (license license:gpl3+)))
+
(define-public emacs-org-emms
(let ((commit "07a8917f3d628c32e5de1dbd118ac08203772533")
(revision "1"))
base-commit: 297ba5c15a32845ab8514aeb6f405ebd4290142d
--
2.39.2
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [bug#63987] Should jinx-mod.so be installed into /.../lib or into /.../share/emacs/site-lisp/...?
2023-06-09 23:00 [bug#63987] [PATCH] gnu: Add emacs-jinx mekeor
@ 2023-06-18 11:34 ` Mekeor Melire
2023-06-18 11:56 ` Liliana Marie Prikler
2023-06-18 12:14 ` [bug#63987] [PATCH] gnu: Add emacs-jinx Liliana Marie Prikler
` (2 subsequent siblings)
3 siblings, 1 reply; 9+ messages in thread
From: Mekeor Melire @ 2023-06-18 11:34 UTC (permalink / raw)
To: 63987; +Cc: Liliana Marie Prikler
Hello Guix,
my previous patch added a package definition for emacs-jinx. The package definition works by installing the accompanying jinx-mod.so into the package's $out/lib directory, and patching jinx.el so that it loads that library from the correct path.
The maintainer of the Emacs package suggests to rather install jinx-mod.so into $out/share/emacs/site-lisp/jinx-.../ instead, i.e. right next to the .el-files: https://github.com/minad/jinx/issues/86#issuecomment-1596102645
What do you think?
^ permalink raw reply [flat|nested] 9+ messages in thread
* [bug#63987] Should jinx-mod.so be installed into /.../lib or into /.../share/emacs/site-lisp/...?
2023-06-18 11:34 ` [bug#63987] Should jinx-mod.so be installed into /.../lib or into /.../share/emacs/site-lisp/...? Mekeor Melire
@ 2023-06-18 11:56 ` Liliana Marie Prikler
2023-06-20 22:04 ` Mekeor Melire
0 siblings, 1 reply; 9+ messages in thread
From: Liliana Marie Prikler @ 2023-06-18 11:56 UTC (permalink / raw)
To: Mekeor Melire, 63987
Hi Mekeor,
Am Sonntag, dem 18.06.2023 um 11:34 +0000 schrieb Mekeor Melire:
> Hello Guix,
>
> my previous patch added a package definition for emacs-jinx. The
> package definition works by installing the accompanying jinx-mod.so
> into the package's $out/lib directory, and patching jinx.el so that
> it loads that library from the correct path.
>
> The maintainer of the Emacs package suggests to rather install jinx-
> mod.so into $out/share/emacs/site-lisp/jinx-.../ instead, i.e. right
> next to the .el-files:
> https://github.com/minad/jinx/issues/86#issuecomment-1596102645
>
> What do you think?
The way you did it SGTM. If you fear that it might shadow other shared
libraries (probably an unnecessary fear, but who knows?), you could use
lib/emacs instead. Other comments will come in a separate reply to
your first mail.
Stay tuned!
^ permalink raw reply [flat|nested] 9+ messages in thread
* [bug#63987] [PATCH] gnu: Add emacs-jinx.
2023-06-09 23:00 [bug#63987] [PATCH] gnu: Add emacs-jinx mekeor
2023-06-18 11:34 ` [bug#63987] Should jinx-mod.so be installed into /.../lib or into /.../share/emacs/site-lisp/...? Mekeor Melire
@ 2023-06-18 12:14 ` Liliana Marie Prikler
2023-06-18 23:02 ` [bug#63987] [PATCH v2] " Mekeor Melire
2023-06-18 23:17 ` [bug#63987] [PATCH v3] " Mekeor Melire
3 siblings, 0 replies; 9+ messages in thread
From: Liliana Marie Prikler @ 2023-06-18 12:14 UTC (permalink / raw)
To: mekeor, 63987
Am Freitag, dem 09.06.2023 um 23:00 +0000 schrieb mekeor@posteo.de:
> * gnu/packages/emacs-xyz.scm (emacs-jinx): New variable.
> ---
> Hello Guix! I have some questions about this patch that I'm
> submitting:
>
> - emacs-jinx needs gcc at build time. Should I use gcc-toolchain (or
> rather the internal gcc) package?
Regular GCC ought to suffice. I'm not sure why it isn't an implicit
input of emacs-build-system, but you get what you code for.
> - When using the module (gnu packages commencement), I first got the
> following warning. That's why I decided to use it with a prefix
> instead. What do you think about that?
>
> WARNING: (gnu packages emacs-xyz): `canonical-package' imported
> from
> both (gnu packages base) and (gnu packages commencement)
>
> - I did not introduce any (revision "0") variable or so. I hope
> that's
> okay. I'm not sure when to use it.
I personally only find that okay when using tagged releases, but
there's different opinions on that and slightly varying styles
throughout the code base. I'd prefer it if you used the
(commit (f version))
pattern, where f is some transformation – including (commit version).
> - I placed the package declaration right after other spelling related
> Emacs packages. Unfortunately, the declaration of emacs-jit-spell
> is
> not close. I could send another additional patch that moves all
> spelling-related Emacs packages into an own section, if you'd like.
> Like this:
Sorting-wise, why not place it right before emacs-jit-spell?
jinx < jit.
> ;;;
> ;;; Spelling
> ;;;
>
> Anyways. Cheers!
>
> gnu/packages/emacs-xyz.scm | 73
> ++++++++++++++++++++++++++++++++++++++
> 1 file changed, 73 insertions(+)
>
> diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
> index 0ea9732bfa..7e4f1a1fea 100644
> --- a/gnu/packages/emacs-xyz.scm
> +++ b/gnu/packages/emacs-xyz.scm
> @@ -148,6 +148,7 @@
>
> (define-module (gnu packages emacs-xyz)
> #:use-module ((guix licenses) #:prefix license:)
> + #:use-module ((gnu packages commencement) #:prefix commencement:)
> #:use-module (guix packages)
> #:use-module (guix cvs-download)
> #:use-module (guix download)
> @@ -265,6 +266,7 @@ (define-module (gnu packages emacs-xyz)
> #:use-module (gnu packages virtualization)
> #:use-module (gnu packages web-browsers)
> #:use-module (gnu packages wget)
> + #:use-module (gnu packages enchant)
> #:use-module (guix utils)
> #:use-module (srfi srfi-1)
> #:use-module (ice-9 match))
> @@ -31922,6 +31924,77 @@ (define-public emacs-spell-fu
> that runs from the syntax highlighter without starting external
> processes.")
> (license license:gpl3+))))
>
> +(define-public emacs-jinx
> + (package
> + (name "emacs-jinx")
> + (version "0.8")
> + (source
> + (origin
> + (method git-fetch)
> + (uri
> + (git-reference
> + (url "https://github.com/minad/jinx")
> + (commit "7fced90fdaca5a482cd08b80967e0eac5ee8d885")))
> + (file-name (git-file-name name version))
> + (sha256
> + (base32
> +
> "1y097rnf9zg26jf4vh74a0laddfp4x6pp1fjqs3xqgwc0cmdq59w"))))
> + (build-system emacs-build-system)
> + (propagated-inputs (list emacs-compat))
> + (native-inputs
> + (list
> + emacs-compat
> + enchant
> + commencement:gcc-toolchain
> + pkg-config
> + texinfo))
> + (inputs (list enchant))
> + (arguments
> + (list
> + #:phases
> + #~(modify-phases %standard-phases
> + ;; Compile the accompanying jinx-mod.c file with Emacs
> and
> + ;; jinx.el. This needs to happen after expand-load-path
> phase so
> + ;; that jinx.el is able to load emacs-compat.
> + (add-after 'expand-load-path 'compile-jinx-mod-c
> + (lambda _
> + (invoke
> + "emacs" "--batch" "-L" "."
> + "-l" "jinx.el"
> + "-f" "jinx--load-module")
> + (install-file "jinx-mod.so"
> + (string-append #$output "/lib"))))
The install-file ought to go in it's own phase, imho.
> + ;; Patch Jinx.el to load the previously compiled jinx-
> mod.so from
> + ;; correct output path instead of attempting to compile
> it.
> + (add-after 'compile-jinx-mod-c 'use-compiled-jinx-mod-so
> + (lambda _
> + (let ((file "jinx.el"))
> + (make-file-writable file)
> + (emacs-substitute-sexps file
> + ("\"Compile and load dynamic module.\""
> + `(module-load
> + ,(string-append #$output "/lib/jinx-
> mod.so")))))))
You might want to use a patch instead if a simple substitute-sexps.
> + (add-after 'install 'makeinfo
> + (lambda _
> + (invoke "emacs" "--batch"
> + "--eval=(require 'ox-texinfo)"
> + "--eval=(find-file \"README.org\")"
> + "--eval=(org-texinfo-export-to-info)")
> + (install-file "jinx.info"
> + (string-append #$output "/share/info")))))))
Again, split build and install.
> + (home-page "https://github.com/minad/jinx")
> + (synopsis "Emacs Enchanted Spell Checker")
> + (description
> + "Jinx is a fast just-in-time spell-checker for Emacs. Jinx
> highlights
> +misspelled words in the text of the visible portion of the buffer.
> For
> +efficiency, Jinx highlights misspellings lazily, recognizes window
> boundaries
> +and text folding, if any.
"Jinx highlights misspellings lazily and honours window boundaries as
well as potential text foldings."
> For example, when unfolding or scrolling, only the
> +newly visible part of the text is checked if it has not been checked
> before.
This is somewhat gratuitous information, leave it out :)
> +Each misspelling can be corrected from a list of dictionary words
> presented as
> +a completion menu.
That's something you'd expect, leave it.
> Jinx's high performance and low resource usage comes from
> +directly calling the widely-used API of the Enchant library.")
Maybe mention this in the first sentence instead of making it the last:
"Jinx is a just-in-time spell-checker for Emacs based on the Enchant
library."
Cheers
^ permalink raw reply [flat|nested] 9+ messages in thread
* [bug#63987] [PATCH v2] gnu: Add emacs-jinx.
2023-06-09 23:00 [bug#63987] [PATCH] gnu: Add emacs-jinx mekeor
2023-06-18 11:34 ` [bug#63987] Should jinx-mod.so be installed into /.../lib or into /.../share/emacs/site-lisp/...? Mekeor Melire
2023-06-18 12:14 ` [bug#63987] [PATCH] gnu: Add emacs-jinx Liliana Marie Prikler
@ 2023-06-18 23:02 ` Mekeor Melire
2023-06-18 23:17 ` [bug#63987] [PATCH v3] " Mekeor Melire
3 siblings, 0 replies; 9+ messages in thread
From: Mekeor Melire @ 2023-06-18 23:02 UTC (permalink / raw)
To: 63987
* gnu/packages/emacs-xyz.scm (emacs-jinx): New variable.
---
Some (but not all) changes in this patch version:
1. The patch still installs jinx-mod.so into $output/lib.
2. The patch does not import (gnu packages commencement) anymore.
3. The patch does not use (let ((commit ...) (revision ...)) ...) anymore.
4. The patch now adds emacs-jinx right before emacs-jit-spell.
5. The patch now splits phases of installation and build of documentation and jinx-mod.
6. The patch now uses a more concise package description.
gnu/packages/emacs-xyz.scm | 60
++++++++++++++++++++++++++++++++++++++
1 file changed, 60 insertions(+)
diff --git a/gnu/packages/emacs-xyz.scm
b/gnu/packages/emacs-xyz.scm
index 24a4ae169e..574fd4cfca 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -177,6 +177,7 @@ (define-module (gnu packages emacs-xyz)
#:use-module (gnu packages djvu)
#:use-module (gnu packages ebook)
#:use-module (gnu packages emacs)
+ #:use-module (gnu packages enchant)
#:use-module (gnu packages fonts)
#:use-module (gnu packages freedesktop)
#:use-module (gnu packages games)
@@ -10010,6 +10011,65 @@ (define-public emacs-jinja2-mode
sgml/html integration, and indentation (working with sgml).")
(license license:gpl3+)))
+(define-public emacs-jinx
+ (package
+ (name "emacs-jinx")
+ (version "0.8")
+ (source
+ (origin
+ (method git-fetch)
+ (uri
+ (git-reference
+ (url "https://github.com/minad/jinx")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+
"1y097rnf9zg26jf4vh74a0laddfp4x6pp1fjqs3xqgwc0cmdq59w"))))
+ (build-system emacs-build-system)
+ (propagated-inputs (list emacs-compat))
+ (native-inputs (list emacs-compat enchant pkg-config
texinfo))
+ (inputs (list enchant))
+ (arguments
+ (list
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-before 'install 'build-jinx-mod
+ (lambda* _
+ (invoke
+ "emacs" "--batch" "-L" "."
+ "-l" "jinx.el"
+ "-f" "jinx--load-module")))
+ (add-before 'install 'patch-path-to-jinx-mod
+ (lambda _
+ (let ((file "jinx.el"))
+ (make-file-writable file)
+ (emacs-substitute-sexps file
+ ("\"Compile and load dynamic module.\""
+ `(module-load
+ ,(string-append #$output
"/lib/jinx-mod.so")))))))
+ (add-before 'install 'build-info
+ (lambda _
+ (invoke "emacs" "--batch"
+ "--eval=(require 'ox-texinfo)"
+ "--eval=(find-file \"README.org\")"
+ "--eval=(org-texinfo-export-to-info)")))
+ (add-after 'install 'install-jinx-mod
+ (lambda _
+ (install-file "jinx-mod.so"
+ (string-append #$output "/lib"))))
+ (add-after 'install 'install-info
+ (lambda _
+ (install-file "jinx.info"
+ (string-append #$output "/share/info")))))))
+ (home-page "https://github.com/minad/jinx")
+ (synopsis "Emacs Enchanted Spell Checker")
+ (description "Jinx is a just-in-time spell-checker for Emacs
based on the
+Enchant library. It lazily highlights misspelled words in the
text of the
+visible portion of the buffer by honouring window boundaries as
well as text
+folding, if any.")
+ (license license:gpl3+)))
+
(define-public emacs-jit-spell
(package
(name "emacs-jit-spell")
--
2.39.2
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [bug#63987] [PATCH v3] gnu: Add emacs-jinx.
2023-06-09 23:00 [bug#63987] [PATCH] gnu: Add emacs-jinx mekeor
` (2 preceding siblings ...)
2023-06-18 23:02 ` [bug#63987] [PATCH v2] " Mekeor Melire
@ 2023-06-18 23:17 ` Mekeor Melire
2023-09-09 10:30 ` bug#63987: " Liliana Marie Prikler
3 siblings, 1 reply; 9+ messages in thread
From: Mekeor Melire @ 2023-06-18 23:17 UTC (permalink / raw)
To: 63987
* gnu/packages/emacs-xyz.scm (emacs-jinx): New variable.
---
Sorry. Here's another edit that makes the order of phases more comprehensible.
gnu/packages/emacs-xyz.scm | 60
++++++++++++++++++++++++++++++++++++++
1 file changed, 60 insertions(+)
diff --git a/gnu/packages/emacs-xyz.scm
b/gnu/packages/emacs-xyz.scm
index 24a4ae169e..dcefa0475e 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -177,6 +177,7 @@ (define-module (gnu packages emacs-xyz)
#:use-module (gnu packages djvu)
#:use-module (gnu packages ebook)
#:use-module (gnu packages emacs)
+ #:use-module (gnu packages enchant)
#:use-module (gnu packages fonts)
#:use-module (gnu packages freedesktop)
#:use-module (gnu packages games)
@@ -10010,6 +10011,65 @@ (define-public emacs-jinja2-mode
sgml/html integration, and indentation (working with sgml).")
(license license:gpl3+)))
+(define-public emacs-jinx
+ (package
+ (name "emacs-jinx")
+ (version "0.8")
+ (source
+ (origin
+ (method git-fetch)
+ (uri
+ (git-reference
+ (url "https://github.com/minad/jinx")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+
"1y097rnf9zg26jf4vh74a0laddfp4x6pp1fjqs3xqgwc0cmdq59w"))))
+ (build-system emacs-build-system)
+ (propagated-inputs (list emacs-compat))
+ (native-inputs (list emacs-compat enchant pkg-config
texinfo))
+ (inputs (list enchant))
+ (arguments
+ (list
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-after 'expand-load-path 'build-jinx-mod
+ (lambda* _
+ (invoke
+ "emacs" "--batch" "-L" "."
+ "-l" "jinx.el"
+ "-f" "jinx--load-module")))
+ (add-after 'expand-load-path 'build-info
+ (lambda _
+ (invoke "emacs" "--batch"
+ "--eval=(require 'ox-texinfo)"
+ "--eval=(find-file \"README.org\")"
+ "--eval=(org-texinfo-export-to-info)")))
+ (add-after 'build-jinx-mod 'patch-path-to-jinx-mod
+ (lambda _
+ (let ((file "jinx.el"))
+ (make-file-writable file)
+ (emacs-substitute-sexps file
+ ("\"Compile and load dynamic module.\""
+ `(module-load
+ ,(string-append #$output
"/lib/jinx-mod.so")))))))
+ (add-after 'install 'install-jinx-mod
+ (lambda _
+ (install-file "jinx-mod.so"
+ (string-append #$output "/lib"))))
+ (add-after 'install 'install-info
+ (lambda _
+ (install-file "jinx.info"
+ (string-append #$output "/share/info")))))))
+ (home-page "https://github.com/minad/jinx")
+ (synopsis "Emacs Enchanted Spell Checker")
+ (description "Jinx is a just-in-time spell-checker for Emacs
based on the
+Enchant library. It lazily highlights misspelled words in the
text of the
+visible portion of the buffer by honouring window boundaries as
well as text
+folding, if any.")
+ (license license:gpl3+)))
+
(define-public emacs-jit-spell
(package
(name "emacs-jit-spell")
--
2.39.2
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [bug#63987] Should jinx-mod.so be installed into /.../lib or into /.../share/emacs/site-lisp/...?
2023-06-18 11:56 ` Liliana Marie Prikler
@ 2023-06-20 22:04 ` Mekeor Melire
2023-06-21 4:23 ` Liliana Marie Prikler
0 siblings, 1 reply; 9+ messages in thread
From: Mekeor Melire @ 2023-06-20 22:04 UTC (permalink / raw)
To: 63987; +Cc: liliana.prikler, mekeor
2023-06-18 13:56 liliana.prikler@gmail.com:
> Hi Mekeor,
>
> Am Sonntag, dem 18.06.2023 um 11:34 +0000 schrieb Mekeor Melire:
> > Hello Guix,
> >
> > my previous patch added a package definition for emacs-jinx.
> > The
> > package definition works by installing the accompanying
> > jinx-mod.so
> > into the package's $out/lib directory, and patching jinx.el so
> > that
> > it loads that library from the correct path.
> >
> > The maintainer of the Emacs package suggests to rather install
> > jinx-
> > mod.so into $out/share/emacs/site-lisp/jinx-.../ instead, i.e.
> > right
> > next to the .el-files:
> > https://github.com/minad/jinx/issues/86#issuecomment-1596102645
> >
> > What do you think?
> The way you did it SGTM. If you fear that it might shadow other
> shared
> libraries (probably an unnecessary fear, but who knows?), you
> could use
> lib/emacs instead. Other comments will come in a separate reply
> to
> your first mail.
>
> Stay tuned!
Daniel Mendler says: "My suggestion is that you put the library
file [jinx-mod.so] in some appropriate directory, which must be on
the load-path. I assume
that there exists some convention on Guix on where to install
native modules."
https://github.com/minad/jinx/issues/86#issuecomment-1597221252
And I think they are right. We should have a convention about where to install native modules (.so-files) and add that directory to Emacs' load-path.
One approach would be to use $out/lib/emacs (or a new subdirectory of it). E.g. we would install jinx-mod.so into that path and Guix would add it to the EMACSLOADPATH environment-variable. (Currently, Guix only makes use of .../lib/emacs/native-site-lisp which is added to EMACSNATIVELOADPATH environment-variable.)
Another approach would be to agree on installing *.so-files into $out/share/site-lisp/PACKAGE-VERSION/ so that it is already present Emacs' load-path as is.
What do you think?
^ permalink raw reply [flat|nested] 9+ messages in thread
* [bug#63987] Should jinx-mod.so be installed into /.../lib or into /.../share/emacs/site-lisp/...?
2023-06-20 22:04 ` Mekeor Melire
@ 2023-06-21 4:23 ` Liliana Marie Prikler
0 siblings, 0 replies; 9+ messages in thread
From: Liliana Marie Prikler @ 2023-06-21 4:23 UTC (permalink / raw)
To: Mekeor Melire, 63987
Am Dienstag, dem 20.06.2023 um 22:04 +0000 schrieb Mekeor Melire:
> Daniel Mendler says: "My suggestion is that you put the library
> file [jinx-mod.so] in some appropriate directory, which must be on
> the load-path. I assume that there exists some convention on Guix on
> where to install native modules."
> https://github.com/minad/jinx/issues/86#issuecomment-1597221252
>
> And I think they are right. We should have a convention about where
> to install native modules (.so-files) and add that directory to
> Emacs' load-path.
>
> One approach would be to use $out/lib/emacs (or a new subdirectory of
> it). E.g. we would install jinx-mod.so into that path and Guix would
> add it to the EMACSLOADPATH environment-variable. (Currently, Guix
> only makes use of .../lib/emacs/native-site-lisp which is added to
> EMACSNATIVELOADPATH environment-variable.)
What's the functional difference between EMACSLOADPATH and
EMACSNATIVELOADPATH here? Why would the latter not work?
> Another approach would be to agree on installing *.so-files into
> $out/share/site-lisp/PACKAGE-VERSION/ so that it is already present
> Emacs' load-path as is.
>
> What do you think?
/lib/emacs/native-site-lisp sounds like the wrong place regardless, as
does /share/site-lisp. Perhaps /lib/emacs/site-mod?
Cheers
^ permalink raw reply [flat|nested] 9+ messages in thread
* bug#63987: [PATCH v3] gnu: Add emacs-jinx.
2023-06-18 23:17 ` [bug#63987] [PATCH v3] " Mekeor Melire
@ 2023-09-09 10:30 ` Liliana Marie Prikler
0 siblings, 0 replies; 9+ messages in thread
From: Liliana Marie Prikler @ 2023-09-09 10:30 UTC (permalink / raw)
To: Mekeor Melire, 63987-done
Am Sonntag, dem 18.06.2023 um 23:17 +0000 schrieb Mekeor Melire:
> * gnu/packages/emacs-xyz.scm (emacs-jinx): New variable.
> ---
> Sorry. Here's another edit that makes the order of phases more
> comprehensible.
Pushed with the following changes:
1. jinx-mod.so is installed to lib/emacs
2. inputs etc. are put after arguments
I also had a bit of a trouble applying your patch because it seems your
MUA breaks it; please take care that no gratuitous line breaks are
inserted.
Cheers
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2023-09-09 10:32 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-06-09 23:00 [bug#63987] [PATCH] gnu: Add emacs-jinx mekeor
2023-06-18 11:34 ` [bug#63987] Should jinx-mod.so be installed into /.../lib or into /.../share/emacs/site-lisp/...? Mekeor Melire
2023-06-18 11:56 ` Liliana Marie Prikler
2023-06-20 22:04 ` Mekeor Melire
2023-06-21 4:23 ` Liliana Marie Prikler
2023-06-18 12:14 ` [bug#63987] [PATCH] gnu: Add emacs-jinx Liliana Marie Prikler
2023-06-18 23:02 ` [bug#63987] [PATCH v2] " Mekeor Melire
2023-06-18 23:17 ` [bug#63987] [PATCH v3] " Mekeor Melire
2023-09-09 10:30 ` bug#63987: " Liliana Marie Prikler
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).