- updated to 1.2.1 (solves IRSSI-SA-2019-06)
[packages/irssi.git] / irssi.spec
CommitLineData
846a0ae4
AG
1# TODO:
2# - color_support_for_gui_entry needs update or to eb removed
a30c64ab 3#
d1d19600 4# Conditional build:
16e18b22 5%bcond_without perl # without perl support
2176773f 6%bcond_without dynamic # without dynamic libraries
c1ae1e75 7%bcond_without xmpp # without plugin
e69c54b0 8
531f8279 9%define no_install_post_check_so 1
10
76eb776c 11%define idea_ver 0.1.46
36c9fd1f 12%define xmpp_ver 0.53
90d4496e 13%define irssi_perl_version 20190628
9afd400b 14%{?with_perl:%include /usr/lib/rpm/macros.perl}
75a558b0 15Summary: Irssi is a IRC client
d6b5098c 16Summary(fr.UTF-8): Irssi est un client IRC
6f275e0f 17Summary(hu.UTF-8): Irssi egy IRC kliens
d6b5098c 18Summary(pl.UTF-8): Irssi - wygodny w użyciu klient IRC
75a558b0 19Name: irssi
90d4496e 20Version: 1.2.1
7e73e624 21Release: 1
75a558b0 22License: GPL
d4791b42 23Group: Applications/Communications
f6d84012 24Source0: https://github.com/irssi/irssi/releases/download/%{version}/%{name}-%{version}.tar.gz
90d4496e 25# Source0-md5: f48f655ac3f13d0cc2d8e5b80b9ac042
13117eda
AM
26Source1: %{name}.desktop
27Source2: %{name}.png
2cdf9123
JB
28# NXDOMAIN
29#Source3: http://real.irssi.org/files/plugins/idea/%{name}-idea-%{idea_ver}.tar.gz
30Source3: %{name}-idea-%{idea_ver}.tar.gz
e030c78a 31# Source3-md5: c326efe317b8f67593a3cd46d5557280
c1ae1e75 32Source4: http://cybione.org/~irssi-xmpp/files/irssi-xmpp-%{xmpp_ver}.tar.gz
36c9fd1f 33# Source4-md5: 8c9906e4efbd6f3c8bd8420f0ac8fd91
ecd062a6 34Patch0: %{name}-dcc-send-limit.patch
7de6b4cc 35Patch1: %{name}-home_etc.patch
36Patch2: %{name}-idea-listlen.patch
37Patch3: %{name}-gcc4.patch
38Patch4: %{name}-dynamic.patch
7e73e624 39
7de6b4cc 40Patch6: %{name}-color_support_for_gui_entry.patch
41Patch7: %{name}-libs-nopoison.patch
4f1a737a 42Patch8: am.patch
36c9fd1f
AM
43Patch9: %{name}-idea-glib.patch
44Patch10: %{name}-xmpp.patch
c48a9e4d 45URL: http://www.irssi.org/
13117eda 46BuildRequires: autoconf
a30c64ab 47BuildRequires: automake
2f9c6be9 48BuildRequires: gettext-tools
2cdf9123 49# for idea only
b72c745e 50BuildRequires: glib-devel
9fc42c2d 51BuildRequires: glib2-devel >= 2.24.0
846a0ae4
AG
52BuildRequires: libgcrypt-devel >= 1.2.0
53BuildRequires: libotr-devel >= 4.1.0
a30c64ab 54BuildRequires: libtool
846a0ae4 55BuildRequires: libutf8proc-devel
c1ae1e75 56%{?with_xmpp:BuildRequires: loudmouth-devel}
c694f984 57BuildRequires: ncurses-devel >= 5.0
36c9fd1f 58BuildRequires: openssl-devel >= 0.9.7d
9ad41241 59%{?with_perl:BuildRequires: perl-devel >= 1:5.8.4}
ed5b13fb 60BuildRequires: pkgconfig
4d2cef65 61BuildRequires: popt-devel
6639e834 62%{?with_perl:BuildRequires: rpm-perlprov}
eeb34517 63BuildRequires: rpmbuild(macros) >= 1.315
b9d2203f 64BuildRequires: sed >= 4.0
9fc42c2d 65Requires: glib2 >= 2.24.0
9afd400b 66Provides: perl(Irssi) = %{irssi_perl_version}
071656b5
ER
67Obsoletes: irssi-speech
68Obsoletes: irssi-sql
1da5a0b0 69BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
c5c87082 70
eeb34517 71%if %{with dynamic}
72%define filterout_ld -Wl,--as-needed
73%endif
74
738c3ae3 75%description
d4791b42 76Irssi is a textUI IRC client with IPv6 support.
738c3ae3 77
fab8b1be 78%description -l fr.UTF-8
d4791b42 79Irssi est client IRC.
6f85d63f 80
6f275e0f 81%description -l hu.UTF-8
6400c7fe 82Irssi egy szöveges felületű IRC kliens IPv6 támogatással.
6f275e0f 83
fab8b1be 84%description -l pl.UTF-8
d4791b42 85Irssi jest tekstowym klientem IRC ze wsparciem dla IPv6.
73c49657 86
74cc6bc5 87%package plugin-idea
f52ef808 88Summary: Irssi plugin IDEA crypt
6f275e0f 89Summary(hu.UTF-8): Irssi IDEA plugin
d6b5098c 90Summary(pl.UTF-8): Wtyczka do irssi do szyfrowania IDEA
f52ef808 91Group: Applications/Communications
071656b5 92Requires: %{name} = %{version}-%{release}
2cdf9123 93Requires: glib >= 1:1.2.10-13
74cc6bc5 94
95%description plugin-idea
39eceb32 96This package contains IDEA Crypt plugin for Irssi.
97
6f275e0f
ZU
98%description plugin-idea -l hu.UTF-8
99Ez a csomag tartalmazza az IDEA titkosítási plugint Irssi-hez.
100
fab8b1be
JR
101%description plugin-idea -l pl.UTF-8
102Ten pakiet zawiera wtyczkę do Irssi z szyfrowaniem IDEA.
74cc6bc5 103
c1ae1e75
JR
104%package plugin-xmpp
105Summary: Irssi XMPP support plugin
106Summary(pl.UTF-8): Wtyczka do irssi do obsługi XMPP
107Group: Applications/Communications
108Requires: %{name} = %{version}-%{release}
109
110%description plugin-xmpp
111This package contains XMPP support plugin for Irssi.
112
113%description plugin-xmpp -l pl.UTF-8
114Ten pakiet zawiera wtyczkę do Irssi z obsługą XMPP.
115
738c3ae3 116%prep
c1ae1e75 117%setup -q -a3 -a4
51b33c8b 118%patch0 -p1
119%patch1 -p1
972ba5d8 120%patch2 -p1
01baf907 121%patch3 -p1
69fc8ac9 122%if %{with dynamic}
7de6b4cc 123%patch4 -p1
69fc8ac9 124%endif
7e73e624 125
846a0ae4 126#%patch6 -p0
7de6b4cc 127%patch7 -p1
738c3ae3 128
2cdf9123
JB
129echo 'AC_DEFUN([AM_PATH_GLIB],[:])' > glib1.m4
130
9afd400b 131mv irssi-idea{-%{idea_ver},}
c1ae1e75 132mv irssi-xmpp{-%{xmpp_ver},}
4f1a737a 133%patch8 -p1
36c9fd1f
AM
134%patch9 -p0
135%patch10 -p0
9afd400b 136
ec3bc534 137# hack
c7d2e44a 138%{__sed} -i -e 's#\./libtool#%{_bindir}/libtool#g' 'configure.ac'
ec3bc534 139
738c3ae3 140%build
9afd400b
ER
141ver=$(awk '/IRSSI_VERSION_DATE/{print $3}' irssi-version.h)
142if [ "$ver" != "%{irssi_perl_version}" ]; then
143 : update irssi_perl_version to $ver
144 exit 1
145fi
146
64ee8d3e 147%{__libtoolize}
6932dd71 148%{__aclocal} -I .
d0022294 149%{__autoconf}
150%{__automake}
c694f984 151%configure \
c2196b84 152 --disable-silent-rules \
c5c87082 153 --without-socks \
13117eda 154 --with-bot \
be6cd0e4 155 --with-textui \
d4791b42
AM
156 --with-proxy \
157 --with-modules \
846a0ae4 158 --with-otr \
d1d19600 159 %{?with_perl:--with-perl=yes} \
160 %{?with_perl:--with-perl-lib=vendor} \
161 %{!?with_perl:--with-perl=no} \
36c9fd1f 162 --enable-true-color
694c1a92 163
c2196b84 164%{__make}
738c3ae3 165
53d15a9c
AM
166# to fool idea configure script
167touch irssi-config
9afd400b 168cd irssi-idea
74cc6bc5 169%{__libtoolize}
170%{__aclocal} -I .
171%{__autoconf}
172%{__automake}
c2196b84
ER
173%configure \
174 --disable-silent-rules
175%{__make}
c1ae1e75 176cd ..
c2196b84 177
c1ae1e75
JR
178export IRSSI_INCLUDE=`pwd`
179cd irssi-xmpp
180%{__make}
181
738c3ae3
AF
182%install
183rm -rf $RPM_BUILD_ROOT
16afed53 184install -d $RPM_BUILD_ROOT{%{_pixmapsdir},%{_desktopdir}}
1352901f 185%{__make} install \
c2196b84
ER
186 docdir=%{_datadir}/%{name}-%{version} \
187 DESTDIR=$RPM_BUILD_ROOT
bed6758a 188
76eb776c
ER
189# scripts packaged by irssi-scripts.spec
190rm -f $RPM_BUILD_ROOT%{_datadir}/%{name}/scripts/*
191
192cp -a %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir}
193cp -a %{SOURCE2} $RPM_BUILD_ROOT%{_pixmapsdir}
d4791b42 194
9afd400b 195%{__make} -C irssi-idea install \
74cc6bc5 196 DESTDIR=$RPM_BUILD_ROOT
197
c1ae1e75
JR
198%{__make} -C irssi-xmpp install \
199 PREFIX=%{_prefix} \
200 IRSSI_LIB=%{_libdir}/%{name} \
201 DESTDIR=$RPM_BUILD_ROOT
202
565dd6a6
AM
203# -devel?
204rm $RPM_BUILD_ROOT%{_libdir}/lib*.{so,la,a}
205rm -r $RPM_BUILD_ROOT%{_includedir}/irssi
76eb776c
ER
206# cleanup
207rm $RPM_BUILD_ROOT%{_libdir}/irssi/modules/lib*.{la,a}
96dd21e9 208%if %{with perl}
76eb776c
ER
209rm $RPM_BUILD_ROOT%{perl_archlib}/perllocal.pod
210rm $RPM_BUILD_ROOT%{perl_vendorarch}/auto/Irssi/.packlist
211rm $RPM_BUILD_ROOT%{perl_vendorarch}/auto/Irssi/Irc/.packlist
212rm $RPM_BUILD_ROOT%{perl_vendorarch}/auto/Irssi/TextUI/.packlist
213rm $RPM_BUILD_ROOT%{perl_vendorarch}/auto/Irssi/UI/.packlist
96dd21e9 214%endif
76eb776c 215rm -r $RPM_BUILD_ROOT%{_datadir}/%{name}-%{version}
565dd6a6 216
738c3ae3 217%clean
bed6758a 218rm -rf $RPM_BUILD_ROOT
738c3ae3 219
be6cd0e4 220%files
75a558b0 221%defattr(644,root,root,755)
c7d2e44a 222%doc AUTHORS ChangeLog README.md TODO NEWS docs/*.{txt,html}
76eb776c
ER
223%attr(755,root,root) %{_bindir}/botti
224%attr(755,root,root) %{_bindir}/irssi
c5c87082 225%dir %{_libdir}/irssi
d4791b42 226%dir %{_libdir}/irssi/modules
74cc6bc5 227%attr(755,root,root) %{_libdir}/irssi/modules/libirc_proxy.so*
846a0ae4 228%attr(755,root,root) %{_libdir}/irssi/modules/libotr_core.so*
69fc8ac9 229%if %{with dynamic}
230%attr(755,root,root) %{_libdir}/libirssi*.so.*
231%endif
76eb776c
ER
232%dir %{_datadir}/%{name}
233%dir %{_datadir}/%{name}/scripts
234%{_datadir}/%{name}/help
235%{_datadir}/%{name}/themes
16afed53 236%{_desktopdir}/irssi.desktop
76eb776c 237%{_pixmapsdir}/irssi.png
c84e79dc 238%{_sysconfdir}/irssi.conf
76eb776c 239%{_mandir}/man1/irssi.1*
c84e79dc 240
d1d19600 241%if %{with perl}
c84e79dc 242%{perl_vendorarch}/*.pm
243%dir %{perl_vendorarch}/Irssi
244%{perl_vendorarch}/Irssi/*.pm
245
246%dir %{perl_vendorarch}/auto/Irssi
c84e79dc 247%attr(755,root,root) %{perl_vendorarch}/auto/Irssi/*.so
248
249%dir %{perl_vendorarch}/auto/Irssi/Irc
c84e79dc 250%attr(755,root,root) %{perl_vendorarch}/auto/Irssi/Irc/*.so
251
252%dir %{perl_vendorarch}/auto/Irssi/TextUI
c84e79dc 253%attr(755,root,root) %{perl_vendorarch}/auto/Irssi/TextUI/*.so
254
255%dir %{perl_vendorarch}/auto/Irssi/UI
c84e79dc 256%attr(755,root,root) %{perl_vendorarch}/auto/Irssi/UI/*.so
257%endif
74cc6bc5 258
259%files plugin-idea
260%defattr(644,root,root,755)
261%attr(755,root,root) %{_libdir}/irssi/modules/libidea.so
c1ae1e75
JR
262
263%files plugin-xmpp
264%defattr(644,root,root,755)
265%doc irssi-xmpp/{docs/*,NEWS,README,TODO}
266%attr(755,root,root) %{_libdir}/irssi/modules/libfe_xmpp.so
267%attr(755,root,root) %{_libdir}/irssi/modules/libtext_xmpp.so
268%attr(755,root,root) %{_libdir}/irssi/modules/libxmpp_core.so
This page took 0.361123 seconds and 4 git commands to generate.