summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaciej Barć <xgqt@gentoo.org>2024-08-03 16:11:45 +0200
committerMaciej Barć <xgqt@gentoo.org>2024-08-03 16:12:17 +0200
commitfde4642a012f5678b417ca937644e2d6ca49b498 (patch)
tree106d297b31acdd6576cb8317300ce3b7726c29ae /app-emacs/erlang-mode
parentapp-emacs/erlang-mode: fix HOMEPAGE and other minor tweaks (diff)
downloadgentoo-fde4642a012f5678b417ca937644e2d6ca49b498.tar.gz
gentoo-fde4642a012f5678b417ca937644e2d6ca49b498.tar.bz2
gentoo-fde4642a012f5678b417ca937644e2d6ca49b498.zip
app-emacs/erlang-mode: sync live 9999 version
Signed-off-by: Maciej Barć <xgqt@gentoo.org>
Diffstat (limited to 'app-emacs/erlang-mode')
-rw-r--r--app-emacs/erlang-mode/erlang-mode-9999.ebuild45
1 files changed, 45 insertions, 0 deletions
diff --git a/app-emacs/erlang-mode/erlang-mode-9999.ebuild b/app-emacs/erlang-mode/erlang-mode-9999.ebuild
new file mode 100644
index 000000000000..614c5b4699a1
--- /dev/null
+++ b/app-emacs/erlang-mode/erlang-mode-9999.ebuild
@@ -0,0 +1,45 @@
+# Copyright 2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit elisp
+
+DESCRIPTION="A major mode for editing Erlang"
+HOMEPAGE="https://www.erlang/
+ https://github.com/erlang/"
+
+if [[ "${PV}" == *9999* ]] ; then
+ inherit git-r3
+
+ EGIT_REPO_URI="https://github.com/erlang/otp.git"
+ S="${WORKDIR}/${P}/lib/tools/emacs"
+else
+ # Distfile is shared with dev-lang/erlang.
+ SRC_URI="https://github.com/erlang/otp/archive/OTP-${PV}.tar.gz
+ -> erlang-${PV}.tar.gz"
+ S="${WORKDIR}/otp-OTP-${PV}/lib/tools/emacs"
+
+ KEYWORDS="~amd64 ~x86"
+fi
+
+LICENSE="Apache-2.0"
+SLOT="0"
+
+RDEPEND="
+ !dev-lang/erlang[emacs(-)]
+"
+
+SITEFILE="50${PN}-gentoo.el"
+
+src_prepare() {
+ elisp_src_prepare
+
+ sed -e "s:/usr/share:${EPREFIX}/usr/share:g" \
+ "${FILESDIR}/${SITEFILE}" > "${T}/${SITEFILE}" || die
+}
+
+src_install() {
+ elisp-install erlang *.el{,c}
+ elisp-site-file-install "${T}/${SITEFILE}"
+}