]> git.pld-linux.org Git - packages/neovim.git/blame - neovim.spec
build with most of the system libs
[packages/neovim.git] / neovim.spec
CommitLineData
0a9d0af1
ER
1# TODO
2# - -rt subpackage? -lang subpackage?
ccead671
ER
3#
4# Conditional build:
5%bcond_with lua # LUA
6
0a9d0af1
ER
7Summary: Vim-fork focused on extensibility and agility
8Name: neovim
9Version: 0.1.5
7d69921c 10Release: 0.4
0a9d0af1
ER
11License: Apache v2.0
12Group: Applications/Editors/Vim
13Source0: https://github.com/neovim/neovim/archive/v%{version}/%{name}-%{version}.tar.gz
14URL: https://neovim.io/
15Source1: %{name}.desktop
16Source2: %{name}.svg
ccead671 17BuildRequires: cmake >= 2.8.7
0a9d0af1 18BuildRequires: fdupes
ccead671 19BuildRequires: gcc >= 6:4.4
0a9d0af1
ER
20BuildRequires: hicolor-icon-theme
21BuildRequires: jemalloc-devel
0a9d0af1 22BuildRequires: libstdc++-devel
ccead671 23BuildRequires: libtermkey-devel
0a9d0af1 24BuildRequires: libuv-devel
7d69921c
ER
25BuildRequires: libvterm-devel
26BuildRequires: msgpack-devel >= 1.1.0
ccead671 27BuildRequires: pkgconfig
ccead671
ER
28BuildRequires: rpmbuild(macros) >= 1.596
29BuildRequires: unibilium-devel
30%if %{with lua}
7d69921c
ER
31BuildRequires: lua-lpeg
32BuildRequires: lua-mpack >= 1.0.2
0a9d0af1 33BuildRequires: lua51-BitOp
0a9d0af1 34BuildRequires: luajit-devel
ccead671
ER
35%endif
36Requires: desktop-file-utils
37Requires: gtk-update-icon-cache
38Requires: hicolor-icon-theme
0a9d0af1
ER
39Suggests: python-neovim
40Suggests: python3-neovim
41Suggests: xsel
42BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
43
44%description
45Neovim is a refactor - and sometimes redactor - in the tradition of
46Vim, which itself derives from Stevie. It is not a rewrite, but a
47continuation and extension of Vim. Many rewrites, clones, emulators
48and imitators exist; some are very clever, but none are Vim. Neovim
49strives to be a superset of Vim, notwithstanding some intentionally
50removed misfeatures; excepting those few and carefully-considered
51excisions, Neovim is Vim. It is built for users who want the good
52parts of Vim, without compromise, and more.
53
54%prep
55%setup -q
56
ccead671 57%if 0
0a9d0af1
ER
58# Remove __DATE__ and __TIME__.
59BUILD_TIME=$(LC_ALL=C date -ur %{_sourcedir}/%{name}.changes +'%{H}:%{M}')
60BUILD_DATE=$(LC_ALL=C date -ur %{_sourcedir}/%{name}.changes +'%{b} %{d} %{Y}')
61sed -i "s/__TIME__/\"$BUILD_TIME\"/" $(grep -rl '__TIME__')
62sed -i "s/__DATE__/\"$BUILD_DATE\"/" $(grep -rl '__DATE__')
ccead671 63%endif
0a9d0af1
ER
64
65%build
7d69921c
ER
66install -d .deps build
67cd .deps
0a9d0af1 68%cmake \
7d69921c
ER
69 -DUSE_BUNDLED=OFF \
70 -DUSE_BUNDLED_JEMALLOC=OFF \
71 -DUSE_BUNDLED_UNIBILIUM=OFF \
72 -DUSE_BUNDLED_LIBTERMKEY=OFF \
73 -DUSE_BUNDLED_LIBVTERM=OFF \
74 -DUSE_BUNDLED_LIBUV=OFF \
75 -DUSE_BUNDLED_MSGPACK=OFF \
ccead671
ER
76 -DUSE_BUNDLED_LUAJIT=ON \
77 -DUSE_BUNDLED_LUAROCKS=ON \
78 -DUSE_BUNDLED_LUV=ON \
7d69921c
ER
79 ../third-party
80%{__make}
ccead671 81
7d69921c
ER
82cd ../build
83%cmake \
84 -DLUA_PRG=/usr/bin/luajit \
85 -DENABLE_JEMALLOC=ON \
86 -DLUAJIT_USE_BUNDLED=OFF \
87 -DLIBUV_USE_BUNDLED=OFF \
88 -DMSGPACK_USE_BUNDLED=OFF \
89 -DUNIBILIUM_USE_BUNDLED=OFF \
90 -DLIBTERMKEY_USE_BUNDLED=OFF \
91 -DLIBVTERM_USE_BUNDLED=OFF \
92 -DJEMALLOC_USE_BUNDLED=OFF \
93 ..
0a9d0af1
ER
94
95%{__make}
96
97%install
98rm -rf $RPM_BUILD_ROOT
7d69921c 99%{__make} -C build install \
0a9d0af1
ER
100 DESTDIR=$RPM_BUILD_ROOT
101
ccead671 102install -d $RPM_BUILD_ROOT{%{_desktopdir},%{_iconsdir}/hicolor/scalable/apps}
0a9d0af1 103cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir}/neovim.desktop
ccead671 104cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_iconsdir}/hicolor/scalable/apps/neovim.svg
0a9d0af1
ER
105
106%find_lang nvim
107
108%clean
109rm -rf $RPM_BUILD_ROOT
110
111%post
112%update_desktop_database
ccead671 113%update_icon_cache hicolor
b086dcf2
ER
114%banner -e -o %{name} << 'EOF'
115
116The Neovim executable is called 'nvim'. To use your existing Vim
117configuration:
118 ln -s ~/.vim ~/.config/nvim
119 ln -s ~/.vimrc ~/.config/nvim/init.vim
120See ':help nvim' for more information on Neovim.
121
122If you want support for Python plugins such as YouCompleteMe, you need
123to install a Python module in addition to Neovim itself.
124
125See ':help provider-python' or this page for more information:
126 http://neovim.io/doc/user/provider.html
127
128If you have any questions, have a look at:
129 https://github.com/neovim/neovim/wiki/FAQ.
130EOF
0a9d0af1
ER
131
132%postun
133%update_desktop_database
ccead671 134%update_icon_cache hicolor
0a9d0af1
ER
135
136%files -f nvim.lang
137%defattr(644,root,root,755)
138%doc BACKERS.md CONTRIBUTING.md LICENSE README.md
139%attr(755,root,root) %{_bindir}/nvim
140%{_datadir}/nvim
141%{_desktopdir}/%{name}.desktop
142%{_iconsdir}/hicolor/*/apps/%{name}.svg
143%{_mandir}/man1/nvim.1*
This page took 0.08985 seconds and 4 git commands to generate.