%define majversion %(echo %version | cut -d. -f 1-2) ## *AUTOSPEC-OFF* %define vimdir %{name}%(majversion=%majversion; echo ${majversion/\./}) ## *AUTOSPEC-ON* %define langversion 7.2 %define with_gvim 0 Name: vim Version: 7.4.884 Release: 1mamba Summary: VIsual editor iMproved Group: Applications/Text Vendor: openmamba Distribution: openmamba Packager: Silvan Calarco URL: http://www.vim.org/ Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{majversion}.tar.bz2 #Source1: ftp://ftp.vim.org/pub/vim/extra/vim-%{langversion}-lang.tar.gz Source2: vimrc-skel # patches got from: ftp://ftp.vim.org/pub/vim/patches/%{majversion} # create full patches archive with vim-patches.sh script below Source3: %{name}-%{version}-patchset.tar.gz Source4: vim-autoupdate License: Charityware ## AUTOBUILDREQ-BEGIN BuildRequires: glibc-devel BuildRequires: libgpm-devel BuildRequires: libncurses-devel BuildRequires: libselinux-devel BuildRequires: libtcl-devel BuildRequires: perl-devel BuildRequires: ruby-devel ## AUTOBUILDREQ-END BuildRequires: perl-devel >= 2:5.8.7 BuildRequires: libpython-devel >= 2.3.4 BuildRequires: libtcl >= 8.4.11 BuildRequires: gettext-devel BuildRoot: %{_tmppath}/%{name}-%{version}-root %description VIM (VIsual editor iMproved) is an updated and improved version of the vi editor. Vi was the first real screen-based editor for UNIX, and is still very popular. VIM improves on vi by adding new features: multiple windows, multi-level undo, block highlighting and more. VIM-X11 is a version of the VIM editor which will run within the X Window System. If you install this package, you can run VIM as an X application with a full GUI interface and mouse support. %package doc Group: Documentation Summary: Documentation for %{name} Requires: %{name} = %{?epoch:%epoch:}%{version}-%{release} %description doc VIM (VIsual editor iMproved) is an updated and improved version of the vi editor. Vi was the first real screen-based editor for UNIX, and is still very popular. VIM improves on vi by adding new features: multiple windows, multi-level undo, block highlighting and more. VIM-X11 is a version of the VIM editor which will run within the X Window System. If you install this package, you can run VIM as an X application with a full GUI interface and mouse support. This package provides documentation files. %package tutor Group: Applications/Text Summary: Tutorial files for %{name} Requires: %{name} = %{?epoch:%epoch:}%{version}-%{release} %description tutor VIM (VIsual editor iMproved) is an updated and improved version of the vi editor. Vi was the first real screen-based editor for UNIX, and is still very popular. VIM improves on vi by adding new features: multiple windows, multi-level undo, block highlighting and more. VIM-X11 is a version of the VIM editor which will run within the X Window System. If you install this package, you can run VIM as an X application with a full GUI interface and mouse support. This package provides tutorial files. %prep %setup -q -n %{vimdir} # apply big patches mkdir patches cd patches tar xf %{SOURCE3} cd .. ls patches/| sort -V | while read f; do cat patches/$f | patch -p0 done %define _use_internal_dependency_generator 0 # Find requires modified %define __find_requires %{_builddir}/%{vimdir}/find_requires.sh # Find requires will ignore datadir files to avoid a wrong /bin/csh requirement cat > find_requires.sh << _EOF #! /bin/sh grep -v %{_datadir} | %{_prefix}/lib/rpm/find-requires %{buildroot} %{_target_cpu} _EOF chmod +x find_requires.sh sed -i ' s,SYS_VIMRC_FILE "\$VIM/vimrc",SYS_VIMRC_FILE "%{_sysconfdir}/vim/vimrc", s,SYS_GVIMRC_FILE "\$VIM/gvimrc",SYS_GVIMRC_FILE "%{_sysconfdir}/vim/gvimrc",' \ src/os_unix.h # disable command echo #for i in runtime/{gvimrc_example.vim,vimrc_example.vim}; do # sed -i 's/^set showcmd/set noshowcmd/' $i #done %define localedir %{buildroot}%{_datadir}/locale/ %build # build gvim %if %{with_gvim} #LOCALEDIR=%{localedir} \ %configure \ --with-compiledby="%{packager}" \ --with-features=huge \ --with-x=yes \ --enable-gui=gnome2 \ --enable-gtk2-check \ --enable-xim \ --enable-fontset \ --enable-nls \ --enable-perlinterp \ --enable-pythoninterp \ --enable-tclinterp \ --enable-rubyinterp \ --enable-cscope \ --disable-acl \ --enable-multibyte # disable the '-g' option %make && mv src/vim src/gvim %make -C src clean CC=%{_target_platform}-gcc %endif # build vim #LOCALEDIR=%{localedir} \ %configure \ --with-compiledby="%{packager}" \ --with-features=huge \ --with-x=no \ --enable-gui=no \ --enable-nls \ --enable-perlinterp \ --enable-pythoninterp \ --enable-tclinterp \ --enable-rubyinterp \ --enable-cscope \ --disable-acl \ --enable-multibyte #sed -i ' # s,LOCALEDIR=$(DEST_LANG),LOCALEDIR=$(DESTDIR)$(prefix)/share/locale,g' \ #src/Makefile %make #% make lang %install [ "%{buildroot}" != / ] && rm -rf "%{buildroot}" %makeinstall ln -s vim %{buildroot}%{_bindir}/vi install -m 0644 -D %{S:2} %{buildroot}%{_sysconfdir}/skel/.vimrc install -m 0644 -D %{S:2} %{buildroot}/root/.vimrc %if %{with_gvim} install -m 0755 -D src/gvim %{buildroot}%{_bindir}/gvim %endif #%find_lang %{name} %clean [ "%{buildroot}" != / ] && rm -rf "%{buildroot}" %files %defattr(-,root,root) %{_bindir}/* %{_datadir}/vim/%{vimdir}/*.vim %{_datadir}/vim/%{vimdir}/autoload %{_datadir}/vim/%{vimdir}/colors %{_datadir}/vim/%{vimdir}/compiler %{_datadir}/vim/%{vimdir}/ftplugin %{_datadir}/vim/%{vimdir}/indent %{_datadir}/vim/%{vimdir}/keymap %{_datadir}/vim/%{vimdir}/lang %{_datadir}/vim/%{vimdir}/macros %{_datadir}/vim/%{vimdir}/plugin %{_datadir}/vim/%{vimdir}/print %{_datadir}/vim/%{vimdir}/spell %{_datadir}/vim/%{vimdir}/syntax %{_datadir}/vim/%{vimdir}/tools %{_sysconfdir}/skel/.vimrc %{_mandir}/man1/* %lang(fr) %{_mandir}/fr*/man1/ %lang(it) %{_mandir}/it*/man1/ %lang(ja) %{_mandir}/ja/man1/ %lang(it) %{_mandir}/it*/man1/ %lang(pl) %{_mandir}/pl*/man1/ %lang(ru) %{_mandir}/ru*/man1/ %if %{with_gvim} %{_bindir}/gvim %endif /root/.vimrc %files doc %defattr(-,root,root) %{_datadir}/vim/%{vimdir}/doc %files tutor %defattr(-,root,root) %{_datadir}/vim/%{vimdir}/tutor %changelog * Fri Oct 02 2015 Automatic Build System 7.4.884-1mamba - automatic version update by autodist * Thu Sep 17 2015 Automatic Build System 7.4.854-1mamba - automatic version update by autodist * Sun Jul 12 2015 Automatic Build System 7.4.778-1mamba - automatic version update by autodist * Fri Jul 03 2015 Automatic Build System 7.4.764-1mamba - automatic version update by autodist * Sun Jun 28 2015 Automatic Build System 7.4.738-1mamba - automatic version update by autodist * Mon May 18 2015 Automatic Build System 7.4.729-1mamba - automatic version update by autodist * Sat May 16 2015 Automatic Build System 7.4.723-1mamba - automatic version update by autodist * Tue Apr 28 2015 Automatic Build System 7.4.712-1mamba - automatic version update by autodist * Thu Mar 19 2015 Automatic Build System 7.4.663-1mamba - automatic version update by autodist * Fri Feb 06 2015 Automatic Build System 7.4.617-1mamba - automatic version update by autodist * Sun Jan 18 2015 Silvan Calarco 7.4.580-1mamba - update to 7.4.580 * Mon Dec 01 2014 Automatic Build System 7.4.537-1mamba - automatic version update by autodist * Tue Nov 25 2014 Automatic Build System 7.4.525-1mamba - automatic version update by autodist * Mon Oct 13 2014 Automatic Build System 7.4.473-1mamba - automatic version update by autodist * Thu Sep 25 2014 Automatic Build System 7.4.459-1mamba - automatic version update by autodist * Thu Aug 28 2014 Automatic Build System 7.4.410-1mamba - automatic version update by autodist * Wed Jul 30 2014 Automatic Build System 7.4.383-1mamba - automatic version update by autodist * Tue Jul 29 2014 Automatic Build System 7.4.373-1mamba - automatic version update by autodist * Wed Apr 09 2014 Silvan Calarco 7.4.258-1mamba - update to 7.4.253 * Sun Jan 12 2014 Silvan Calarco 7.4.142-1mamba - update to 7.4.142 * Sun Nov 17 2013 Silvan Calarco 7.4.094-1mamba - update to 7.4.094 * Fri Sep 13 2013 Automatic Build System 7.4.027-1mamba - update to 7.4.027 * Tue Aug 27 2013 Automatic Build System 7.4.009-1mamba - update to 7.4.009 * Sat Aug 10 2013 Automatic Build System 7.3.1287-1mamba - automatic version update by autodist * Wed Dec 01 2010 Silvan Calarco 7.3-2mamba - fix dependencies by unsetting use_internal_dependency_generator - update packager - added -doc and -tutor packages * Tue Nov 16 2010 Silvan Calarco 7.3-1mamba - update to 7.3 - also install .vimrc in /root * Thu May 06 2009 Ercole 'ercolinux' Carpanetto 7.2-2mamba - modified the .vimrc to add mode and command in the ruler, and make cursors keys works in edit mode - modified vendor and distribution * Fri Aug 29 2008 Silvan Calarco 7.2-1mamba - update to 7.2 * Mon May 14 2007 Aleph0 7.1-1mamba - update to 7.1 - modified xorg paths used when building gvim * Fri Jul 07 2006 Stefano Cotta Ramusino 7.0.037-1qilnx - update to version 7.0.037 by autospec * Mon Jun 26 2006 Davide Madrisan 6.4.010-2qilnx - updated vimrc file * Wed Apr 12 2006 Davide Madrisan 6.4.010-1qilnx - update to version 6.4.010 by autospec * Mon Oct 03 2005 Stefano Cotta Ramusino 6.3.090-1qilnx - updated to patch level 090 * Mon Aug 08 2005 Davide Madrisan 6.3.086-1qilnx - updated to patch level 086 * Thu Dec 16 2004 Davide Madrisan 6.3-3qilnx - security fix QSA-2004-064 (CAN-2004-1138) - added new patches from ftp://ftp.vim.org/pub/vim/patches/6.3/ * Wed Nov 17 2004 Davide Madrisan 6.3-2qilnx - rebuild with patches from ftp://ftp.vim.org/pub/vim/patches/6.3/ - fixed security issues in `vimspell.sh' and `tcltags' (insecure creation of temporary files) * Tue Jun 08 2004 Davide Madrisan 6.3-1qilnx - new version rebuild - added localisation * Tue Feb 17 2004 Davide Madrisan 6.2-1qilnx - new version rebuild * Mon Apr 23 2003 Silvan Calarco 6.1-4qilnx - added .vimrc default skeleton file * Mon Apr 17 2003 Silvan Calarco 6.1-3qilnx - removed Prefix definition - modified find_requires script to avoid a mistaken /bin/csh requirement * Mon Apr 14 2003 Mirko Cortillaro - modified file list and created infodir * Wed Apr 02 2003 Mirko Cortillaro - write a spec file for vim