## START: Set by rpmautospec ## (rpmautospec version 0.8.4) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 1; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} ## END: Set by rpmautospec %bcond gui 1 %bcond lua 1 %bcond netbeans 1 %bcond perl 1 %bcond selinux 1 %bcond default_editor %{undefined rhel} %bcond gpm %{undefined rhel} %bcond ruby %{undefined flatpak} %bcond desktop_file %{with gui} # VIm upstream wants to build with FORTIFY_SOURCE=1, # because higher levels causes crashes of valid code constructs # and their reimplementation would cost unnecessary maintenance # https://github.com/vim/vim/pull/3507 %define _fortify_level 1 # if %%{binsuffix} is non-empty, it will be appended to the name of all binaries # and manual pages. an optional subpackage, vim-classic-as-vim, then symlinks # them back. %define binsuffix -classic %define topdir %{name} %define vimdir vim%(echo %{version}|awk -F. '{print $1 $2}') # NOTE(vim-classic): %%{topdir} by default is /usr/share/vim; this needlessly # conflicts with the proper vim package, so we move it. we are overriding # VIMDIR, which is defined in a block of src/Makefile where modifications are # discouraged. however, this specific variable is only used to set VIMLOC and # VIMRTLOC, both of which we want to modify in this exact way (and are # encouraged by the Makefile to do so). overwriting MAKE is needed, so our # change takes precedence over the pre-defined variable. # there is no --with-vimdiff-name, but we can cheese it here %define make_vars VIMDIR=/%{topdir} MAKE="make -e" VIMDIFFNAME=vimdiff%{binsuffix} VIMTUTORNAME=vimtutor%{binsuffix} Summary: The VIM editor URL: http://www.vim-classic.org/ Name: vim-classic Version: 8.3.0 Release: %autorelease License: Vim and MIT Source0: https://git.sr.ht/~sircmpwn/%{name}/archive/v%{version}.tar.gz Source1: virc Source2: vimrc Source9: vim-classic-default-editor.sh Source10: vim-classic-default-editor.csh Source11: vim-classic-default-editor.fish Patch2000: vim-8.3-fixkeys.patch # https://git.sr.ht/~sircmpwn/vim-classic/commit/24ccc847eeed1ac5b6d29f55e98a922245c0e04d # https://git.sr.ht/~sircmpwn/vim-classic/commit/f78d35b098eeb88517b620419b6a28976afe9ff0 # https://git.sr.ht/~sircmpwn/vim-classic/commit/40079151305738c57ff8c13d926b9279798084c5 Patch3007: vim-8.3-fortify-source.patch # https://git.sr.ht/~sircmpwn/vim-classic/commit/aa7c2c6e071eaf37019f14ad531cfdddc3076f2f Patch3008: vim-8.3-fixruby.patch # don't ever set mouse (Fedora downstream patch) Patch3006: vim-8.3-copy-paste.patch # temporary patch, might upstream to vim-classic Patch6666: 0001-allow-overriding-vimtutor-name.patch # uses autoconf in spec file BuildRequires: autoconf %if %{with desktop_file} # for /usr/bin/desktop-file-install BuildRequires: desktop-file-utils Requires: desktop-file-utils %endif # gcc is no longer in buildroot by default BuildRequires: gcc # for translations BuildRequires: gettext # glibc in F35 bootstraped several conversion formats from # iconv into a separate package. Vim needs those additional # formats during compilation. # remove the conditional once F34 is EOL and leave # only BuildRequires here %if 0%{?fedora} >= 35 BuildRequires: glibc-gconv-extra %endif %if %{with gpm} # for mouse support in console BuildRequires: gpm-devel %endif # for setting ACL on created files BuildRequires: libacl-devel # selinux support %if %{with selinux} BuildRequires: libselinux-devel %endif # for lua plugin %if %{with lua} BuildRequires: lua-devel %endif # uses make BuildRequires: make # screen handling library BuildRequires: ncurses-devel # for perl plugin %if %{with perl} BuildRequires: perl-devel BuildRequires: perl-generators BuildRequires: perl(ExtUtils::Embed) BuildRequires: perl(ExtUtils::ParseXS) %endif # for python plugin BuildRequires: python3-devel # for ruby plugin %if %{with ruby} BuildRequires: ruby BuildRequires: ruby-devel %endif %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. %package common Summary: The common files needed by any version of the VIM editor # shared files between common and minimal Requires: %{name}-data = %{version}-%{release} Requires: %{name}-filesystem #Conflicts: vim-common %description common 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. The vim-classic-common package contains files which every VIM binary will need in order to run. If you are installing vim-classic-enhanced or vim-classic-X11, you'll also need to install the vim-classic-common package. %package minimal Summary: A minimal version of the VIM editor #Conflicts: vim-minimal #Provides: vim-minimal #Provides: vi #Provides: %%{_bindir}/vi # shared files between common and minimal Requires: %{name}-data = %{version}-%{release} %description minimal 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. The vim-classic-minimal package includes a minimal version of VIM, providing the commands vi, view, ex, rvi, and rview. NOTE: The online help is only available when the vim-classic-common package is installed. %package enhanced Summary: A version of the VIM editor which includes recent enhancements # vim bundles libvterm, which is used during build - so we need to provide # bundled libvterm for catching possible libvterm CVEs Provides: bundled(libvterm) #Conflicts: vim #Provides: vim #Conflicts: vim-enhanced #Provides: vim-enhanced Provides: vim-classic #Provides: %%{_bindir}/vim Requires: %{name}-common = %{version}-%{release} # required for vimtutor (#395371) Requires: which Suggests: python3 Suggests: python3-libs # suggest python3, lua, ruby and perl packages because of their # embedded functionality in Vim/GVim %if %{with lua} Suggests: lua-libs %endif %if %{with perl} Suggests: perl-devel Suggests: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) %endif %if %{with ruby} Suggests: ruby Suggests: ruby-libs %endif %description enhanced 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. The vim-classic-enhanced package contains a version of VIM with extra, recently introduced features like Python and Perl interpreters. Install the vim-classic-enhanced package if you'd like to use a version of the VIM editor which includes recently added enhancements like interpreters for the Python and Perl scripting languages. You'll also need to install the vim-classic-common package. %package filesystem Summary: VIM filesystem layout BuildArch: noarch %Description filesystem This package provides some directories which are required by other packages that add vim files, p.e. additional syntax files or filetypes. %if %{with gui} %package X11 Summary: The VIM version of the vi editor for the X Window System - GVim # devel of libICE, gtk3, libSM, libX11, libXpm and libXt are needed in buildroot # so configure script can have correct macros enabled for GUI (#1603272) # generic gnome toolkit for graphical support BuildRequires: gtk3-devel # inter-client exchange library - for X session management protocol BuildRequires: libICE-devel # X session management library BuildRequires: libSM-devel # core X11 protocol client library BuildRequires: libX11-devel # X PixMap library for X11 - for creating images in X PixMap format BuildRequires: libXpm-devel # X Toolkit Intrinsics library - working with widgets? BuildRequires: libXt-devel # for sound support BuildRequires: libcanberra-devel #Conflicts: vim-X11 #Provides: vim-X11 #Provides: gvim Provides: gvim-classic #Provides: %%{_bindir}/gvim # GVIM graphics are based on GTK3 Requires: gtk3 # needed for icons (#226526) Requires: hicolor-icon-theme # for getting/setting extended attributes - they are pairs (name:value) # from inodes (files, dirs etc.) Requires: libattr >= 2.4 Requires: %{name}-common = %{version}-%{release} Suggests: python3 Suggests: python3-libs # suggest python3, lua, ruby and perl packages because of their # embedded functionality in Vim/GVim %if %{with lua} Suggests: lua-libs %endif %if %{with perl} Suggests: perl-devel Suggests: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) %endif %if %{with ruby} Suggests: ruby Suggests: ruby-libs %endif %description X11 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 by command gvim. Install the vim-classic-X11 package if you'd like to try out a version of vi with graphics and mouse capabilities. You'll also need to install the vim-classic-common package. %endif %package data Summary: Shared data for Vi and Vim BuildArch: noarch %description data The subpackage is used for shipping files and directories, which need to be shared between vim-classic-minimal and vim-classic-common packages. %if %{with default_editor} %package default-editor Summary: Set vim-classic as the default editor BuildArch: noarch Conflicts: system-default-editor Provides: system-default-editor Requires: %{name}-enhanced %description default-editor This subpackage contains files needed to set Vim as the default editor. %endif %prep %autosetup -p1 -n %{name}-v%{version} %build cd src autoconf # added -std=c17 because F42 uses c23 by default and dynamically loaded Ruby plugin fails to build # with c23 due using `()` for callback arguments to be able to use callbacks with different number # of arguments in one function # reported upstream as https://github.com/vim/vim/issues/16575 export CFLAGS="%{optflags} -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -std=c17" export CXXFLAGS="%{optflags} -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -std=c17" cp -f os_unix.h os_unix.h.save # Configure options: # --enable-fail-if-missing - we need to fail if configure options aren't satisfied # --with-features - for setting how big amount of features is enabled # --enable-multibyte - enabling multibyte editing support - for editing files in languages, which one character # cannot be represented by one byte - Asian languages, Unicode # --disable-netbeans - disabling socket interface for integrating Vim into NetBeans IDE # --enable-selinux - enabling selinux support # --enable-Ninterp - enabling internal interpreter # --with-x - yes if we want X11 support (graphical Vim for X11) # --with-tlib - which terminal library to use # --disable-gpm - disabling support for General Purpose Mouse - Linux mouse daemon perl -pi -e "s/vimrc/virc/" os_unix.h %configure CFLAGS="${CFLAGS} -DSYS_VIMRC_FILE='\"/etc/virc\"'" \ --with-vim-name=vim%{binsuffix} \ --with-ex-name=ex%{binsuffix} \ --with-view-name=view%{binsuffix} \ --with-xxd-name=xxd%{binsuffix} \ --prefix=%{_prefix} --with-features=small --with-x=no \ --enable-multibyte \ --disable-netbeans \ %if %{with selinux} --enable-selinux \ %else --disable-selinux \ %endif --disable-pythoninterp --disable-perlinterp --disable-tclinterp \ --with-tlib=ncurses --enable-gui=no --disable-gpm --exec-prefix=/ \ --with-compiledby="" \ --with-modified-by="" \ --enable-fail-if-missing \ --disable-canberra %make_build %{make_vars} cp vim%{binsuffix} minimal-vim make clean %{make_vars} mv -f os_unix.h.save os_unix.h %if %{with gui} # More configure options: # --enable-xim - enabling X Input Method - international input module for X, # it is for multibyte languages in Vim with X # --enable-termtruecolor - use terminal with true colors %configure CFLAGS="${CFLAGS} -DSYS_VIMRC_FILE='\"/etc/vimrc\"'" \ --with-vim-name=vim%{binsuffix} \ --with-ex-name=ex%{binsuffix} \ --with-view-name=view%{binsuffix} \ --with-xxd-name=xxd%{binsuffix} \ --with-features=huge \ --enable-python3interp=dynamic \ %if %{with perl} --enable-perlinterp=dynamic \ %else --disable-perlinterp \ %endif --disable-tclinterp --with-x=yes \ --enable-xim --enable-multibyte \ --with-tlib=ncurses \ --enable-gtk3-check --enable-gui=gtk3 \ --with-compiledby="" --enable-cscope \ --with-modified-by="" \ %if %{with netbeans} --enable-netbeans \ %else --disable-netbeans \ %endif %if %{with selinux} --enable-selinux \ %else --disable-selinux \ %endif %if %{with ruby} --enable-rubyinterp=dynamic \ %else --disable-rubyinterp \ %endif %if %{with lua} --enable-luainterp=dynamic \ %else --disable-luainterp \ %endif --enable-fail-if-missing \ --enable-canberra %make_build %{make_vars} cp vim%{binsuffix} gvim make clean %{make_vars} %endif %configure CFLAGS="${CFLAGS} -DSYS_VIMRC_FILE='\"/etc/vimrc\"'" \ --with-vim-name=vim%{binsuffix} \ --with-ex-name=ex%{binsuffix} \ --with-view-name=view%{binsuffix} \ --with-xxd-name=xxd%{binsuffix} \ --prefix=%{_prefix} --with-features=huge \ --enable-python3interp=dynamic \ %if %{with perl} --enable-perlinterp=dynamic \ %else --disable-perlinterp \ %endif --disable-tclinterp \ --with-x=no \ --enable-gui=no --exec-prefix=%{_prefix} --enable-multibyte \ --enable-cscope --with-modified-by="" \ --with-tlib=ncurses \ --with-compiledby="" \ %if %{with gpm} --enable-gpm \ %else --disable-gpm \ %endif %if %{with netbeans} --enable-netbeans \ %else --disable-netbeans \ %endif %if %{with selinux} --enable-selinux \ %else --disable-selinux \ %endif %if %{with ruby} --enable-rubyinterp=dynamic \ %else --disable-rubyinterp \ %endif %if %{with lua} --enable-luainterp=dynamic \ %else --disable-luainterp \ %endif --enable-fail-if-missing \ --disable-canberra %make_build %{make_vars} cp vim%{binsuffix} enhanced-vim %install mkdir -p %{buildroot}/%{_bindir} mkdir -p %{buildroot}/%{_datadir}/%{topdir}/vimfiles/{after,autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} mkdir -p %{buildroot}/%{_datadir}/%{topdir}/vimfiles/after/{autoload,colors,compiler,doc,ftdetect,ftplugin,indent,keymap,lang,plugin,print,spell,syntax,tutor} cp runtime/doc/uganda.txt LICENSE # Those aren't Linux info files but some binary files for Amiga: rm -f README*.info cd src # Adding STRIP=/bin/true, because Vim wants to strip the binaries by himself # and put the stripped files into correct dirs. Build system (koji/brew) # does it for us, so there is no need to do it in Vim %make_install BINDIR=%{_bindir} STRIP=/bin/true %{make_vars} # make install creates vim binary and view symlink, they will be wrappers # so remove them here rm -f %{buildroot}%{_bindir}/{vim,view}%{binsuffix} mkdir -p %{buildroot}%{_libexecdir} install -m755 minimal-vim %{buildroot}%{_libexecdir}/vi%{binsuffix} install -m755 enhanced-vim %{buildroot}%{_bindir}/vim%{binsuffix} %if %{with gui} make installgtutorbin DESTDIR=%{buildroot} BINDIR=%{_bindir} %{make_vars} # NOTE(vim-classic): --with-vim-name still keeps *.png and *.desktop files untouched. bit hacky. for i in %{buildroot}/%{_datadir}/icons/{hicolor,locolor}/*/apps/gvim.png; do mv "$i" "${i%.*}%{binsuffix}.${i##*.}" done for i in %{buildroot}/%{_datadir}/applications/{vim,gvim}.desktop; do sed -i 's/Exec=g\?vim/&%{binsuffix}/' "$i" sed -i 's/Icon=g\?vim/&%{binsuffix}/' "$i" sed -i '/^Name/s/$/ Classic/' "$i" mv "$i" "${i%.*}%{binsuffix}.${i##*.}" done install -m755 gvim %{buildroot}%{_bindir}/gvim%{binsuffix} # NOTE(vim-classic): vim.spec inlines a custom gvim.appdata.xml here - seems unnecessary. for i in gvim gex gview vimx; do echo ".so man1/vim%{binsuffix}.1" > %{buildroot}/%{_mandir}/man1/$i%{binsuffix}.1 done echo ".so man1/vimdiff%{binsuffix}.1" > %{buildroot}/%{_mandir}/man1/gvimdiff%{binsuffix}.1 echo ".so man1/vimtutor%{binsuffix}.1" > %{buildroot}/%{_mandir}/man1/gvimtutor%{binsuffix}.1 %else # Remove files included in X11 subpackage, but built by default: rm %{buildroot}/%{_mandir}/man1/evim.* rm %{buildroot}/%{_datadir}/applications/{vim,gvim}.desktop rm %{buildroot}/%{_datadir}/icons/{hicolor,locolor}/*/apps/gvim.png %endif ( cd %{buildroot} ln -sf %{_libexecdir}/vi%{binsuffix} .%{_bindir}/rvi%{binsuffix} ln -sf %{_libexecdir}/vi%{binsuffix} .%{_bindir}/rview%{binsuffix} ln -sf %{_libexecdir}/vi%{binsuffix} .%{_bindir}/ex%{binsuffix} # NOTE(vim-classic): vim.spec provides /bin/vi and /bin/view using *_wrapper scripts. we don't, for now. ln -sf %{_libexecdir}/vi%{binsuffix} .%{_bindir}/vi%{binsuffix} ln -sf %{_libexecdir}/vi%{binsuffix} .%{_bindir}/view%{binsuffix} ln -sf vim%{binsuffix} .%{_bindir}/rvim%{binsuffix} ln -sf vim%{binsuffix} .%{_bindir}/vimdiff%{binsuffix} perl -pi -e "s,%{buildroot},," .%{_mandir}/man1/vim%{binsuffix}.1 .%{_mandir}/man1/vimtutor%{binsuffix}.1 rm -f .%{_mandir}/man1/rvim%{binsuffix}.1 cp -p .%{_mandir}/man1/vim%{binsuffix}.1 .%{_mandir}/man1/vi%{binsuffix}.1 ln -sf vi%{binsuffix}.1.gz .%{_mandir}/man1/rvi%{binsuffix}.1.gz ln -sf vi%{binsuffix}.1.gz .%{_mandir}/man1/ex%{binsuffix}.1 ln -sf vi%{binsuffix}.1.gz .%{_mandir}/man1/view%{binsuffix}.1 ln -sf vi%{binsuffix}.1.gz .%{_mandir}/man1/rview%{binsuffix}.1 ln -sf vim%{binsuffix}.1.gz .%{_mandir}/man1/vimdiff%{binsuffix}.1.gz %if %{with gui} ln -sf gvim%{binsuffix} ./%{_bindir}/gview%{binsuffix} ln -sf gvim%{binsuffix} ./%{_bindir}/gex%{binsuffix} ln -sf gvim%{binsuffix} ./%{_bindir}/evim%{binsuffix} ln -sf gvim%{binsuffix} ./%{_bindir}/gvimdiff%{binsuffix} ln -sf gvim%{binsuffix} ./%{_bindir}/vimx%{binsuffix} # XXX(vim-classic): TODO! %if %{with desktop_file} desktop-file-install \ --dir %{buildroot}/%{_datadir}/applications \ %{buildroot}/%{_datadir}/applications/gvim%{binsuffix}.desktop # --add-category "Development;TextEditor;X-Red-Hat-Base" D\ %else mkdir -p ./%{_sysconfdir}/X11/applnk/Applications cp %{buildroot}/%{_datadir}/applications/gvim%{binsuffix}.desktop ./%{_sysconfdir}/X11/applnk/Applications/gvim%{binsuffix}.desktop %endif %endif # ja_JP.ujis is obsolete, ja_JP.eucJP is recommended. ( cd ./%{_datadir}/%{topdir}/%{vimdir}/lang; \ ln -sf menu_ja_jp.ujis.vim menu_ja_jp.eucjp.vim ) ) pushd %{buildroot}/%{_datadir}/%{topdir}/%{vimdir}/tutor mkdir conv iconv -f CP1252 -t UTF8 tutor.ca > conv/tutor.ca iconv -f CP1252 -t UTF8 tutor.it > conv/tutor.it #iconv -f CP1253 -t UTF8 tutor.gr > conv/tutor.gr iconv -f CP1252 -t UTF8 tutor.fr > conv/tutor.fr iconv -f CP1252 -t UTF8 tutor.es > conv/tutor.es iconv -f CP1252 -t UTF8 tutor.de > conv/tutor.de #iconv -f CP737 -t UTF8 tutor.gr.cp737 > conv/tutor.gr.cp737 #iconv -f EUC-JP -t UTF8 tutor.ja.euc > conv/tutor.ja.euc #iconv -f SJIS -t UTF8 tutor.ja.sjis > conv/tutor.ja.sjis iconv -f UTF8 -t UTF8 tutor.ja.utf-8 > conv/tutor.ja.utf-8 iconv -f UTF8 -t UTF8 tutor.ko.utf-8 > conv/tutor.ko.utf-8 iconv -f CP1252 -t UTF8 tutor.no > conv/tutor.no iconv -f ISO-8859-2 -t UTF8 tutor.pl > conv/tutor.pl iconv -f ISO-8859-2 -t UTF8 tutor.sk > conv/tutor.sk iconv -f KOI8R -t UTF8 tutor.ru > conv/tutor.ru iconv -f CP1252 -t UTF8 tutor.sv > conv/tutor.sv mv -f tutor.ja.euc tutor.ja.sjis tutor.ko.euc tutor.pl.cp1250 tutor.zh.big5 tutor.ru.cp1251 tutor.zh.euc tutor.sr.cp1250 tutor.sr.utf-8 conv/ rm -f tutor.ca tutor.de tutor.es tutor.fr tutor.gr tutor.it tutor.ja.utf-8 tutor.ko.utf-8 tutor.no tutor.pl tutor.sk tutor.ru tutor.sv mv -f conv/* . rmdir conv popd # Dependency cleanups chmod 644 %{buildroot}/%{_datadir}/%{topdir}/%{vimdir}/doc/vim2html.pl chmod 644 ../runtime/doc/vim2html.pl mkdir -p %{buildroot}%{_sysconfdir} install -p -m644 %{SOURCE1} %{buildroot}%{_sysconfdir}/virc%{binsuffix} install -p -m644 %{SOURCE2} %{buildroot}%{_sysconfdir}/vimrc%{binsuffix} # if Vim isn't built for Fedora, use redhat augroup %if 0%{?rhel} >= 7 sed -i -e "s/augroup fedora/augroup redhat/" %{buildroot}/%{_sysconfdir}/vimrc%{binsuffix} sed -i -e "s/augroup fedora/augroup redhat/" %{buildroot}/%{_sysconfdir}/virc%{binsuffix} %endif %if %{with default_editor} mkdir -p %{buildroot}/%{_sysconfdir}/profile.d install -p -m644 %{SOURCE9} %{buildroot}/%{_sysconfdir}/profile.d/%{name}-default-editor.sh install -p -m644 %{SOURCE10} %{buildroot}/%{_sysconfdir}/profile.d/%{name}-default-editor.csh mkdir -p %{buildroot}/%{_datadir}/fish/vendor_conf.d/ install -p -m644 %{SOURCE11} %{buildroot}/%{_datadir}/fish/vendor_conf.d/%{name}-default-editor.fish %endif mkdir -p %{buildroot}%{_rpmconfigdir}/macros.d/ (cd ../runtime; rm -rf doc; ln -svf ../../%{topdir}/%{vimdir}/doc docs;) rm -f %{buildroot}/%{_datadir}/%{topdir}/%{vimdir}/macros/maze/maze*.c rm -rf %{buildroot}/%{_datadir}/%{topdir}/%{vimdir}/tools rm -rf %{buildroot}/%{_datadir}/%{topdir}/%{vimdir}/doc/vim2html.pl rm -f %{buildroot}/%{_datadir}/%{topdir}/%{vimdir}/tutor/tutor.gr.utf-8~ # Remove not UTF-8 manpages for i in pl.ISO8859-2 it.ISO8859-1 ru.KOI8-R fr.ISO8859-1 da.ISO8859-1 de.ISO8859-1 tr.ISO8859-9; do rm -rf %{buildroot}/%{_mandir}/$i done # use common man1/ru directory mv %{buildroot}/%{_mandir}/ru.UTF-8 %{buildroot}/%{_mandir}/ru # Remove duplicate man pages for i in fr.UTF-8 it.UTF-8 pl.UTF-8 da.UTF-8 de.UTF-8 tr.UTF-8; do rm -rf %{buildroot}/%{_mandir}/$i done # Install symlink for rvim man page echo ".so man1/vim%{binsuffix}.1" > %{buildroot}/%{_mandir}/man1/rvim%{binsuffix}.1 mkdir -p %{buildroot}/%{_mandir}/man5 echo ".so man1/vim%{binsuffix}.1" > %{buildroot}/%{_mandir}/man5/vimrc%{binsuffix}.5 echo ".so man1/vi%{binsuffix}.1" > %{buildroot}/%{_mandir}/man5/virc%{binsuffix}.5 touch %{buildroot}/%{_datadir}/%{topdir}/vimfiles/doc/tags # Refresh documentation helptags %transfiletriggerin common -- %{_datadir}/%{topdir}/vimfiles/doc %{_bindir}/vim -c ":helptags %{_datadir}/%{topdir}/vimfiles/doc" -c :q &> /dev/null || : %transfiletriggerpostun common -- %{_datadir}/%{topdir}/vimfiles/doc > %{_datadir}/%{topdir}/vimfiles/doc/tags || : %{_bindir}/vim -c ":helptags %{_datadir}/%{topdir}/vimfiles/doc" -c :q &> /dev/null || : %files common %config(noreplace) %{_sysconfdir}/vimrc%{binsuffix} %{!?_licensedir:%global license %%doc} %doc README* %doc runtime/docs %{_datadir}/%{topdir}/%{vimdir}/rgb.txt %{_datadir}/%{topdir}/%{vimdir}/autoload %{_datadir}/%{topdir}/%{vimdir}/colors %{_datadir}/%{topdir}/%{vimdir}/compiler %{_datadir}/%{topdir}/%{vimdir}/pack %{_datadir}/%{topdir}/%{vimdir}/doc %{_datadir}/%{topdir}/%{vimdir}/*.vim %exclude %{_datadir}/%{topdir}/%{vimdir}/defaults.vim %{_datadir}/%{topdir}/%{vimdir}/ftplugin %{_datadir}/%{topdir}/%{vimdir}/indent %{_datadir}/%{topdir}/%{vimdir}/keymap %{_datadir}/%{topdir}/%{vimdir}/lang/*.vim %{_datadir}/%{topdir}/%{vimdir}/lang/*.txt %dir %{_datadir}/%{topdir}/%{vimdir}/lang %{_datadir}/%{topdir}/%{vimdir}/macros %{_datadir}/%{topdir}/%{vimdir}/plugin %{_datadir}/%{topdir}/%{vimdir}/print %{_datadir}/%{topdir}/%{vimdir}/syntax %{_datadir}/%{topdir}/%{vimdir}/tutor %{_datadir}/%{topdir}/%{vimdir}/spell %lang(af) %{_datadir}/%{topdir}/%{vimdir}/lang/af %lang(ca) %{_datadir}/%{topdir}/%{vimdir}/lang/ca %lang(cs) %{_datadir}/%{topdir}/%{vimdir}/lang/cs %lang(cs.cp1250) %{_datadir}/%{topdir}/%{vimdir}/lang/cs.cp1250 %lang(da) %{_datadir}/%{topdir}/%{vimdir}/lang/da %lang(de) %{_datadir}/%{topdir}/%{vimdir}/lang/de %lang(en_GB) %{_datadir}/%{topdir}/%{vimdir}/lang/en_GB %lang(eo) %{_datadir}/%{topdir}/%{vimdir}/lang/eo %lang(es) %{_datadir}/%{topdir}/%{vimdir}/lang/es %lang(fi) %{_datadir}/%{topdir}/%{vimdir}/lang/fi %lang(fr) %{_datadir}/%{topdir}/%{vimdir}/lang/fr %lang(ga) %{_datadir}/%{topdir}/%{vimdir}/lang/ga %lang(it) %{_datadir}/%{topdir}/%{vimdir}/lang/it %lang(ja) %{_datadir}/%{topdir}/%{vimdir}/lang/ja %lang(ja.euc-jp) %{_datadir}/%{topdir}/%{vimdir}/lang/ja.euc-jp %lang(ja.sjis) %{_datadir}/%{topdir}/%{vimdir}/lang/ja.sjis %lang(ko) %{_datadir}/%{topdir}/%{vimdir}/lang/ko %lang(ko) %{_datadir}/%{topdir}/%{vimdir}/lang/ko.UTF-8 %lang(lv) %{_datadir}/%{topdir}/%{vimdir}/lang/lv %lang(nb) %{_datadir}/%{topdir}/%{vimdir}/lang/nb %lang(nl) %{_datadir}/%{topdir}/%{vimdir}/lang/nl %lang(no) %{_datadir}/%{topdir}/%{vimdir}/lang/no %lang(pl) %{_datadir}/%{topdir}/%{vimdir}/lang/pl %lang(pl.UTF-8) %{_datadir}/%{topdir}/%{vimdir}/lang/pl.UTF-8 %lang(pl.cp1250) %{_datadir}/%{topdir}/%{vimdir}/lang/pl.cp1250 %lang(pt_BR) %{_datadir}/%{topdir}/%{vimdir}/lang/pt_BR %lang(ru) %{_datadir}/%{topdir}/%{vimdir}/lang/ru %lang(ru.cp1251) %{_datadir}/%{topdir}/%{vimdir}/lang/ru.cp1251 %lang(sk) %{_datadir}/%{topdir}/%{vimdir}/lang/sk %lang(sk.cp1250) %{_datadir}/%{topdir}/%{vimdir}/lang/sk.cp1250 %lang(sr) %{_datadir}/%{topdir}/%{vimdir}/lang/sr %lang(sv) %{_datadir}/%{topdir}/%{vimdir}/lang/sv %lang(tr) %{_datadir}/%{topdir}/%{vimdir}/lang/tr %lang(uk) %{_datadir}/%{topdir}/%{vimdir}/lang/uk %lang(uk.cp1251) %{_datadir}/%{topdir}/%{vimdir}/lang/uk.cp1251 %lang(vi) %{_datadir}/%{topdir}/%{vimdir}/lang/vi %lang(zh_CN) %{_datadir}/%{topdir}/%{vimdir}/lang/zh_CN %lang(zh_CN.cp936) %{_datadir}/%{topdir}/%{vimdir}/lang/zh_CN.cp936 %lang(zh_TW) %{_datadir}/%{topdir}/%{vimdir}/lang/zh_TW %lang(zh_CN.UTF-8) %{_datadir}/%{topdir}/%{vimdir}/lang/zh_CN.UTF-8 %lang(zh_TW.UTF-8) %{_datadir}/%{topdir}/%{vimdir}/lang/zh_TW.UTF-8 /%{_bindir}/xxd%{binsuffix} %{_mandir}/man1/rvim%{binsuffix}.* %{_mandir}/man1/vim%{binsuffix}.* %{_mandir}/man1/vimdiff%{binsuffix}.* %{_mandir}/man1/vimtutor%{binsuffix}.* %{_mandir}/man1/xxd%{binsuffix}.* %{_mandir}/man5/vimrc%{binsuffix}.* %if %{with gui} %{_mandir}/man1/gex%{binsuffix}.* %{_mandir}/man1/gview%{binsuffix}.* %{_mandir}/man1/gvim*%{binsuffix}* %{_mandir}/man1/vimx%{binsuffix}.* %endif %lang(fr) %{_mandir}/fr/man1/* %lang(da) %{_mandir}/da/man1/* %lang(de) %{_mandir}/de/man1/* %lang(it) %{_mandir}/it/man1/* %lang(ja) %{_mandir}/ja/man1/* %lang(pl) %{_mandir}/pl/man1/* %lang(ru) %{_mandir}/ru/man1/* %lang(tr) %{_mandir}/tr/man1/* %files minimal %config(noreplace) %{_sysconfdir}/virc%{binsuffix} %{_bindir}/ex%{binsuffix} %{_bindir}/rvi%{binsuffix} %{_bindir}/rview%{binsuffix} %{_bindir}/vi%{binsuffix} %{_bindir}/view%{binsuffix} %{_libexecdir}/vi%{binsuffix} %{_mandir}/man1/vi%{binsuffix}.* %{_mandir}/man1/ex%{binsuffix}.* %{_mandir}/man1/rvi%{binsuffix}.* %{_mandir}/man1/rview%{binsuffix}.* %{_mandir}/man1/view%{binsuffix}.* %{_mandir}/man5/virc%{binsuffix}.* %files enhanced %{_bindir}/rvim%{binsuffix} %{_bindir}/vim%{binsuffix} %{_bindir}/vimdiff%{binsuffix} %{_bindir}/vimtutor%{binsuffix} %files filesystem %dir %{_datadir}/%{topdir}/vimfiles/after %dir %{_datadir}/%{topdir}/vimfiles/after/* %dir %{_datadir}/%{topdir}/vimfiles/autoload %dir %{_datadir}/%{topdir}/vimfiles/colors %dir %{_datadir}/%{topdir}/vimfiles/compiler %dir %{_datadir}/%{topdir}/vimfiles/doc %ghost %{_datadir}/%{topdir}/vimfiles/doc/tags %dir %{_datadir}/%{topdir}/vimfiles/ftdetect %dir %{_datadir}/%{topdir}/vimfiles/ftplugin %dir %{_datadir}/%{topdir}/vimfiles/indent %dir %{_datadir}/%{topdir}/vimfiles/keymap %dir %{_datadir}/%{topdir}/vimfiles/lang %dir %{_datadir}/%{topdir}/vimfiles/plugin %dir %{_datadir}/%{topdir}/vimfiles/print %dir %{_datadir}/%{topdir}/vimfiles/spell %dir %{_datadir}/%{topdir}/vimfiles/syntax %dir %{_datadir}/%{topdir}/vimfiles/tutor %if %{with gui} %files X11 %if %{with desktop_file} /%{_datadir}/applications/* %exclude /%{_datadir}/applications/vim%{binsuffix}.desktop %else /%{_sysconfdir}/X11/applnk/*/gvim%{binsuffix}.desktop %endif %{_bindir}/gvimtutor%{binsuffix} %{_bindir}/gvim%{binsuffix} %{_bindir}/gvimdiff%{binsuffix} %{_bindir}/gview%{binsuffix} %{_bindir}/gex%{binsuffix} %{_bindir}/vimtutor%{binsuffix} %{_bindir}/vimx%{binsuffix} %{_bindir}/evim%{binsuffix} %{_mandir}/man1/evim%{binsuffix}.* %dir %{_datadir}/icons/hicolor %dir %{_datadir}/icons/hicolor/* %dir %{_datadir}/icons/hicolor/*/apps %{_datadir}/icons/hicolor/*/apps/* %dir %{_datadir}/icons/locolor %dir %{_datadir}/icons/locolor/* %dir %{_datadir}/icons/locolor/*/apps %{_datadir}/icons/locolor/*/apps/* %endif %files data %license LICENSE %dir %{_datadir}/%{topdir} %dir %{_datadir}/%{topdir}/%{vimdir} %{_datadir}/%{topdir}/%{vimdir}/defaults.vim %dir %{_datadir}/%{topdir}/vimfiles %if %{with default_editor} %files default-editor %dir %{_datadir}/fish/vendor_conf.d %{_datadir}/fish/vendor_conf.d/%{name}-default-editor.fish %config(noreplace) %{_sysconfdir}/profile.d/%{name}-default-editor.* %endif %changelog ## START: Generated by rpmautospec * Sat Aug 29 2026 John Doe - 8.3.0-1 - Uncommitted changes ## END: Generated by rpmautospec