Gentoo Archives: gentoo-commits

From: Ben Kohler <bkohler@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: www-client/links/
Date: Thu, 04 Nov 2021 11:04:09
Message-Id: 1636023838.ad28681d073be4f3f7a68b694adff6bdbf3aa2c0.bkohler@gentoo
1 commit: ad28681d073be4f3f7a68b694adff6bdbf3aa2c0
2 Author: Ben Kohler <bkohler <AT> gentoo <DOT> org>
3 AuthorDate: Thu Nov 4 11:00:49 2021 +0000
4 Commit: Ben Kohler <bkohler <AT> gentoo <DOT> org>
5 CommitDate: Thu Nov 4 11:03:58 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ad28681d
7
8 www-client/links: add explicit dep on libbsd (was automagic)
9
10 Closes: https://bugs.gentoo.org/821535
11 Package-Manager: Portage-3.0.28, Repoman-3.0.3
12 Signed-off-by: Ben Kohler <bkohler <AT> gentoo.org>
13
14 www-client/links/links-2.25-r1.ebuild | 171 ++++++++++++++++++++++++++++++++++
15 1 file changed, 171 insertions(+)
16
17 diff --git a/www-client/links/links-2.25-r1.ebuild b/www-client/links/links-2.25-r1.ebuild
18 new file mode 100644
19 index 00000000000..b9ea020b62e
20 --- /dev/null
21 +++ b/www-client/links/links-2.25-r1.ebuild
22 @@ -0,0 +1,171 @@
23 +# Copyright 1999-2021 Gentoo Authors
24 +# Distributed under the terms of the GNU General Public License v2
25 +
26 +EAPI=8
27 +
28 +inherit autotools desktop xdg-utils
29 +
30 +DESCRIPTION="A fast and lightweight web browser running in both graphics and text mode"
31 +HOMEPAGE="http://links.twibright.com/"
32 +SRC_URI="http://${PN}.twibright.com/download/${P}.tar.bz2"
33 +
34 +LICENSE="GPL-2"
35 +SLOT="2"
36 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
37 +IUSE="brotli bzip2 fbcon freetype gpm ipv6 jpeg libevent livecd lzip lzma ssl suid svga tiff unicode X zlib zstd"
38 +
39 +GRAPHICS_DEPEND="media-libs/libpng:0="
40 +
41 +RDEPEND="
42 + dev-libs/libbsd
43 + brotli? (
44 + app-arch/brotli
45 + )
46 + bzip2? (
47 + app-arch/bzip2
48 + )
49 + fbcon? (
50 + ${GRAPHICS_DEPEND}
51 + )
52 + freetype? (
53 + media-libs/fontconfig
54 + media-libs/freetype
55 + )
56 + gpm? (
57 + sys-libs/gpm
58 + )
59 + jpeg? (
60 + virtual/jpeg:0
61 + )
62 + libevent? (
63 + dev-libs/libevent:0=
64 + )
65 + livecd? (
66 + ${GRAPHICS_DEPEND}
67 + sys-libs/gpm
68 + virtual/jpeg:0
69 + )
70 + lzip? (
71 + app-arch/lzip
72 + )
73 + lzma? (
74 + app-arch/xz-utils
75 + )
76 + ssl? (
77 + dev-libs/openssl:0=
78 + )
79 + svga? (
80 + ${GRAPHICS_DEPEND}
81 + media-libs/svgalib
82 + )
83 + tiff? (
84 + media-libs/tiff:0
85 + )
86 + X? (
87 + ${GRAPHICS_DEPEND}
88 + x11-libs/libXext
89 + )
90 + zlib? (
91 + sys-libs/zlib
92 + )
93 + zstd? (
94 + app-arch/zstd
95 + )"
96 +
97 +DEPEND="${RDEPEND}
98 + fbcon? ( virtual/os-headers )
99 + livecd? ( virtual/os-headers )"
100 +
101 +BDEPEND="virtual/pkgconfig"
102 +
103 +IDEPEND="X? ( dev-util/desktop-file-utils )"
104 +
105 +REQUIRED_USE="!livecd? ( fbcon? ( gpm ) )
106 + svga? ( suid )"
107 +
108 +DOCS=( AUTHORS BRAILLE_HOWTO ChangeLog KEYS NEWS README SITES )
109 +
110 +src_prepare() {
111 + use X && xdg_environment_reset
112 +
113 + if use unicode; then
114 + pushd intl > /dev/null || die
115 + ./gen-intl || die
116 + ./synclang || die
117 + popd > /dev/null || die
118 + fi
119 +
120 + # error: conditional "am__fastdepCXX" was never defined (for eautoreconf)
121 + sed -i \
122 + -e '/AC_PROG_CXX/s:dnl ::' \
123 + -e 's:AM_CONFIG_HEADER:AC_CONFIG_HEADERS:' \
124 + configure.in || die #467020
125 +
126 + # Upstream configure produced by broken autoconf-2.13. This also fixes
127 + # toolchain detection.
128 + mv configure.in configure.ac || die
129 +
130 + default
131 + eautoreconf #131440 and #103483#c23
132 +}
133 +
134 +src_configure() {
135 + local myconf
136 +
137 + if use livecd; then
138 + export ac_cv_lib_gpm_Gpm_Open=yes
139 + myconf+=' --with-fb --with-libjpeg'
140 + else
141 + export ac_cv_lib_gpm_Gpm_Open=$(usex gpm)
142 + fi
143 +
144 + if use X || use fbcon || use svga || use livecd; then
145 + myconf+=' --enable-graphics'
146 + fi
147 +
148 + econf \
149 + --without-directfb \
150 + --without-librsvg \
151 + $(use_with brotli) \
152 + $(use_with bzip2) \
153 + $(use_with fbcon fb) \
154 + $(use_with freetype) \
155 + $(use_with ipv6) \
156 + $(use_with jpeg libjpeg) \
157 + $(use_with libevent) \
158 + $(use_with lzip) \
159 + $(use_with lzma) \
160 + $(use_with ssl) \
161 + $(use_with svga svgalib) \
162 + $(use_with tiff libtiff) \
163 + $(use_with X x) \
164 + $(use_with zlib) \
165 + $(use_with zstd) \
166 + ${myconf}
167 +}
168 +
169 +src_install() {
170 + HTML_DOCS="doc/links_cal/*"
171 + default
172 +
173 + if use X; then
174 + newicon Links_logo.png links.png
175 + make_desktop_entry 'links -g %u' Links links 'Network;WebBrowser'
176 + local d="${ED}"/usr/share/applications
177 + echo 'MimeType=x-scheme-handler/http;' >> "${d}"/*.desktop || die
178 + if use ssl; then
179 + sed -i -e 's:x-scheme-handler/http;:&x-scheme-handler/https;:' \
180 + "${d}"/*.desktop || die
181 + fi
182 + fi
183 +
184 + use suid && fperms 4755 /usr/bin/links
185 +}
186 +
187 +pkg_postinst() {
188 + use X && xdg_desktop_database_update
189 +}
190 +
191 +pkg_postrm() {
192 + use X && xdg_desktop_database_update
193 +}