summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArsen Arsenović <arsen@gentoo.org>2023-04-18 01:44:34 +0200
committerArsen Arsenović <arsen@gentoo.org>2023-04-18 02:22:01 +0200
commit423aa2c1b2a1e173c769cf847bb11ff112864f1e (patch)
tree9fa221795db4212488762190d09695f1a3e49201 /app-emacs
parentdev-util/poke: add 3.1 (diff)
downloadgentoo-423aa2c1b2a1e173c769cf847bb11ff112864f1e.tar.gz
gentoo-423aa2c1b2a1e173c769cf847bb11ff112864f1e.tar.bz2
gentoo-423aa2c1b2a1e173c769cf847bb11ff112864f1e.zip
app-emacs/jinx: new package, add 0.6
Signed-off-by: Arsen Arsenović <arsen@gentoo.org>
Diffstat (limited to 'app-emacs')
-rw-r--r--app-emacs/jinx/Manifest1
-rw-r--r--app-emacs/jinx/files/50jinx-gentoo.el4
-rw-r--r--app-emacs/jinx/files/jinx-0.6-try-load-path.patch32
-rw-r--r--app-emacs/jinx/jinx-0.6.ebuild44
-rw-r--r--app-emacs/jinx/metadata.xml19
5 files changed, 100 insertions, 0 deletions
diff --git a/app-emacs/jinx/Manifest b/app-emacs/jinx/Manifest
new file mode 100644
index 000000000000..cc55fa667dc7
--- /dev/null
+++ b/app-emacs/jinx/Manifest
@@ -0,0 +1 @@
+DIST jinx-0.6.tar.xz 16692 BLAKE2B 49a391b55b809dd6749ce264b4f732b5c902c1ea67a39e681327ddcf8f728271897202ecd282dc5c4999cf336a5b37c89b9863239291fc944cee352920d99189 SHA512 aa253836d04aec04674ca6dbbd1e73719bee78f4d01d4d93eef2cb05f4c3edc6ec4a11c352fb8952780523f187581fae9c33ea0d30416ec30803b7a196d03f60
diff --git a/app-emacs/jinx/files/50jinx-gentoo.el b/app-emacs/jinx/files/50jinx-gentoo.el
new file mode 100644
index 000000000000..35fde43c0137
--- /dev/null
+++ b/app-emacs/jinx/files/50jinx-gentoo.el
@@ -0,0 +1,4 @@
+;;; app-emacs/jinx site configuration -*- lexical-binding: t; -*-
+(add-to-list 'load-path "@SITELISP@")
+(add-to-list 'load-path "@EMACSMODULES@")
+(load "@SITELISP@/jinx-autoload.el" nil t)
diff --git a/app-emacs/jinx/files/jinx-0.6-try-load-path.patch b/app-emacs/jinx/files/jinx-0.6-try-load-path.patch
new file mode 100644
index 000000000000..5cb498015791
--- /dev/null
+++ b/app-emacs/jinx/files/jinx-0.6-try-load-path.patch
@@ -0,0 +1,32 @@
+From 3c0aa84130e07cf69219adce8a3494e76977fc26 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Arsen=20Arsenovi=C4=87?= <arsen@gentoo.org>
+Date: Tue, 18 Apr 2023 01:29:55 +0200
+Subject: [PATCH] Try searching the whole load-path for jinx-mod
+
+* jinx.el (jinx--load-module): Try to (locate-library module)
+before trying to look for a sibling file of jinx.el.
+---
+https://github.com/minad/jinx/pull/42
+
+ jinx.el | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/jinx.el b/jinx.el
+index d0cf56d..e829d50 100644
+--- a/jinx.el
++++ b/jinx.el
+@@ -472,6 +472,11 @@ If VISIBLE is non-nil, only include visible overlays."
+ (let ((default-directory
+ (file-name-directory (locate-library "jinx.el" t)))
+ (module (file-name-with-extension "jinx-mod" module-file-suffix)))
++
++ (let ((located-module (locate-library module)))
++ (when located-module
++ (setq module located-module)))
++
+ (unless (file-exists-p module)
+ (let ((command
+ `("cc" "-I." "-O2" "-Wall" "-Wextra" "-fPIC" "-shared"
+--
+2.40.0
+
diff --git a/app-emacs/jinx/jinx-0.6.ebuild b/app-emacs/jinx/jinx-0.6.ebuild
new file mode 100644
index 000000000000..4cb2cfcb7ae9
--- /dev/null
+++ b/app-emacs/jinx/jinx-0.6.ebuild
@@ -0,0 +1,44 @@
+# Copyright 2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+NEED_EMACS=27.1
+inherit edo elisp toolchain-funcs
+
+DESCRIPTION="Enchanted Spell Checker for GNU Emacs"
+HOMEPAGE="https://github.com/minad/jinx"
+
+# Recompressed from ELPA.
+SRC_URI="https://dev.gentoo.org/~arsen/${P}.tar.xz"
+
+LICENSE="GPL-3+"
+SLOT="0"
+KEYWORDS="~amd64"
+
+RDEPEND="
+ app-text/enchant:2
+ >=app-emacs/compat-29.1.4.0
+"
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+SITEFILE="50${PN}-gentoo.el"
+
+PATCHES=(
+ "${FILESDIR}"/jinx-0.6-try-load-path.patch
+)
+
+src_compile() {
+ edo $(tc-getCC) -fPIC -Wall -Wextra -shared \
+ $($(tc-getPKG_CONFIG) --cflags --libs enchant-2) \
+ ${CPPFLAGS} ${CFLAGS} ${LDFLAGS} -o jinx-mod.so jinx-mod.c
+ elisp_src_compile
+}
+
+src_install() {
+ elisp-make-autoload-file
+ elisp_src_install
+
+ elisp-modules-install "${PN}" jinx-mod.so
+}
diff --git a/app-emacs/jinx/metadata.xml b/app-emacs/jinx/metadata.xml
new file mode 100644
index 000000000000..983a85253bdd
--- /dev/null
+++ b/app-emacs/jinx/metadata.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>arsen@gentoo.org</email>
+ <description>Arsen Arsenović</description>
+ </maintainer>
+ <maintainer type="person">
+ <email>sam@gentoo.org</email>
+ <description>Sam James</description>
+ </maintainer>
+ <maintainer type="project">
+ <email>gnu-emacs@gentoo.org</email>
+ <name>Gentoo GNU Emacs project</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">minad/jinx</remote-id>
+ </upstream>
+</pkgmetadata>