2 # - consider doing subpackages for all those plugins (which one should be in main package ?)
3 # - desktop file (icon exists, but no desktop file?)
7 %bcond_without aspell # don't build aspell support
8 %bcond_without gnutls # don't build gnutls support
9 %bcond_with doc # don't build docs
11 %bcond_without guile # don't enable Scheme (guile) scripting language
12 %bcond_without lua # don't enable Lua scripting language
13 %bcond_without perl # don't enable Perl scripting language
14 %bcond_with php # don't enable PHP scripting language
15 %bcond_without python # don't enable Python scripting language
16 %bcond_without ruby # don't enable Ruby scripting language
17 %bcond_without tcl # don't enable Tcl scripting language
18 %bcond_without js # don't enable JavaScript scripting language (V8 engine)
20 %ifnarch %{ix86} %{x8664} arm mips
24 %define php_name php%{?php_suffix}
26 Summary: WeeChat - fast and light chat environment
27 Summary(pl.UTF-8): WeeChat - szybkie i lekkie środowisko do rozmów
32 Group: Applications/Communications
33 Source0: http://www.weechat.org/files/src/%{name}-%{version}.tar.gz
34 # Source0-md5: 2766e82e5500dadfcc0e2bcfdb0ec5b0
35 Patch0: %{name}-curses.patch
36 URL: http://www.weechat.org/
37 %{?with_doc:BuildRequires: asciidoctor}
38 %{?with_aspell:BuildRequires: aspell-devel}
39 BuildRequires: cmake >= 3.0
40 BuildRequires: curl-devel
41 BuildRequires: gettext-tools
42 %{?with_gnutls:BuildRequires: gnutls-devel}
43 %{?with_guile:BuildRequires: guile-devel}
44 BuildRequires: libgcrypt-devel
45 %{?with_lua:BuildRequires: lua51-devel}
46 BuildRequires: ncurses-devel
47 %{?with_perl:BuildRequires: perl-devel}
48 %{?with_php:BuildRequires: %{php_name}-devel >= 4:7}
49 BuildRequires: pkgconfig
50 BuildRequires: sed >= 4.0
51 %{?with_js:BuildRequires: v8-devel}
53 BuildRequires: python-devel
54 BuildRequires: python-modules
56 BuildRequires: rpmbuild(macros) >= 1.129
57 %{?with_ruby:BuildRequires: ruby-devel}
58 %{?with_tcl:BuildRequires: tcl-devel}
59 Requires(post,postun): desktop-file-utils
60 Requires(post,postun): gtk-update-icon-cache
61 Obsoletes: weechat-common
62 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
64 %define skip_post_check_so ruby.so.0.0.0
67 WeeChat (Wee Enhanced Environment for Chat) is a fast and light chat
68 environment for many operating systems. Everything can be done with a
69 keyboard. It is customizable and extensible with scripts.
71 %description -l pl.UTF-8
72 WeeChat (Wee Ehanced Environment for Chat) to szybkie i lekkie
73 środowisko do rozmów dla wielu systemów operacyjnych. Pozwala wszystko
74 zrobić przy pomocy klawiatury. Jest konfigurowalne i rozszerzalne za
78 Summary: Manual for weechat
80 %if "%{_rpmversion}" >= "5"
85 HTML documentation for weechat.
98 -DENABLE_ASPELL=%{?with_aspell:ON}%{!?with_aspell:OFF} \
99 -DENABLE_GNUTLS=%{?with_gnutls:ON}%{!?with_gnutls:OFF} \
100 -DENABLE_DOC=%{?with_doc:ON}%{!?with_doc:OFF} \
101 -DENABLE_PERL=%{?with_perl:ON}%{!?with_perl:OFF} \
102 -DENABLE_PHP=%{?with_php:ON}%{!?with_php:OFF} \
103 -DENABLE_PYTHON=%{?with_python:ON}%{!?with_python:OFF} \
104 -DENABLE_RUBY=%{?with_ruby:ON}%{!?with_ruby:OFF} \
105 -DENABLE_LUA=%{?with_lua:ON}%{!?with_lua:OFF} \
106 -DENABLE_GUILE=%{?with_guile:ON}%{!?with_guile:OFF} \
107 -DENABLE_TCL=%{?with_tcl:ON}%{!?with_tcl:OFF} \
108 -DENABLE_MAN=%{?with_doc:ON}%{!?with_doc:OFF} \
109 -DENABLE_JAVASCRIPT=%{?with_js:ON}%{!?with_js:OFF} \
115 rm -rf $RPM_BUILD_ROOT
116 %{__make} -C build install \
117 DESTDIR=$RPM_BUILD_ROOT
119 # symlink to "weechat"
120 %{__rm} $RPM_BUILD_ROOT%{_bindir}/weechat-curses
123 %{__rm} -r $RPM_BUILD_ROOT%{_includedir}/%{name}
124 %{__rm} $RPM_BUILD_ROOT%{_pkgconfigdir}/%{name}.pc
129 rm -rf $RPM_BUILD_ROOT
132 %update_desktop_database
133 %update_icon_cache hicolor
134 %update_mime_database
137 %update_desktop_database_postun
138 %update_icon_cache hicolor
139 %update_mime_database
141 %files -f %{name}.lang
142 %defattr(644,root,root,755)
143 %doc AUTHORS.adoc ChangeLog.adoc README.adoc ReleaseNotes.adoc
144 %attr(755,root,root) %{_bindir}/weechat
145 %attr(755,root,root) %{_bindir}/weechat-headless
147 %{_mandir}/man1/weechat.1*
148 %lang(cs) %{_mandir}/cs/man1/weechat.1*
149 %lang(de) %{_mandir}/de/man1/weechat.1*
150 %lang(fr) %{_mandir}/fr/man1/weechat.1*
151 %lang(it) %{_mandir}/it/man1/weechat.1*
152 %lang(ja) %{_mandir}/ja/man1/weechat.1*
153 %lang(pl) %{_mandir}/pl/man1/weechat.1*
154 %lang(ru) %{_mandir}/ru/man1/weechat.1*
156 %{_iconsdir}/hicolor/*/apps/weechat.png
157 %{_desktopdir}/%{name}.desktop
159 %dir %{_libdir}/%{name}
160 %dir %{_libdir}/%{name}/plugins
161 %attr(755,root,root) %{_libdir}/%{name}/plugins/alias.so
162 %attr(755,root,root) %{_libdir}/%{name}/plugins/buflist.so
163 %attr(755,root,root) %{_libdir}/%{name}/plugins/charset.so
164 %attr(755,root,root) %{_libdir}/%{name}/plugins/exec.so
165 %attr(755,root,root) %{_libdir}/%{name}/plugins/fifo.so
166 %attr(755,root,root) %{_libdir}/%{name}/plugins/fset.so
167 %attr(755,root,root) %{_libdir}/%{name}/plugins/irc.so
168 %attr(755,root,root) %{_libdir}/%{name}/plugins/logger.so
169 %attr(755,root,root) %{_libdir}/%{name}/plugins/relay.so
170 %attr(755,root,root) %{_libdir}/%{name}/plugins/script.so
171 %attr(755,root,root) %{_libdir}/%{name}/plugins/trigger.so
172 %attr(755,root,root) %{_libdir}/%{name}/plugins/xfer.so
175 %{?with_aspell:%attr(755,root,root) %{_libdir}/%{name}/plugins/spell.so}
178 %{?with_guile:%attr(755,root,root) %{_libdir}/%{name}/plugins/guile.so}
179 %{?with_lua:%attr(755,root,root) %{_libdir}/%{name}/plugins/lua.so}
180 %{?with_perl:%attr(755,root,root) %{_libdir}/%{name}/plugins/perl.so}
181 %{?with_python:%attr(755,root,root) %{_libdir}/%{name}/plugins/python.so}
182 %{?with_ruby:%attr(755,root,root) %{_libdir}/%{name}/plugins/ruby.so}
183 %{?with_tcl:%attr(755,root,root) %{_libdir}/%{name}/plugins/tcl.so}
184 %{?with_js:%attr(755,root,root) %{_libdir}/%{name}/plugins/javascript.so}
188 %defattr(644,root,root,755)
189 %dir %{_docdir}/%{name}
190 %lang(cs) %{_docdir}/%{name}/*.cs.html
191 %lang(de) %{_docdir}/%{name}/*.de.html
192 %lang(en) %{_docdir}/%{name}/*.en.html
193 %lang(es) %{_docdir}/%{name}/*.es.html
194 %lang(fr) %{_docdir}/%{name}/*.fr.html
195 %lang(it) %{_docdir}/%{name}/*.it.html
196 %lang(ja) %{_docdir}/%{name}/*.ja.html
197 %lang(pl) %{_docdir}/%{name}/*.pl.html
198 %lang(ru) %{_docdir}/%{name}/*.ru.html