c67250
Summary: C source code tree search and browse tool 
c67250
Name: cscope
c67250
Version: 15.8
3cfd45
Release: 10%{?dist}
c67250
Source0: https://downloads.sourceforge.net/project/%{name}/%{name}/%{version}/%{name}-%{version}.tar.bz2
c67250
URL: http://cscope.sourceforge.net
c67250
License: BSD and GPLv2+
c67250
Group: Development/Tools 
c67250
BuildRoot: %{_tmppath}/%{name}-%{version}
c67250
BuildRequires: pkgconfig ncurses-devel flex bison m4
5e7ba3
Requires: emacs-filesystem
c67250
c67250
%define cscope_share_path %{_datadir}/cscope
c67250
%define emacs_lisp_path %{_datadir}/emacs/site-lisp
c67250
%define vim_plugin_path %{_datadir}/vim/vimfiles/plugin
c67250
c67250
Patch0: cscope-invindex-sizing.patch
05f219
Patch1: cscope-15.8-init-function-array-to-unknown.patch
05f219
Patch2: cscope-version.patch
c67250
c67250
%description
c67250
cscope is a mature, ncurses based, C source code tree browsing tool.  It 
c67250
allows users to search large source code bases for variables, functions,
c67250
macros, etc, as well as perform general regex and plain text searches.  
c67250
Results are returned in lists, from which the user can select individual 
c67250
matches for use in file editing.
c67250
c67250
%prep
c67250
%setup -q
c67250
%patch0 -p0
05f219
%patch1 -p1
05f219
%patch2 -p1 -z .update
c67250
c67250
%build
c67250
%configure
c67250
make
c67250
c67250
%install
c67250
rm -rf $RPM_BUILD_ROOT %{name}-%{version}.files
c67250
make DESTDIR=$RPM_BUILD_ROOT install 
c67250
mkdir -p $RPM_BUILD_ROOT/var/lib/cs
c67250
mkdir -p $RPM_BUILD_ROOT%{cscope_share_path}
c67250
cp -a contrib/xcscope/xcscope.el $RPM_BUILD_ROOT%{cscope_share_path}
c67250
cp -a contrib/xcscope/cscope-indexer $RPM_BUILD_ROOT%{_bindir}
c67250
cp -a contrib/cctree.vim $RPM_BUILD_ROOT%{cscope_share_path}
5e7ba3
for dir in %{emacs_lisp_path} ; do
5e7ba3
  mkdir -p $RPM_BUILD_ROOT$dir
5e7ba3
  ln -s %{cscope_share_path}/xcscope.el $RPM_BUILD_ROOT$dir
5e7ba3
  touch $RPM_BUILD_ROOT$dir/xcscope.elc
5e7ba3
  echo "%ghost $dir/xcscope.el*" >> %{name}-%{version}.files
5e7ba3
done
5e7ba3
c67250
c67250
%clean
c67250
rm -rf $RPM_BUILD_ROOT
c67250
c67250
5e7ba3
%files -f %{name}-%{version}.files
c67250
%defattr(-,root,root,-)
c67250
%{_bindir}/*
c67250
%dir %{cscope_share_path}
c67250
%{cscope_share_path}/
c67250
%{_mandir}/man1/*
c67250
%dir /var/lib/cs
c67250
%doc AUTHORS COPYING ChangeLog README TODO contrib/cctree.txt
c67250
3cfd45
%triggerin -- emacs, emacs-nox
5e7ba3
ln -sf %{cscope_share_path}/xcscope.el %{emacs_lisp_path}/xcscope.el
5e7ba3
c67250
%triggerin -- vim-filesystem
c67250
ln -sf %{cscope_share_path}/cctree.vim %{vim_plugin_path}/cctree.vim
c67250
3cfd45
%triggerun -- emacs, emacs-nox
5e7ba3
[ $2 -gt 0 ] && exit 0
5e7ba3
rm -f %{emacs_lisp_path}/xcscope.el
5e7ba3
c67250
%triggerun -- vim-filesystem
c67250
[ $2 -gt 0 ] && exit 0
c67250
rm -f %{vim_plugin_path}/cctree.vim
c67250
c67250
%changelog
3cfd45
* Wed Jun 07 2017 Neil Horman <nhorman@redhat.com> - 15.8-10
3cfd45
- Add emacs-nox to triggin install/uninstall (bz 1412326)
3cfd45
05f219
* Wed Feb 17 2016 Neil Horman <nhorman@redhat.com> - 15.8-9
05f219
- Resolves bz 1057132)
05f219
05f219
* Thu Feb 11 2016 Neil Horman <nhorman@redhat.com> - 15.8-8
05f219
- Resolves bz 1124571
05f219
5e7ba3
* Fri Jan 24 2014 Daniel Mach <dmach@redhat.com> - 15.8-7
5e7ba3
- Mass rebuild 2014-01-24
5e7ba3
5e7ba3
* Tue Jan 07 2014 Neil Horman <nhorman@redhat.com> - 15.8-6
5e7ba3
- Remove xemacs-filesystem as a dep (bz 1049179)
5e7ba3
5e7ba3
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 15.8-5
5e7ba3
- Mass rebuild 2013-12-27
5e7ba3
5e7ba3
* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.8-4
5e7ba3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
c67250
c67250
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.8-3
c67250
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
c67250
c67250
* Tue Jul 10 2012 Neil Horman <nhorman@redhat.com> - 15.8-2
c67250
- Fix inverted index sizing
c67250
c67250
* Mon Jun 18 2012 Neil Horman <nhorman@redhat.com> - 15.8
c67250
- Update to latest upstream
c67250
c67250
* Mon Mar 12 2012 Neil Horman <nhorman@redhat.com> -15.7a-10
c67250
- Fixed a segfault in invlib construction ( bz 786523)
c67250
c67250
* Mon Mar 05 2012 Neil Horman <nhorman@redhat.com> 15.7a-9
c67250
- Fixed a segfault in the symbol assignment search (bz 799643)
c67250
c67250
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.7a-8
c67250
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
c67250
c67250
* Wed Jun 30 2011 Neil Horman <nhorman@redhat.com> - 15.7a-7
c67250
- Added LEXERR token to catch bad parsing before we crash (bz717545)
c67250
c67250
* Fri Jun 24 2011 Neil Horman <nhorman@redhat.com> - 15.7a-6
c67250
- Fixed licensing for xcscope.el (bz 715898)
c67250
- Fixed xemacs pkg. dependency (bz 719523)
c67250
c67250
* Wed Jun 01 2011 Neil Horman <nhorman@redhat.com> - 15.7a-5
c67250
- Fix scriptles macro expansion (bz 708499)
c67250
c67250
* Thu May 26 2011 Neil Horman <nhorman@redhat.com> - 15.7a-4
c67250
- Added cctree.vim vi plugin
c67250
c67250
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.7a-3
c67250
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
c67250
c67250
* Thu Sep 30 2010 Neil Horman 
c67250
- Ignore SIGPIPE in line mode (bz 638756)
c67250
c67250
* Mon Mar 1 2010 Neil Horman <nhorman@redhat.com> - 15.7a-1
c67250
- Update to latest upstream release (bz 569043)
c67250
c67250
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.6-5
c67250
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
c67250
c67250
* Fri Jun 12 2009 Neil Horman <nhorman@redhat.com>
c67250
- Fix some buffer overflows (bz 505605)
c67250
c67250
* Tue Feb 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 15.6-3
c67250
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
c67250
c67250
* Tue Jul 08 2008 Neil Horman <nhorman@redhat.com> -15.6-2.dist
c67250
- Grab upstream patch for -q rebuld (bz 436648)
c67250
c67250
* Fri Mar 25 2007 Neil Horman <nhorman@redhat.com> -15.6-1.dist
c67250
- Rebase to version 15.6
c67250
c67250
* Mon Mar 05 2007 Neil Horman <nhorman@redhat.com> -15.5-15.4.dist
c67250
- Make sigwinch handler only register for curses mode (bz 230862)
c67250
c67250
* Mon Feb 05 2007 Neil Horman <nhorman@redhat.com> -15.5-15.3.dist
c67250
- Fixing dist label in release tag.
c67250
c67250
* Thu Feb 01 2007 Neil Horman <nhorman@redhat.com> -15.5-15.2.dist
c67250
- Fixing changelog to not have macro in release
c67250
c67250
* Wed Aug 23 2006 Neil Horman <nhorman@redhat.com> -15.5-15.1
c67250
- fixed overflows per bz 203651
c67250
- start using {dist} tag to make release numbering easier
c67250
c67250
* Mon Jul 17 2006 Jesse Keating <jkeating@redhat.com> - 15.5-14
c67250
- rebuild
c67250
c67250
* Fri Jun 23 2006 Neil Horman <nhorman@redhat.com>
c67250
- Fix putstring overflow (bz 189666)
c67250
c67250
* Fri Jun 23 2006 Neil Horman <nhorman@redhat.com>
c67250
- Fix putstring overflow (bz 189666)
c67250
c67250
* Fri May 5  2006 Neil Horman <nhorman@redhat.com>
c67250
- Adding fix to put SYSDIR in right location (bz190580)
c67250
c67250
* Fri Apr 21 2006 Neil Horman <nhorman@redhat.com> - 15.5-13.4
c67250
- adding inverted index overflow patch
c67250
c67250
* Fri Feb 10 2006 Jesse Keating <jkeating@redhat.com> - 15.5-13.2
c67250
- bump again for double-long bug on ppc(64)
c67250
c67250
* Tue Feb 07 2006 Jesse Keating <jkeating@redhat.com> - 15.5-13.1
c67250
- rebuilt for new gcc4.1 snapshot and glibc changes
c67250
c67250
* Fri Dec 16 2005 Jesse Keating <jkeating@redhat.com>
c67250
- rebuild on new gcc
c67250
c67250
* Tue Nov 30 2004 Neil Horman <nhorman@redhat.com>
c67250
- added tempsec patch to fix bz140764/140765
c67250
c67250
* Mon Nov 29 2004 Neil Horman <nhorman@redhat.com>
c67250
- updated cscope resize patch to do less work in
c67250
  signal handler and synced version nr. on dist.
c67250
c67250
* Mon Nov 22 2004 Neil Horman <nhorman@redhat.com>
c67250
- added cscope-1.5.-resize patch to allow terminal
c67250
  resizing while cscope is running
c67250
c67250
* Tue Oct 5  2004 Neil Horman <nhorman@redhat.com>
c67250
- modified cscope-15.5.-inverted patch to be upstream
c67250
  friendly
c67250
c67250
* Tue Sep 28 2004 Neil Horman <nhorman@redhat.com>
c67250
- fixed inverted index bug (bz 133942)
c67250
 
c67250
* Mon Sep 13 2004 Frank Ch. Eigler <fche@redhat.com>
c67250
- bumped release number to a plain "1"
c67250
c67250
* Fri Jul 16 2004 Neil Horman <nhorman@redhat.com>
c67250
- Added cscope-indexer helper and xcscope lisp addon
c67250
- Added man page for xcscope
c67250
- Added triggers to add xcscope.el pkg to (x)emacs
c67250
- Thanks to Ville, Michael and Jens for thier help :)
c67250
c67250
* Fri Jul 2 2004 Neil Horman <nhorman@redhat.com>
c67250
- Added upstream ocs fix
c67250
- Added feature to find symbol assignments
c67250
- Changed default SYSDIR directory to /var/lib/cs
c67250
- Incoproated M. Schwendt's fix for ocs -s 
c67250
c67250
* Fri Jun 18 2004 Neil Horman <nhorman@redhat.com>
c67250
- built the package