]> git.pld-linux.org Git - packages/weechat.git/blob - weechat.spec
- rebuild with perl 5.30.0
[packages/weechat.git] / weechat.spec
1 # TODO:
2 # - consider doing subpackages for all those plugins (which one should be in main package ?)
3 # - desktop file (icon exists, but no desktop file?)
4 #
5 # Conditional build:
6 # Features
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
10 # Bindings
11 %bcond_with     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_without  python  # don't enable Python scripting language
15 %bcond_without  ruby    # don't enable Ruby scripting language
16 %bcond_without  tcl     # don't enable Tcl scripting language
17 %bcond_without  js      # don't enable JavaScript scripting language (V8 engine)
18
19 %ifnarch %{ix86} %{x8664} arm mips
20 %undefine       with_js
21 %endif
22
23 Summary:        WeeChat - fast and light chat environment
24 Summary(pl.UTF-8):      WeeChat - szybkie i lekkie środowisko do rozmów
25 Name:           weechat
26 Version:        2.4
27 Release:        2
28 License:        GPL v3+
29 Group:          Applications/Communications
30 Source0:        http://www.weechat.org/files/src/%{name}-%{version}.tar.gz
31 # Source0-md5:  a148af9fa88a408b716139b735854ed7
32 Patch0:         guile-2.2.patch
33 Patch2:         %{name}-curses.patch
34 URL:            http://www.weechat.org/
35 %{?with_doc:BuildRequires:      asciidoctor}
36 %{?with_aspell:BuildRequires:   aspell-devel}
37 BuildRequires:  cmake
38 BuildRequires:  curl-devel
39 BuildRequires:  gettext-tools
40 %{?with_gnutls:BuildRequires:   gnutls-devel}
41 %{?with_guile:BuildRequires:    guile-devel}
42 BuildRequires:  libgcrypt-devel
43 %{?with_lua:BuildRequires:      lua51-devel}
44 BuildRequires:  ncurses-devel
45 %{?with_perl:BuildRequires:     perl-devel}
46 BuildRequires:  pkgconfig
47 BuildRequires:  sed >= 4.0
48 %{?with_js:BuildRequires:       v8-devel}
49 %if %{with python}
50 BuildRequires:  python-devel
51 BuildRequires:  python-modules
52 %endif
53 BuildRequires:  rpmbuild(macros) >= 1.129
54 %{?with_ruby:BuildRequires:     ruby-devel}
55 %{?with_tcl:BuildRequires:      tcl-devel}
56 Obsoletes:      weechat-common
57 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
58
59 %define         skip_post_check_so      ruby.so.0.0.0
60
61 %description
62 WeeChat (Wee Enhanced Environment for Chat) is a fast and light chat
63 environment for many operating systems. Everything can be done with a
64 keyboard. It is customizable and extensible with scripts.
65
66 %description -l pl.UTF-8
67 WeeChat (Wee Ehanced Environment for Chat) to szybkie i lekkie
68 środowisko do rozmów dla wielu systemów operacyjnych. Pozwala wszystko
69 zrobić przy pomocy klawiatury. Jest konfigurowalne i rozszerzalne za
70 pomocą skryptów.
71
72 %package doc
73 Summary:        Manual for weechat
74 Group:          Documentation
75 %if "%{_rpmversion}" >= "5"
76 BuildArch:      noarch
77 %endif
78
79 %description doc
80 HTML documentation for weechat.
81
82 %prep
83 %setup -q
84 %patch0 -p1
85 %patch2 -p0
86
87 %build
88 install -d build
89 cd build
90 %cmake \
91         -DPREFIX=%{_prefix} \
92         -DLIBDIR=%{_libdir} \
93         -DENABLE_NCURSES=ON \
94         -DENABLE_ASPELL=%{?with_aspell:ON}%{!?with_aspell:OFF} \
95         -DENABLE_GNUTLS=%{?with_gnutls:ON}%{!?with_gnutls:OFF} \
96         -DENABLE_DOC=%{?with_doc:ON}%{!?with_doc:OFF} \
97         -DENABLE_PERL=%{?with_perl:ON}%{!?with_perl:OFF} \
98         -DENABLE_PYTHON=%{?with_python:ON}%{!?with_python:OFF} \
99         -DENABLE_RUBY=%{?with_ruby:ON}%{!?with_ruby:OFF} \
100         -DENABLE_LUA=%{?with_lua:ON}%{!?with_lua:OFF} \
101         -DENABLE_GUILE=%{?with_guile:ON}%{!?with_guile:OFF} \
102         -DENABLE_TCL=%{?with_tcl:ON}%{!?with_tcl:OFF} \
103         -DENABLE_MAN=ON \
104         ..
105
106 %{__make} VERBOSE=1
107
108 %install
109 rm -rf $RPM_BUILD_ROOT
110 %{__make} -C build install \
111         DESTDIR=$RPM_BUILD_ROOT
112
113 # symlink to "weechat"
114 %{__rm} $RPM_BUILD_ROOT%{_bindir}/weechat-curses
115
116 # no -devel, drop
117 %{__rm} -r $RPM_BUILD_ROOT%{_includedir}/%{name}
118 %{__rm} $RPM_BUILD_ROOT%{_pkgconfigdir}/%{name}.pc
119
120 %find_lang %{name}
121
122 %clean
123 rm -rf $RPM_BUILD_ROOT
124
125 %files -f %{name}.lang
126 %defattr(644,root,root,755)
127 %doc AUTHORS.adoc ChangeLog.adoc README.adoc ReleaseNotes.adoc
128 %attr(755,root,root) %{_bindir}/weechat
129 %attr(755,root,root) %{_bindir}/weechat-headless
130 %if %{with doc}
131 %{_mandir}/man1/weechat.1*
132 %lang(cs) %{_mandir}/cs/man1/weechat.1*
133 %lang(de) %{_mandir}/de/man1/weechat.1*
134 %lang(fr) %{_mandir}/fr/man1/weechat.1*
135 %lang(it) %{_mandir}/it/man1/weechat.1*
136 %lang(ja) %{_mandir}/ja/man1/weechat.1*
137 %lang(pl) %{_mandir}/pl/man1/weechat.1*
138 %lang(ru) %{_mandir}/ru/man1/weechat.1*
139 %endif
140 %{_iconsdir}/hicolor/*/apps/weechat.png
141
142 %dir %{_libdir}/%{name}
143 %dir %{_libdir}/%{name}/plugins
144 %attr(755,root,root) %{_libdir}/%{name}/plugins/alias.so
145 %attr(755,root,root) %{_libdir}/%{name}/plugins/buflist.so
146 %attr(755,root,root) %{_libdir}/%{name}/plugins/charset.so
147 %attr(755,root,root) %{_libdir}/%{name}/plugins/exec.so
148 %attr(755,root,root) %{_libdir}/%{name}/plugins/fifo.so
149 %attr(755,root,root) %{_libdir}/%{name}/plugins/fset.so
150 %attr(755,root,root) %{_libdir}/%{name}/plugins/irc.so
151 %attr(755,root,root) %{_libdir}/%{name}/plugins/logger.so
152 %attr(755,root,root) %{_libdir}/%{name}/plugins/relay.so
153 %attr(755,root,root) %{_libdir}/%{name}/plugins/script.so
154 %attr(755,root,root) %{_libdir}/%{name}/plugins/trigger.so
155 %attr(755,root,root) %{_libdir}/%{name}/plugins/xfer.so
156
157 # addons
158 %{?with_aspell:%attr(755,root,root) %{_libdir}/%{name}/plugins/aspell.so}
159
160 # language bindings
161 %{?with_guile:%attr(755,root,root) %{_libdir}/%{name}/plugins/guile.so}
162 %{?with_lua:%attr(755,root,root) %{_libdir}/%{name}/plugins/lua.so}
163 %{?with_perl:%attr(755,root,root) %{_libdir}/%{name}/plugins/perl.so}
164 %{?with_python:%attr(755,root,root) %{_libdir}/%{name}/plugins/python.so}
165 %{?with_ruby:%attr(755,root,root) %{_libdir}/%{name}/plugins/ruby.so}
166 %{?with_tcl:%attr(755,root,root) %{_libdir}/%{name}/plugins/tcl.so}
167 %{?with_js:%attr(755,root,root) %{_libdir}/%{name}/plugins/javascript.so}
168
169 %if %{with doc}
170 %files doc
171 %defattr(644,root,root,755)
172 %dir %{_docdir}/%{name}
173 %lang(cs) %{_docdir}/%{name}/*.cs.html
174 %lang(de) %{_docdir}/%{name}/*.de.html
175 %lang(en) %{_docdir}/%{name}/*.en.html
176 %lang(es) %{_docdir}/%{name}/*.es.html
177 %lang(fr) %{_docdir}/%{name}/*.fr.html
178 %lang(it) %{_docdir}/%{name}/*.it.html
179 %lang(ja) %{_docdir}/%{name}/*.ja.html
180 %lang(pl) %{_docdir}/%{name}/*.pl.html
181 %lang(ru) %{_docdir}/%{name}/*.ru.html
182 %endif
This page took 0.041582 seconds and 4 git commands to generate.