5f26f2
Summary: C source code tree search and browse tool
204343
Name: cscope
204343
Version: 15.9
662f5f
Release: 17%{?dist}
1124be
Source0: https://downloads.sourceforge.net/project/%{name}/%{name}/v%{version}/%{name}-%{version}.tar.gz
204343
URL: http://cscope.sourceforge.net
204343
License: BSD and GPLv2+
1124be
BuildRequires: pkgconf-pkg-config ncurses-devel gcc flex bison m4
1124be
BuildRequires: autoconf automake make
1124be
Requires: emacs-filesystem coreutils ed
1124be
%if !0%{?rhel} && 0%{?fedora} < 36
204343
Requires: xemacs-filesystem
204343
%endif
204343
1124be
# upstream commits from https://sourceforge.net/p/cscope/cscope/commit_browser
1124be
Patch1: cscope-1-modified-from-patch-81-Fix-reading-include-files-in-.patch
1124be
Patch2: cscope-2-Cull-extraneous-declaration.patch
1124be
Patch3: cscope-3-Avoid-putting-directories-found-during-header-search.patch
1124be
Patch4: cscope-4-Avoid-double-free-via-double-fclose-in-changestring.patch
1124be
Patch5: cscope-5-contrib-ocs-Fix-bashims-Closes-480591.patch
1124be
Patch6: cscope-6-doc-cscope.1-Fix-hyphens.patch
1124be
Patch7: cscope-7-fscanner-swallow-function-as-parameters.patch
1124be
# this patch is not needed - RHEL8 has emacs-26.1
1124be
# Patch8: cscope-8-emacs-plugin-fixup-GNU-Emacs-27.1-removes-function-p.patch
662f5f
Patch9: cscope-9-fix-access-beyond-end-of-string.patch
662f5f
Patch10: cscope-a-docs-typo-fixes-in-man-page-and-comments.patch
662f5f
1124be
# distrubution patches which were not upstreamed
662f5f
Patch11: dist-1-coverity-fixes.patch
662f5f
Patch12: dist-2-cscope-indexer-help.patch
662f5f
Patch13: dist-3-add-selftests.patch
662f5f
Patch14: dist-4-fix-printf.patch
204343
204343
%define cscope_share_path %{_datadir}/cscope
1124be
%if !0%{?rhel} && 0%{?fedora} < 36
204343
%define xemacs_lisp_path %{_datadir}/xemacs/site-packages/lisp
1124be
%else
1124be
%define xemacs_lisp_path %nil
1124be
%endif
204343
%define emacs_lisp_path %{_datadir}/emacs/site-lisp
204343
%define vim_plugin_path %{_datadir}/vim/vimfiles/plugin
204343
204343
%description
5f26f2
cscope is a mature, ncurses based, C source code tree browsing tool.  It
204343
allows users to search large source code bases for variables, functions,
5f26f2
macros, etc, as well as perform general regex and plain text searches.
5f26f2
Results are returned in lists, from which the user can select individual
204343
matches for use in file editing.
204343
204343
%prep
204343
%autosetup -p1
204343
204343
%build
0d2092
aclocal
0d2092
autoheader
0d2092
autoconf
0d2092
automake --add-missing
204343
%configure
204343
make
204343
204343
%install
204343
rm -rf $RPM_BUILD_ROOT %{name}-%{version}.files
5f26f2
make DESTDIR=$RPM_BUILD_ROOT install
204343
mkdir -p $RPM_BUILD_ROOT/var/lib/cs
204343
mkdir -p $RPM_BUILD_ROOT%{cscope_share_path}
204343
cp -a contrib/xcscope/xcscope.el $RPM_BUILD_ROOT%{cscope_share_path}
204343
install -m 755 contrib/xcscope/cscope-indexer $RPM_BUILD_ROOT%{_bindir}
204343
cp -a contrib/cctree.vim $RPM_BUILD_ROOT%{cscope_share_path}
204343
for dir in %{xemacs_lisp_path} %{emacs_lisp_path} ; do
204343
  mkdir -p $RPM_BUILD_ROOT$dir
204343
  ln -s %{cscope_share_path}/xcscope.el $RPM_BUILD_ROOT$dir
204343
  touch $RPM_BUILD_ROOT$dir/xcscope.elc
204343
  echo "%ghost $dir/xcscope.el*" >> %{name}-%{version}.files
204343
done
204343
1124be
%check
1124be
make check
1124be
204343
%files -f %{name}-%{version}.files
204343
%{_bindir}/*
204343
%dir %{cscope_share_path}
204343
%{cscope_share_path}/
204343
%{_mandir}/man1/*
204343
%dir /var/lib/cs
204343
%doc AUTHORS COPYING ChangeLog README TODO contrib/cctree.txt
204343
1124be
%if !0%{?rhel} && 0%{?fedora} < 36
204343
%triggerin -- xemacs
204343
ln -sf %{cscope_share_path}/xcscope.el %{xemacs_lisp_path}/xcscope.el
204343
%endif
204343
204343
%triggerin -- emacs, emacs-nox, emacs-lucid
204343
ln -sf %{cscope_share_path}/xcscope.el %{emacs_lisp_path}/xcscope.el
204343
204343
%triggerin -- vim-filesystem
204343
ln -sf %{cscope_share_path}/cctree.vim %{vim_plugin_path}/cctree.vim
204343
1124be
%if !0%{?rhel} && 0%{?fedora} < 36
204343
%triggerun -- xemacs
204343
[ $2 -gt 0 ] && exit 0
204343
rm -f %{xemacs_lisp_path}/xcscope.el
204343
%endif
204343
204343
%triggerun -- emacs, emacs-nox, emacs-lucid
204343
[ $2 -gt 0 ] && exit 0
204343
rm -f %{emacs_lisp_path}/xcscope.el
204343
204343
%triggerun -- vim-filesystem
204343
[ $2 -gt 0 ] && exit 0
204343
rm -f %{vim_plugin_path}/cctree.vim
204343
204343
%changelog
662f5f
* Thu Sep 29 2022 Vladis Dronov <vdronov@redhat.com> - 15.9-17
662f5f
- Update to the upstream git @ 7f2369ac (bz 2129887)
662f5f
1124be
* Fri Apr 22 2022 Vladis Dronov <vdronov@redhat.com> - 15.9-11
1124be
- Add another small distrubution patch (bz 2074437)
1124be
1124be
* Mon Apr 11 2022 Vladis Dronov <vdronov@redhat.com> - 15.9-10
1124be
- Add missing upstream patches (bz 2074437)
1124be
5f26f2
* Wed Oct 21 2020 Vladis Dronov <vdronov@redhat.com> - 15.9-9
5f26f2
- Remove another fclose() to please covscan (bz1886165)
5f26f2
5f26f2
* Wed Oct 07 2020 Vladis Dronov <vdronov@redhat.com> - 15.9-8
5f26f2
- Fix a double-free in changestring() (bz1886165)
5f26f2
- Update Requires to include coreutils and ed
5f26f2
- Adjust cscope-coverity-fixes.patch removing the fclose(script) chunk
5f26f2
- Adjust BuildRequires and remove trailing spaces
5f26f2
- Remove older source version from .gitignore
5f26f2
- Rename cscope-invindex-sizing.patch as it is for the older upstream version
5f26f2
0d2092
* Tue Jun 25 2019 Neil Horman <nhorman@redhat.com> - 15.9-6
0d2092
- Fix covscan warning (bz 1722404)
0d2092
0d2092
* Mon Jun 24 2019 Neil Horman <nhorman@redhat.com> - 15.9-5
0d2092
- update help for cscope-indexer (bz 1722404)
0d2092
0d2092
* Mon Jun 03 2019 Neil Horman <nhorman@redhat.com> - 15.9-4
0d2092
- Fix cscope version (bz 1685920)
0d2092
0d2092
* Thu Feb 28 2019 Neil Horman <nhorman@redhat.com> - 15.9-3
0d2092
- Add CI test harness (bz 1682353)
0d2092
204343
* Fri Oct 12 2018 Neil Horman <nhorman@redhat.com> - 15.9-2
204343
- Fix up some coverity scan issues (bz 1602468)
204343
204343
* Tue Jul 24 2018 Neil Horman <nhorman@redhat.com> - 15.9-1
204343
- Update to latest upstream with coverity fixes (bz 1602468)
204343
204343
* Thu Mar 01 2018 Josh Boyer <jwboyer@fedoraproject.org> - 15.8b-8
204343
- Conditionalize xemacs
204343
204343
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 15.8b-7
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
204343
204343
* Wed Aug 02 2017 Fedora Release Engineering <releng@fedoraproject.org> - 15.8b-6
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
204343
204343
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 15.8b-5
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
204343
204343
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 15.8b-4
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
204343
204343
* Mon Nov 28 2016 Neil Horman <nhorman@redhat.com> - 15.8b-3
204343
- Changed permissions on cscope-indexer (bz 1399108)
204343
204343
* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 15.8b-2
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
204343
204343
* Wed Aug 05 2015 Neil Horman <nhorman@redhat.com> - 15.8b-1
204343
- Update to latest upstream
204343
1124be
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.8-12
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
204343
204343
* Tue Sep 30 2014 Neil Horman <nhorman@redhat.com> - 15.8-11
204343
- Added triggerin support for emacs-nox (bz 961709)
204343
204343
* Sat Aug 16 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.8-10
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
204343
204343
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.8-9
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
204343
204343
* Tue Apr 15 2014 Neil Horman <nhorman@redhat.com> - 15.8-8
204343
- Fixed formatting issue with empty function array (bz 1087940)
204343
204343
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.8-7
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
204343
204343
* Mon Mar 25 2013 Neil Horman <nhorman@redhat.com> - 15.8-6
204343
- Fixed build break
204343
204343
* Mon Mar 25 2013 Neil Horman <nhorman@redhat.com> - 15.8-5
204343
- Updated to run autoreconf for impending aarch64 introduction (bz 925201)
204343
204343
* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.8-4
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
204343
204343
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.8-3
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
204343
204343
* Tue Jul 10 2012 Neil Horman <nhorman@redhat.com> - 15.8-2
204343
- Fix inverted index sizing
204343
204343
* Mon Jun 18 2012 Neil Horman <nhorman@redhat.com> - 15.8
204343
- Update to latest upstream
204343
204343
* Mon Mar 12 2012 Neil Horman <nhorman@redhat.com> -15.7a-10
204343
- Fixed a segfault in invlib construction ( bz 786523)
204343
204343
* Mon Mar 05 2012 Neil Horman <nhorman@redhat.com> 15.7a-9
204343
- Fixed a segfault in the symbol assignment search (bz 799643)
204343
204343
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.7a-8
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
204343
204343
* Thu Jun 30 2011 Neil Horman <nhorman@redhat.com> - 15.7a-7
204343
- Added LEXERR token to catch bad parsing before we crash (bz717545)
204343
204343
* Fri Jun 24 2011 Neil Horman <nhorman@redhat.com> - 15.7a-6
204343
- Fixed licensing for xcscope.el (bz 715898)
204343
- Fixed xemacs pkg. dependency (bz 719523)
204343
204343
* Wed Jun 01 2011 Neil Horman <nhorman@redhat.com> - 15.7a-5
204343
- Fix scriptles macro expansion (bz 708499)
204343
204343
* Thu May 26 2011 Neil Horman <nhorman@redhat.com> - 15.7a-4
204343
- Added cctree.vim vi plugin
204343
204343
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.7a-3
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
204343
204343
* Thu Sep 30 2010 Neil Horman 
204343
- Ignore SIGPIPE in line mode (bz 638756)
204343
204343
* Mon Mar 1 2010 Neil Horman <nhorman@redhat.com> - 15.7a-1
204343
- Update to latest upstream release (bz 569043)
204343
204343
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.6-5
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
204343
204343
* Fri Jun 12 2009 Neil Horman <nhorman@redhat.com>
204343
- Fix some buffer overflows (bz 505605)
204343
204343
* Tue Feb 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.6-3
204343
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
204343
204343
* Tue Jul 08 2008 Neil Horman <nhorman@redhat.com> -15.6-2.dist
204343
- Grab upstream patch for -q rebuld (bz 436648)
204343
204343
* Tue Mar 27 2007 Neil Horman <nhorman@redhat.com> -15.6-1.dist
204343
- Rebase to version 15.6
204343
204343
* Mon Mar 05 2007 Neil Horman <nhorman@redhat.com> -15.5-15.4.dist
204343
- Make sigwinch handler only register for curses mode (bz 230862)
204343
204343
* Mon Feb 05 2007 Neil Horman <nhorman@redhat.com> -15.5-15.3.dist
204343
- Fixing dist label in release tag.
204343
204343
* Thu Feb 01 2007 Neil Horman <nhorman@redhat.com> -15.5-15.2.dist
204343
- Fixing changelog to not have macro in release
204343
204343
* Wed Aug 23 2006 Neil Horman <nhorman@redhat.com> -15.5-15.1
204343
- fixed overflows per bz 203651
204343
- start using {dist} tag to make release numbering easier
204343
204343
* Mon Jul 17 2006 Jesse Keating <jkeating@redhat.com> - 15.5-14
204343
- rebuild
204343
204343
* Fri Jun 23 2006 Neil Horman <nhorman@redhat.com>
204343
- Fix putstring overflow (bz 189666)
204343
204343
* Fri Jun 23 2006 Neil Horman <nhorman@redhat.com>
204343
- Fix putstring overflow (bz 189666)
204343
204343
* Fri May 5  2006 Neil Horman <nhorman@redhat.com>
204343
- Adding fix to put SYSDIR in right location (bz190580)
204343
204343
* Fri Apr 21 2006 Neil Horman <nhorman@redhat.com> - 15.5-13.4
204343
- adding inverted index overflow patch
204343
204343
* Fri Feb 10 2006 Jesse Keating <jkeating@redhat.com> - 15.5-13.2
204343
- bump again for double-long bug on ppc(64)
204343
204343
* Tue Feb 07 2006 Jesse Keating <jkeating@redhat.com> - 15.5-13.1
204343
- rebuilt for new gcc4.1 snapshot and glibc changes
204343
204343
* Fri Dec 16 2005 Jesse Keating <jkeating@redhat.com>
204343
- rebuild on new gcc
204343
204343
* Tue Nov 30 2004 Neil Horman <nhorman@redhat.com>
204343
- added tempsec patch to fix bz140764/140765
204343
204343
* Mon Nov 29 2004 Neil Horman <nhorman@redhat.com>
204343
- updated cscope resize patch to do less work in
204343
  signal handler and synced version nr. on dist.
204343
204343
* Mon Nov 22 2004 Neil Horman <nhorman@redhat.com>
204343
- added cscope-1.5.-resize patch to allow terminal
204343
  resizing while cscope is running
204343
204343
* Tue Oct 5  2004 Neil Horman <nhorman@redhat.com>
204343
- modified cscope-15.5.-inverted patch to be upstream
204343
  friendly
204343
204343
* Tue Sep 28 2004 Neil Horman <nhorman@redhat.com>
204343
- fixed inverted index bug (bz 133942)
5f26f2
204343
* Mon Sep 13 2004 Frank Ch. Eigler <fche@redhat.com>
204343
- bumped release number to a plain "1"
204343
204343
* Fri Jul 16 2004 Neil Horman <nhorman@redhat.com>
204343
- Added cscope-indexer helper and xcscope lisp addon
204343
- Added man page for xcscope
204343
- Added triggers to add xcscope.el pkg to (x)emacs
204343
- Thanks to Ville, Michael and Jens for thier help :)
204343
204343
* Fri Jul 2 2004 Neil Horman <nhorman@redhat.com>
204343
- Added upstream ocs fix
204343
- Added feature to find symbol assignments
204343
- Changed default SYSDIR directory to /var/lib/cs
5f26f2
- Incoproated M. Schwendt's fix for ocs -s
204343
204343
* Fri Jun 18 2004 Neil Horman <nhorman@redhat.com>
204343
- built the package