# comment out if not nightly build #define nightly 20180604 #define gitcommit cf92a76 %bcond_without translations # rel to bump %define rel 1 # build will override this anyway, so let's skip it %define _fortify_cflags %nil %define vendor_version 0.11.3 %if 0%{!?mkrel:1} %define mkrel(c) %{1}%{?dist} %endif %if 0%{!?_iconsdir:1} %define _iconsdir %{_datadir}/icons %endif # Systems that have system luajit, which has patches for s390x and ppc64le # support that haven't been merged upstream. %if 0%{?centos} || 0%{?suse_version} %bcond_with system_luajit %else %ifarch aarch64 %arm64 %bcond_with system_luajit %else %bcond_without system_luajit %endif %endif Name: neovim Version: 0.11.3 Release: %mkrel 1 Summary: Vim-fork focused on extensibility and usability Group: Editors License: ASL 2.0 URL: https://neovim.io/ %if 0%{?nightly:1} Source0: https://github.com/neovim/neovim/archive/nightly/%{name}-%{version}-nightly%{nightly}.tar.gz %else Source0: https://github.com/neovim/neovim/archive/v%{version}/%{name}-%{version}.tar.gz %endif Source1: %{name}-%{vendor_version}-vendor.tar.gz BuildRequires: cmake BuildRequires: gcc %if %{with translations} BuildRequires: gettext %endif BuildRequires: gperf BuildRequires: make %if %{with system_luajit} BuildRequires: luajit,pkgconfig(luajit) %endif %if 0%{?epel} == 9 || 0%{?fedora} >=41 || 0%{?mageia} >= 9 BuildRequires: pkgconfig(termkey) BuildRequires: pkgconfig(jemalloc) BuildRequires: pkgconfig(libbsd) %endif Requires: %{name}-data >= %{version}-%{release} Provides: nvim = %{version}-%{release} Recommends: xclip Recommends: wl-clipboard Recommends: ripgrep Recommends: python3dist(pynvim) Recommends: npm(neovim) %if ! %{with system_luajit} ExcludeArch: ppc64le s390x %endif %description Neovim is a project that seeks to aggressively refactor Vim in order to: - Simplify maintenance and encourage contributions - Split the work between multiple developers - Enable advanced UIs without modifications to the core - Maximize extensibility %package data Summary: Data files for %{name} BuildArch: noarch %description data Data files for %{name}. %prep %setup -q -b1 %autosetup -p1 -n %{name}-%{?nightly:nightly}%{?!nightly:%{version}} sed -i "s|sys/end|bsd/sys/end|g" cmake.config/CMakeLists.txt %build # Make sure we have the dependencies. # Use system luajit, which has patches for s390x and ppc64le support that # haven't been merged upstream. mkdir -p .deps/build/ mv -f ../%{name}-%{vendor_version}-vendor .deps/build/downloads cmake -S cmake.deps -B .deps -G 'Unix Makefiles' -D CMAKE_BUILD_TYPE=RelWithDebInfo -DUSE_BUNDLED=ON \ %if %{with system_luajit} -DUSE_BUNDLED_LUAJIT=OFF \ %endif %nil cmake --build .deps # Now the build itself %cmake -G 'Unix Makefiles' \ %if %{with translations} -DENABLE_TRANSLATIONS=ON \ %endif -B build %make_build -C build %install %make_install -C build %if %{with translations} %find_lang nvim %endif %files %license LICENSE.txt %doc CONTRIBUTING.md README.md %{_bindir}/nvim %{_mandir}/man1/nvim.1* %{_iconsdir}/hicolor/*/apps/nvim.png %{_datadir}/applications/nvim.desktop %{_libdir}/nvim/parser %files data -f nvim.lang %{_datadir}/nvim/