public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Ulrich Müller" <ulm@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-util/cscope/, dev-util/cscope/files/
Date: Fri, 27 Jan 2023 06:54:18 +0000 (UTC)	[thread overview]
Message-ID: <1674802346.5921ece59c359b0eeedb990008db786101bb3257.ulm@gentoo> (raw)

commit:     5921ece59c359b0eeedb990008db786101bb3257
Author:     Ulrich Müller <ulm <AT> gentoo <DOT> org>
AuthorDate: Fri Jan 27 06:52:26 2023 +0000
Commit:     Ulrich Müller <ulm <AT> gentoo <DOT> org>
CommitDate: Fri Jan 27 06:52:26 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5921ece5

dev-util/cscope: Fix xcscope.el with >=emacs-27

Patch from upstream (with whitespace changes removed).

Closes: https://bugs.gentoo.org/892071
Signed-off-by: Ulrich Müller <ulm <AT> gentoo.org>

 dev-util/cscope/cscope-15.9-r1.ebuild            | 70 ++++++++++++++++++++++++
 dev-util/cscope/files/cscope-15.9-emacs-27.patch | 28 ++++++++++
 2 files changed, 98 insertions(+)

diff --git a/dev-util/cscope/cscope-15.9-r1.ebuild b/dev-util/cscope/cscope-15.9-r1.ebuild
new file mode 100644
index 000000000000..f0ca12cf9cfc
--- /dev/null
+++ b/dev-util/cscope/cscope-15.9-r1.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools elisp-common toolchain-funcs
+
+DESCRIPTION="Interactively examine a C program"
+HOMEPAGE="https://cscope.sourceforge.net/"
+SRC_URI="mirror://sourceforge/cscope/${P}.tar.gz"
+
+LICENSE="BSD GPL-2+"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~x86-solaris"
+IUSE="emacs"
+
+RDEPEND=">=sys-libs/ncurses-5.2:0=
+	emacs? ( >=app-editors/emacs-23.1:* )"
+DEPEND="${RDEPEND}"
+BDEPEND="sys-devel/flex
+	virtual/pkgconfig
+	app-alternatives/yacc"
+
+SITEFILE="50${PN}-gentoo.el"
+
+src_prepare() {
+	eapply "${FILESDIR}/${PN}-15.7a-ocs-sysdir.patch" #269305
+	eapply "${FILESDIR}/${PN}-15.9-pkgconfig.patch"
+	eapply "${FILESDIR}/${PN}-15.9-emacs-27.patch"
+	eapply_user
+	mv configure.{in,ac} || die
+	eautoreconf		  # prevent maintainer mode later on
+}
+
+src_configure() {
+	econf --with-ncurses="${EPREFIX}"/usr
+}
+
+src_compile() {
+	emake CURSES_LIBS="$("$(tc-getPKG_CONFIG)" --libs ncurses)"
+	if use emacs; then
+		cd "${S}"/contrib/xcscope || die
+		elisp-compile *.el
+	fi
+}
+
+src_install() {
+	default
+
+	if use emacs; then
+		cd "${S}"/contrib/xcscope || die
+		elisp-install ${PN} *.el *.elc
+		elisp-site-file-install "${FILESDIR}/${SITEFILE}"
+		dobin cscope-indexer
+	fi
+
+	cd "${S}"/contrib/webcscope || die
+	docinto webcscope
+	dodoc INSTALL TODO cgi-lib.pl cscope hilite.c
+	docinto webcscope/icons
+	dodoc icons/*.gif
+}
+
+pkg_postinst() {
+	use emacs && elisp-site-regen
+}
+
+pkg_postrm() {
+	use emacs && elisp-site-regen
+}

diff --git a/dev-util/cscope/files/cscope-15.9-emacs-27.patch b/dev-util/cscope/files/cscope-15.9-emacs-27.patch
new file mode 100644
index 000000000000..48cd7150176d
--- /dev/null
+++ b/dev-util/cscope/files/cscope-15.9-emacs-27.patch
@@ -0,0 +1,28 @@
+https://bugs.gentoo.org/892071
+
+commit eaea31cb93ecddda69a373f83f632e1a450c3c90
+Author: Brock Zheng Techyauld Ltd <yzheng@techyauld.com>
+Date:   Tue Aug 25 20:28:11 2020 +0800
+
+    emacs plugin fixup: GNU/Emacs 27.1 removes function process-kill-without-query
+
+--- a/contrib/xcscope/xcscope.el
++++ b/contrib/xcscope/xcscope.el
+@@ -2006,7 +2006,7 @@
+ 	      (set-process-filter cscope-process cscope-filter-func)
+ 	      (set-process-sentinel cscope-process cscope-sentinel-func)
+ 	      (set-marker (process-mark cscope-process) (point))
+-	      (process-kill-without-query cscope-process)
++              (set-process-query-on-exit-flag cscope-process nil)
+ 	      (if cscope-running-in-xemacs
+ 		  (setq modeline-process ": Searching ..."))
+ 	      (setq buffer-read-only t)
+@@ -2139,7 +2139,7 @@
+ 		   cscope-indexing-script args))
+       (set-process-sentinel cscope-unix-index-process
+ 			    'cscope-unix-index-files-sentinel)
+-      (process-kill-without-query cscope-unix-index-process)
++      (set-process-query-on-exit-flag cscope-unix-index-process nil)
+       )
+     ))
+ 


             reply	other threads:[~2023-01-27  6:54 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-27  6:54 Ulrich Müller [this message]
  -- strict thread matches above, loose matches on Subject: below --
2022-06-10 18:08 [gentoo-commits] repo/gentoo:master commit in: dev-util/cscope/, dev-util/cscope/files/ Matt Turner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1674802346.5921ece59c359b0eeedb990008db786101bb3257.ulm@gentoo \
    --to=ulm@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox