From 4340eb85c2d4859037b858bb58e2f77d7f79d9f7 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Ulrich=20M=C3=BCller?= Date: Sun, 22 Sep 2019 18:13:52 +0200 Subject: [PATCH] app-editors/emacs: Install systemd unit file. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Closes: https://bugs.gentoo.org/694542 Package-Manager: Portage-2.3.76, Repoman-2.3.17 Signed-off-by: Ulrich Müller --- .../emacs/{emacs-26.3.ebuild => emacs-26.3-r1.ebuild} | 9 +++++++++ 1 file changed, 9 insertions(+) rename app-editors/emacs/{emacs-26.3.ebuild => emacs-26.3-r1.ebuild} (97%) diff --git a/app-editors/emacs/emacs-26.3.ebuild b/app-editors/emacs/emacs-26.3-r1.ebuild similarity index 97% rename from app-editors/emacs/emacs-26.3.ebuild rename to app-editors/emacs/emacs-26.3-r1.ebuild index 0e312adbbbb7..40ca9d580196 100644 --- a/app-editors/emacs/emacs-26.3.ebuild +++ b/app-editors/emacs/emacs-26.3-r1.ebuild @@ -281,6 +281,15 @@ src_install () { # remove COPYING file (except for etc/COPYING used by describe-copying) rm "${ED}"/usr/share/emacs/${FULL_VERSION}/lisp/COPYING + if use systemd; then + insinto /usr/lib/systemd/user + sed -e "/^##/d" \ + -e "/^ExecStart/s,emacs,${EPREFIX}/usr/bin/${EMACS_SUFFIX}," \ + -e "/^ExecStop/s,emacsclient,${EPREFIX}/usr/bin/&-${EMACS_SUFFIX}," \ + etc/emacs.service | newins - ${EMACS_SUFFIX}.service + assert + fi + if use gzip-el; then # compress .el files when a corresponding .elc exists find "${ED}"/usr/share/emacs/${FULL_VERSION}/lisp -type f \ -- 2.26.2