]> git.pld-linux.org Git - packages/elinks.git/blame - elinks.spec
- initialize unit_len_ctx
[packages/elinks.git] / elinks.spec
CommitLineData
fea9e3e9 1#
21bf3c6a 2# Conditional build:
b1e248e0
JB
3# - protocols
4%bcond_without bittorrent # BitTorrent protocol support
80b78d5d 5%bcond_without curl # FTPes, SFTP, HTTP/2, etc.
b1e248e0
JB
6%bcond_without fsp # FSP support
7%bcond_without idn # Internation Domain Names support
8%bcond_without ipv6 # IPv6 support
9%bcond_with smb # smb protocol support (non-distib: recent libsmbclient is GPL v3)
10%bcond_with gnutls # GNUTLS-based SSL support (instead of openssl)
11%bcond_without openssl # OpenSSL-based SSL support
12# - content
13%bcond_without cgi # Local CGI support
612abce5
WF
14%bcond_without brotli # Brotli compression support
15%bcond_without js # experimental (yet quite usable) JavaScript support (using quickjs)
80b78d5d 16%bcond_without libcss # libcss support
b1e248e0 17%bcond_with lzma # LZMA support (old API, incompatible with xz-libs)
612abce5 18%bcond_without zstd # zstd compression support
b1e248e0
JB
19# - scripting
20%bcond_with guile # Guile scripting support (non-distrib: guile 2 is LGPL v3+)
21%bcond_without lua # Lua scripting
612abce5 22%bcond_with perl # Perl scripting
b1e248e0
JB
23%bcond_with python # Python scripting support
24%bcond_with ruby # (experimental) Ruby scripting support
25# - display and UI
26%bcond_without 256 # 256 colors support
27%bcond_without led # LEDs
e594467d 28%bcond_without sixel # image display support in SIXEL capable terminals
b1e248e0 29%bcond_without truecolor # true color
b1e248e0
JB
30%bcond_with x # Use the X Window System
31# - misc
32%bcond_without verbose # verbose build (V=1)
5f8650b6 33%bcond_without libevent # build without libevent
e0b0004d 34
3d4d38d9
AG
35%if %{with gnutls}
36%undefine with_openssl
37%endif
e0b0004d 38
ade95a80
JP
39%if %{without libcss}
40%undefine with_js
80b78d5d
WF
41%endif
42
17631700 43Summary: Experimantal Links (text WWW browser)
f85cbf5d
ER
44Summary(es.UTF-8): El links es un browser para modo texto, similar a lynx
45Summary(pl.UTF-8): Eksperymentalny Links (tekstowa przeglądarka WWW)
46Summary(pt_BR.UTF-8): O links é um browser para modo texto, similar ao lynx
17631700 47Name: elinks
80b78d5d 48Version: 0.17.0
95c45c74 49Release: 2
e2affc83 50Epoch: 1
d8169248 51License: GPL v2
17631700 52Group: Applications/Networking
612abce5 53Source0: https://github.com/rkd77/elinks/releases/download/v%{version}/%{name}-%{version}.tar.xz
80b78d5d 54# Source0-md5: 6bb43cd9037ad83cded1df85d95dbd73
17631700 55Source1: %{name}.desktop
5a8f1bd1 56Source2: links.png
95c45c74
WF
57Patch0: libcss-0.9.2.patch
58Patch1: crlf.patch
8ca357a6 59URL: http://www.elinks.cz/
5a8f1bd1 60BuildRequires: bzip2-devel
80b78d5d 61%{?with_curl:BuildRequires: curl-devel}
fcffdc5b 62BuildRequires: expat-devel
b631af97 63%{?with_fsp:BuildRequires: fsplib-devel}
fda44b2d 64BuildRequires: gettext-tools
261ce4dd 65BuildRequires: git-core
e0b0004d 66%{?with_gnutls:BuildRequires: gnutls-devel >= 1.2.5}
17631700 67BuildRequires: gpm-devel
3d4d38d9 68%{?with_guile:BuildRequires: guile-devel}
95c45c74 69%{?with_libcss:BuildRequires: libCSS-devel >= 0.9.2}
fbbf0870 70BuildRequires: libstdc++-devel
aca21feb 71BuildRequires: rpmbuild(macros) >= 1.736
612abce5 72%{?with_js:BuildRequires: sqlite3-devel}
8c08d917 73%{?with_brotli:BuildRequires: libbrotli-devel}
b76c5506 74%if %{with js} || %{with libcss}
95c45c74 75BuildRequires: libdom-devel >= 0.4.2
b76c5506 76%endif
5f8650b6 77%{?with_libevent:BuildRequires: libevent-devel}
695de93c 78%{?with_idn:BuildRequires: libidn2-devel}
e594467d 79%{?with_sixel:BuildRequires: libsixel-devel}
505355c8 80%{?with_smb:BuildRequires: libsmbclient-devel}
612abce5 81%{?with_lua:BuildRequires: lua53-devel}
505355c8 82%{?with_lzma:BuildRequires: lzma-devel}
612abce5 83BuildRequires: meson
1c33e430 84BuildRequires: ncurses-devel >= 5.1
fbbf0870 85BuildRequires: ninja >= 1.5
3d4d38d9
AG
86%{?with_openssl:BuildRequires: openssl-devel >= 0.9.7d}
87%{?with_perl:BuildRequires: perl-devel}
f28e64c7 88BuildRequires: pkgconfig
612abce5 89%{?with_python:BuildRequires: python3-devel}
fbbf0870 90%{?with_js:BuildRequires: quickjs-devel >= 20210327-4}
8ca357a6 91%{?with_ruby:BuildRequires: ruby-devel}
612abce5 92BuildRequires: sed
742dfa9f 93BuildRequires: tar >= 1:1.22
42ac557b 94BuildRequires: tre-devel
f28e64c7 95BuildRequires: which
74175628 96BuildRequires: xmlto
742dfa9f 97BuildRequires: xz
5a8f1bd1 98BuildRequires: zlib-devel
612abce5 99%{?with_zstd:BuildRequires: zstd-devel}
307fe94a 100%{?with_gnutls:Requires: gnutls-libs >= 1.2.5}
95c45c74 101%{?with_libcss:Requires: libCSS >= 0.9.2}
b76c5506 102%if %{with js} || %{with libcss}
95c45c74 103Requires: libdom >= 0.4.2
b76c5506 104%endif
307fe94a
JP
105Requires: ncurses >= 5.1
106%{?with_openssl:Requires: openssl >= 0.9.7d}
107%{?with_js:Requires: quickjs >= 20210327-4}
e1bc1545 108Suggests: mailcap
17631700
AM
109Provides: webclient
110BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
111
c4be24e9 112%define _sysconfdir /etc/elinks
e0b0004d 113%define specflags_ia32 -fomit-frame-pointer
4fc089e9 114
17631700 115%description
cd6ad879
JB
116This is the elinks tree - intended to provide feature-rich version of
117links, however not rock-stable and dedicated mainly for testing. Its
118purpose is to make alternative to links, until Mikulas will have some
119time to maintain it, and to test and tune various patches for Mikulas
120to be able to include them in the official links releases.
17631700 121
3328f371 122%description -l es.UTF-8
c15f1e53 123Links es un browser WWW modo texto, similar al Lynx. El links muestra
124tablas, hace baja archivos en segundo plano, y usa conexiones HTTP/1.1
125keepalive.
126
3328f371
JR
127%description -l pl.UTF-8
128Bogata w opcje i możliwości wersja tekstowej przeglądarki WWW - links.
129elinks jednak jest dedykowana głównie do testowania.
17631700 130
3328f371
JR
131%description -l pt_BR.UTF-8
132Links é um browser WWW modo texto, similar ao Lynx. O Links exibe
133tabelas, baixa arquivos em segundo plano, e usa as conexões HTTP/1.1
c15f1e53 134keepalive.
135
17631700 136%prep
612abce5 137%setup -q
95c45c74
WF
138%patch0 -p1
139%patch1 -p1
0b57a582 140
17631700 141%build
612abce5 142%meson build \
74175628
WF
143 -Dapidoc=false \
144 -Dhtmldoc=true \
145 -Dpdfdoc=false \
146 -Ddocdir=%{_docdir}/%{name}-%{version} \
612abce5
WF
147 %{?with_bittorrent:-Dbittorrent=true} \
148 %{?with_cgi:-Dcgi=true} \
149 -D88-colors=true \
150 %{?with_256:-D256-colors=true} \
151 %{?with_truecolor:-Dtrue-color=true} \
152 -Dexmode=true \
153 %{?debug:-Ddebug=true} \
154 %{!?debug:-Dfastmem=true} \
155 -Dfinger=true \
ea719f7c 156 -Dfsp=%{__true_false fsp} \
612abce5
WF
157 -Dgemini=true \
158 -Dgettext=true \
159 -Dgopher=true \
160 -Dhtml-highlight=true \
161 %{!?with_ipv6:-Dipv6=false} \
162 %{?with_leds:-Dleds=true} \
e594467d 163 -Dlibsixel=%{__true_false sixel} \
612abce5
WF
164 -Dmarks=true \
165 -Dnntp=true \
166 -Dno-root=false \
167 %{?with_smb:-Dsmb=true} \
168 %{?with_brotli:-Dbrotli=true} \
169 %{?with_zstd:-Dzstd=true} \
170 %{?with_gnutls:-Dgnutls=true} \
171 %{?with_guile:-Dguile=true} \
172 %{!?with_idn:-Didn=false} \
173 %{?with_lua:-Dluapkg=lua5.3} \
174 %{?with_lzma:-Dlzma=true} \
175 %{?with_openssl:-Dopenssl=true} \
176 %{?with_perl:-Dperl=true} \
177 %{?with_python:-Dpython=true} \
178 %{?with_ruby:-Druby=true} \
179 %{?with_js:-Dquickjs=true} \
5f8650b6 180 %{?with_x:-Dx=true} \
80b78d5d
WF
181 %{?with_libevent:-Dlibevent=true} \
182 %{!?with_curl:-Dlibcurl=false} \
183 %{!?with_libcss:-Dlibcss=false}
612abce5
WF
184
185%ninja_build -C build
17631700
AM
186
187%install
188rm -rf $RPM_BUILD_ROOT
612abce5
WF
189%ninja_install -C build
190
1568d5eb 191install -d $RPM_BUILD_ROOT%{_desktopdir} \
ad628403 192 $RPM_BUILD_ROOT%{_datadir}/%{name} \
c4be24e9 193 $RPM_BUILD_ROOT{%{_sysconfdir},%{_pixmapsdir}}
17631700 194
e0b0004d
ER
195cp -a %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir}
196cp -a %{SOURCE2} $RPM_BUILD_ROOT%{_pixmapsdir}/%{name}.png
5a8f1bd1 197
ef0f233a 198%{?with_lua:install contrib/lua/*.lua $RPM_BUILD_ROOT%{_sysconfdir}}
612abce5 199sed -i -e 's|bin/lua|bin/lua5.3|g' $RPM_BUILD_ROOT%{_sysconfdir}/*lua
347f019c 200
80b78d5d 201install AUTHORS BUGS ChangeLog NEWS README.md SITES TODO $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
74175628
WF
202install contrib/{keybind*,wipe-out-ssl*,lua/elinks-remote} contrib/conv/{*awk,*.pl,*.sh} $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
203
269a2ef7 204%find_lang %{name}
205
17631700
AM
206%clean
207rm -rf $RPM_BUILD_ROOT
208
269a2ef7 209%files -f %{name}.lang
17631700 210%defattr(644,root,root,755)
74175628 211%{_docdir}/%{name}-%{version}
c20ec49a
JB
212%attr(755,root,root) %{_bindir}/elinks
213%{_mandir}/man1/elinks.1*
214%{_mandir}/man5/elinks.conf.5*
215%{_mandir}/man5/elinkskeys.5*
216%{_desktopdir}/elinks.desktop
217%{_pixmapsdir}/elinks.png
218%if %{with lua}
219%dir %{_sysconfdir}
220%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.lua
221%endif
This page took 0.589844 seconds and 5 git commands to generate.