Gentoo Archives: gentoo-commits

From: Christian Ruppert <idl0r@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/
Date: Tue, 02 Jun 2020 07:56:07
Message-Id: 1591084553.4ab2becb78f6bd8c6f57f900b6a1915910c9f229.idl0r@gentoo
1 commit: 4ab2becb78f6bd8c6f57f900b6a1915910c9f229
2 Author: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
3 AuthorDate: Tue Jun 2 07:54:13 2020 +0000
4 Commit: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
5 CommitDate: Tue Jun 2 07:55:53 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4ab2becb
7
8 net-proxy/haproxy: Remove old ebuilds
9
10 Package-Manager: Portage-2.3.99, Repoman-2.3.22
11 Signed-off-by: Christian Ruppert <idl0r <AT> gentoo.org>
12
13 net-proxy/haproxy/Manifest | 2 -
14 net-proxy/haproxy/haproxy-1.8.13.ebuild | 169 -------------------------------
15 net-proxy/haproxy/haproxy-1.8.9.ebuild | 169 -------------------------------
16 net-proxy/haproxy/haproxy-1.9.15.ebuild | 173 --------------------------------
17 4 files changed, 513 deletions(-)
18
19 diff --git a/net-proxy/haproxy/Manifest b/net-proxy/haproxy/Manifest
20 index 5f6420bd3f7..5ba091b92af 100644
21 --- a/net-proxy/haproxy/Manifest
22 +++ b/net-proxy/haproxy/Manifest
23 @@ -1,6 +1,4 @@
24 -DIST haproxy-1.8.13.tar.gz 2063046 BLAKE2B 9ebccf2520719cdf209bc9a87bf28d015b5b673e0d017d5387af4025f930ac401f6a2cfa851583ffe6b6645b7b91ad255bb5db737688a1f310958072a11c8a80 SHA512 54d4cb0721a3868267d7e085b3d3bb050384e4279eb49e88abb925bb3ea8cc39ef9069bdc99b7b18a23fd22e0d29e24dfcb8a0507ddca9243a845e4418be9cc5
25 DIST haproxy-1.8.25.tar.gz 2184002 BLAKE2B d6ea39af0109eee679d87dde258038bbb38ccf12796b2e6a7172067fce6bd0f10485e2a3d89ca5b3596529db4e34d511bbb194b019c7403703cb636573b0438d SHA512 655eb4056989a3fee321ea9278a2085b0a999e522293f1f6229ebb8d17f3d33cb78abb4fd55a06d0218082e632b2d42de105575d0acd0c1b49996d4b45aa78e8
26 -DIST haproxy-1.8.9.tar.gz 2057051 BLAKE2B d81d18f68a27ae8a77660c1ecb1dfc28599263ebfd57f25ea574af2b101b35eb7a1a89ba4034b55dfa89673ae6ac4c0dca5428b4b494a02184b1b157850ce96b SHA512 e59c29af3a39d6212f012ae8341b169436e10e42fadaf8f1aa68d2bb7ee181fd1fe3b74640bfcd8c37c17dfc5062b36bd69d90290d7c59cd3e4648ef2ab1c8dd
27 DIST haproxy-1.9.15.tar.gz 2480346 BLAKE2B 9ebdef0cb038324b1cbe74198e73fd7f3adf5d1c6ec4000fb02e2640fe79e4b64257bfb5d6da5f1ee73486969a47e13f386313d1923893d290ef368775a08d79 SHA512 618799c9c9c5ce2c9e42aaf22abe6018d1071a72ce54273c330538007d44568a29f643d53e4861d26dbc4fc5acd1b927361948dfc1c846574d6183b6ae81429c
28 DIST haproxy-2.0.14.tar.gz 2651320 BLAKE2B dd5aed78e52b3d3dd295f3883d45adf8795efac93cf6c23fbe39be031f29d19adad0afb400e8041281413f4570bc074f06d9cd88bee672789311e56f57b258d0 SHA512 6b63b713a1009eff59a2622fa93462deb8794c910685840f142711a61be88ea228c7cb2ec7ca50bba0803288625e1a65b2d2f87ffbcedfd23debfbbbb5d96993
29 DIST haproxy-2.1.4.tar.gz 2684568 BLAKE2B 0618e069e6cf6fd20eb9fad0cfcb5ca1714d4001a794e20ce60d812741f4f65d44088c46599e4181cb79536566a940d748030552d0bd010ba14d1552cf7156f4 SHA512 fd029ac1ec877fa89a9410944439b66795b1392b6c8416aaa7978943170530c3826ba50ea706366f3f7785b7cffed58497cb362fc2480dd6920a99af4f920d98
30
31 diff --git a/net-proxy/haproxy/haproxy-1.8.13.ebuild b/net-proxy/haproxy/haproxy-1.8.13.ebuild
32 deleted file mode 100644
33 index 7f78d78c47a..00000000000
34 --- a/net-proxy/haproxy/haproxy-1.8.13.ebuild
35 +++ /dev/null
36 @@ -1,169 +0,0 @@
37 -# Copyright 1999-2018 Gentoo Foundation
38 -# Distributed under the terms of the GNU General Public License v2
39 -
40 -EAPI="6"
41 -
42 -[[ ${PV} == *9999 ]] && SCM="git-r3"
43 -inherit user versionator toolchain-funcs flag-o-matic systemd linux-info $SCM
44 -
45 -MY_P="${PN}-${PV/_beta/-dev}"
46 -
47 -DESCRIPTION="A TCP/HTTP reverse proxy for high availability environments"
48 -HOMEPAGE="http://www.haproxy.org"
49 -if [[ ${PV} != *9999 ]]; then
50 - SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
51 - KEYWORDS="amd64 arm ~ppc x86"
52 -else
53 - EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 1-2).git/"
54 - EGIT_BRANCH=master
55 -fi
56 -
57 -LICENSE="GPL-2 LGPL-2.1"
58 -SLOT="0"
59 -IUSE="+crypt doc examples libressl slz net_ns +pcre pcre-jit pcre2 pcre2-jit ssl
60 -systemd +threads tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
61 -REQUIRED_USE="pcre-jit? ( pcre )
62 - pcre2-jit? ( pcre2 )
63 - pcre? ( !pcre2 )
64 - device-atlas? ( pcre )
65 - ?? ( slz zlib )"
66 -
67 -DEPEND="
68 - pcre? (
69 - dev-libs/libpcre
70 - pcre-jit? ( dev-libs/libpcre[jit] )
71 - )
72 - pcre2? (
73 - dev-libs/libpcre
74 - pcre2-jit? ( dev-libs/libpcre2[jit] )
75 - )
76 - ssl? (
77 - !libressl? ( dev-libs/openssl:0=[zlib?] )
78 - libressl? ( dev-libs/libressl:0= )
79 - )
80 - slz? ( dev-libs/libslz:= )
81 - zlib? ( sys-libs/zlib )
82 - lua? ( dev-lang/lua:5.3 )
83 - device-atlas? ( dev-libs/device-atlas-api-c )"
84 -RDEPEND="${DEPEND}"
85 -
86 -S="${WORKDIR}/${MY_P}"
87 -
88 -DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
89 -CONTRIBS=( halog iprange )
90 -# ip6range is present in 1.6, but broken.
91 -version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
92 -# TODO: mod_defender - requires apache / APR, modsecurity - the same
93 -version_is_at_least 1.8.0 $PV && CONTRIBS+=( hpack )
94 -
95 -haproxy_use() {
96 - (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
97 -
98 - usex "${1}" "USE_${2}=1" "USE_${2}="
99 -}
100 -
101 -pkg_setup() {
102 - enewgroup haproxy
103 - enewuser haproxy -1 -1 -1 haproxy
104 -
105 - if use net_ns; then
106 - CONFIG_CHECK="~NET_NS"
107 - linux-info_pkg_setup
108 - fi
109 -}
110 -
111 -src_compile() {
112 - local -a args=(
113 - TARGET=linux2628
114 - USE_GETADDRINFO=1
115 - USE_TFO=1
116 - )
117 -
118 - # TODO: PCRE2_WIDTH?
119 - args+=( $(haproxy_use threads THREAD) )
120 - args+=( $(haproxy_use crypt LIBCRYPT) )
121 - args+=( $(haproxy_use net_ns NS) )
122 - args+=( $(haproxy_use pcre PCRE) )
123 - args+=( $(haproxy_use pcre-jit PCRE_JIT) )
124 - args+=( $(haproxy_use ssl OPENSSL) )
125 - args+=( $(haproxy_use slz SLZ) )
126 - args+=( $(haproxy_use zlib ZLIB) )
127 - args+=( $(haproxy_use lua LUA) )
128 - args+=( $(haproxy_use 51degrees 51DEGREES) )
129 - args+=( $(haproxy_use device-atlas DEVICEATLAS) )
130 - args+=( $(haproxy_use wurfl WURFL) )
131 - args+=( $(haproxy_use systemd SYSTEMD) )
132 -
133 - # For now, until the strict-aliasing breakage will be fixed
134 - append-cflags -fno-strict-aliasing
135 -
136 - emake CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
137 - emake -C contrib/systemd SBINDIR=/usr/sbin
138 -
139 - if use tools ; then
140 - for contrib in ${CONTRIBS[@]} ; do
141 - emake -C contrib/${contrib} \
142 - CFLAGS="${CFLAGS}" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
143 - done
144 - fi
145 -}
146 -
147 -src_install() {
148 - dosbin haproxy
149 - dosym ../sbin/haproxy /usr/bin/haproxy
150 -
151 - newconfd "${FILESDIR}/${PN}.confd" $PN
152 - newinitd "${FILESDIR}/${PN}.initd-r6" $PN
153 -
154 - doman doc/haproxy.1
155 -
156 - systemd_dounit contrib/systemd/haproxy.service
157 -
158 - einstalldocs
159 -
160 - # The errorfiles are used by upstream defaults.
161 - insinto /etc/haproxy/errors/
162 - doins examples/errorfiles/*
163 -
164 - if use doc; then
165 - dodoc ROADMAP doc/*.txt
166 - #if use lua; then
167 - # TODO: doc/lua-api/
168 - #fi
169 - fi
170 -
171 - if use tools ; then
172 - has halog "${CONTRIBS[@]}" && dobin contrib/halog/halog
173 - has "iprange" "${CONTRIBS[@]}" && newbin contrib/iprange/iprange haproxy_iprange
174 - has "ip6range" "${CONTRIBS[@]}" && newbin contrib/ip6range/ip6range haproxy_ip6range
175 - has "spoa_example" "${CONTRIBS[@]}" && newbin contrib/spoa_example/spoa haproxy_spoa_example
176 - has "spoa_example" "${CONTRIBS[@]}" && newdoc contrib/spoa_example/README README.spoa_example
177 - has "tcploop" "${CONTRIBS[@]}" && newbin contrib/tcploop/tcploop haproxy_tcploop
178 - has "hpack" "${CONTRIBS[@]}" && newbin contrib/hpack/gen-rht haproxy_hpack
179 - fi
180 -
181 - if use examples ; then
182 - docinto examples
183 - dodoc examples/*.cfg
184 - dodoc examples/seamless_reload.txt
185 - fi
186 -
187 - if use vim-syntax ; then
188 - insinto /usr/share/vim/vimfiles/syntax
189 - doins examples/haproxy.vim
190 - fi
191 -}
192 -
193 -pkg_postinst() {
194 - if [[ ! -f "${EROOT}/etc/haproxy/haproxy.cfg" ]] ; then
195 - ewarn "You need to create /etc/haproxy/haproxy.cfg before you start the haproxy service."
196 - ewarn "It's best practice to not run haproxy as root, user and group haproxy was therefore created."
197 - ewarn "Make use of them with the \"user\" and \"group\" directives."
198 -
199 - if [[ -d "${EROOT}/usr/share/doc/${PF}" ]]; then
200 - einfo "Please consult the installed documentation for learning the configuration file's syntax."
201 - einfo "The documentation and sample configuration files are installed here:"
202 - einfo " ${EROOT}usr/share/doc/${PF}"
203 - fi
204 - fi
205 -}
206
207 diff --git a/net-proxy/haproxy/haproxy-1.8.9.ebuild b/net-proxy/haproxy/haproxy-1.8.9.ebuild
208 deleted file mode 100644
209 index 92c291b8106..00000000000
210 --- a/net-proxy/haproxy/haproxy-1.8.9.ebuild
211 +++ /dev/null
212 @@ -1,169 +0,0 @@
213 -# Copyright 1999-2018 Gentoo Foundation
214 -# Distributed under the terms of the GNU General Public License v2
215 -
216 -EAPI="6"
217 -
218 -[[ ${PV} == *9999 ]] && SCM="git-r3"
219 -inherit user versionator toolchain-funcs flag-o-matic systemd linux-info $SCM
220 -
221 -MY_P="${PN}-${PV/_beta/-dev}"
222 -
223 -DESCRIPTION="A TCP/HTTP reverse proxy for high availability environments"
224 -HOMEPAGE="http://www.haproxy.org"
225 -if [[ ${PV} != *9999 ]]; then
226 - SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
227 - KEYWORDS="amd64 arm ppc x86"
228 -else
229 - EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 1-2).git/"
230 - EGIT_BRANCH=master
231 -fi
232 -
233 -LICENSE="GPL-2 LGPL-2.1"
234 -SLOT="0"
235 -IUSE="+crypt doc examples libressl slz net_ns +pcre pcre-jit pcre2 pcre2-jit ssl
236 -systemd +threads tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
237 -REQUIRED_USE="pcre-jit? ( pcre )
238 - pcre2-jit? ( pcre2 )
239 - pcre? ( !pcre2 )
240 - device-atlas? ( pcre )
241 - ?? ( slz zlib )"
242 -
243 -DEPEND="
244 - pcre? (
245 - dev-libs/libpcre
246 - pcre-jit? ( dev-libs/libpcre[jit] )
247 - )
248 - pcre2? (
249 - dev-libs/libpcre
250 - pcre2-jit? ( dev-libs/libpcre2[jit] )
251 - )
252 - ssl? (
253 - !libressl? ( dev-libs/openssl:0=[zlib?] )
254 - libressl? ( dev-libs/libressl:0= )
255 - )
256 - slz? ( dev-libs/libslz:= )
257 - zlib? ( sys-libs/zlib )
258 - lua? ( dev-lang/lua:5.3 )
259 - device-atlas? ( dev-libs/device-atlas-api-c )"
260 -RDEPEND="${DEPEND}"
261 -
262 -S="${WORKDIR}/${MY_P}"
263 -
264 -DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
265 -CONTRIBS=( halog iprange )
266 -# ip6range is present in 1.6, but broken.
267 -version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
268 -# TODO: mod_defender - requires apache / APR, modsecurity - the same
269 -version_is_at_least 1.8.0 $PV && CONTRIBS+=( hpack )
270 -
271 -haproxy_use() {
272 - (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
273 -
274 - usex "${1}" "USE_${2}=1" "USE_${2}="
275 -}
276 -
277 -pkg_setup() {
278 - enewgroup haproxy
279 - enewuser haproxy -1 -1 -1 haproxy
280 -
281 - if use net_ns; then
282 - CONFIG_CHECK="~NET_NS"
283 - linux-info_pkg_setup
284 - fi
285 -}
286 -
287 -src_compile() {
288 - local -a args=(
289 - TARGET=linux2628
290 - USE_GETADDRINFO=1
291 - USE_TFO=1
292 - )
293 -
294 - # TODO: PCRE2_WIDTH?
295 - args+=( $(haproxy_use threads THREAD) )
296 - args+=( $(haproxy_use crypt LIBCRYPT) )
297 - args+=( $(haproxy_use net_ns NS) )
298 - args+=( $(haproxy_use pcre PCRE) )
299 - args+=( $(haproxy_use pcre-jit PCRE_JIT) )
300 - args+=( $(haproxy_use ssl OPENSSL) )
301 - args+=( $(haproxy_use slz SLZ) )
302 - args+=( $(haproxy_use zlib ZLIB) )
303 - args+=( $(haproxy_use lua LUA) )
304 - args+=( $(haproxy_use 51degrees 51DEGREES) )
305 - args+=( $(haproxy_use device-atlas DEVICEATLAS) )
306 - args+=( $(haproxy_use wurfl WURFL) )
307 - args+=( $(haproxy_use systemd SYSTEMD) )
308 -
309 - # For now, until the strict-aliasing breakage will be fixed
310 - append-cflags -fno-strict-aliasing
311 -
312 - emake CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
313 - emake -C contrib/systemd SBINDIR=/usr/sbin
314 -
315 - if use tools ; then
316 - for contrib in ${CONTRIBS[@]} ; do
317 - emake -C contrib/${contrib} \
318 - CFLAGS="${CFLAGS}" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
319 - done
320 - fi
321 -}
322 -
323 -src_install() {
324 - dosbin haproxy
325 - dosym ../sbin/haproxy /usr/bin/haproxy
326 -
327 - newconfd "${FILESDIR}/${PN}.confd" $PN
328 - newinitd "${FILESDIR}/${PN}.initd-r6" $PN
329 -
330 - doman doc/haproxy.1
331 -
332 - systemd_dounit contrib/systemd/haproxy.service
333 -
334 - einstalldocs
335 -
336 - # The errorfiles are used by upstream defaults.
337 - insinto /etc/haproxy/errors/
338 - doins examples/errorfiles/*
339 -
340 - if use doc; then
341 - dodoc ROADMAP doc/*.txt
342 - #if use lua; then
343 - # TODO: doc/lua-api/
344 - #fi
345 - fi
346 -
347 - if use tools ; then
348 - has halog "${CONTRIBS[@]}" && dobin contrib/halog/halog
349 - has "iprange" "${CONTRIBS[@]}" && newbin contrib/iprange/iprange haproxy_iprange
350 - has "ip6range" "${CONTRIBS[@]}" && newbin contrib/ip6range/ip6range haproxy_ip6range
351 - has "spoa_example" "${CONTRIBS[@]}" && newbin contrib/spoa_example/spoa haproxy_spoa_example
352 - has "spoa_example" "${CONTRIBS[@]}" && newdoc contrib/spoa_example/README README.spoa_example
353 - has "tcploop" "${CONTRIBS[@]}" && newbin contrib/tcploop/tcploop haproxy_tcploop
354 - has "hpack" "${CONTRIBS[@]}" && newbin contrib/hpack/gen-rht haproxy_hpack
355 - fi
356 -
357 - if use examples ; then
358 - docinto examples
359 - dodoc examples/*.cfg
360 - dodoc examples/seamless_reload.txt
361 - fi
362 -
363 - if use vim-syntax ; then
364 - insinto /usr/share/vim/vimfiles/syntax
365 - doins examples/haproxy.vim
366 - fi
367 -}
368 -
369 -pkg_postinst() {
370 - if [[ ! -f "${EROOT}/etc/haproxy/haproxy.cfg" ]] ; then
371 - ewarn "You need to create /etc/haproxy/haproxy.cfg before you start the haproxy service."
372 - ewarn "It's best practice to not run haproxy as root, user and group haproxy was therefore created."
373 - ewarn "Make use of them with the \"user\" and \"group\" directives."
374 -
375 - if [[ -d "${EROOT}/usr/share/doc/${PF}" ]]; then
376 - einfo "Please consult the installed documentation for learning the configuration file's syntax."
377 - einfo "The documentation and sample configuration files are installed here:"
378 - einfo " ${EROOT}usr/share/doc/${PF}"
379 - fi
380 - fi
381 -}
382
383 diff --git a/net-proxy/haproxy/haproxy-1.9.15.ebuild b/net-proxy/haproxy/haproxy-1.9.15.ebuild
384 deleted file mode 100644
385 index 9c532b35446..00000000000
386 --- a/net-proxy/haproxy/haproxy-1.9.15.ebuild
387 +++ /dev/null
388 @@ -1,173 +0,0 @@
389 -# Copyright 1999-2020 Gentoo Authors
390 -# Distributed under the terms of the GNU General Public License v2
391 -
392 -EAPI="7"
393 -
394 -[[ ${PV} == *9999 ]] && SCM="git-r3"
395 -inherit user toolchain-funcs flag-o-matic systemd linux-info $SCM
396 -
397 -MY_P="${PN}-${PV/_beta/-dev}"
398 -
399 -DESCRIPTION="A TCP/HTTP reverse proxy for high availability environments"
400 -HOMEPAGE="http://www.haproxy.org"
401 -if [[ ${PV} != *9999 ]]; then
402 - SRC_URI="http://haproxy.1wt.eu/download/$(ver_cut 1-2)/src/${MY_P}.tar.gz"
403 - KEYWORDS="~amd64 ~arm ~ppc ~x86"
404 -else
405 - EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(ver_cut 1-2).git/"
406 - EGIT_BRANCH=master
407 -fi
408 -
409 -LICENSE="GPL-2 LGPL-2.1"
410 -SLOT="0"
411 -IUSE="+crypt doc examples libressl slz net_ns +pcre pcre-jit pcre2 pcre2-jit ssl
412 -systemd +threads tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
413 -REQUIRED_USE="pcre-jit? ( pcre )
414 - pcre2-jit? ( pcre2 )
415 - pcre? ( !pcre2 )
416 - device-atlas? ( pcre )
417 - ?? ( slz zlib )"
418 -
419 -DEPEND="
420 - pcre? (
421 - dev-libs/libpcre
422 - pcre-jit? ( dev-libs/libpcre[jit] )
423 - )
424 - pcre2? (
425 - dev-libs/libpcre
426 - pcre2-jit? ( dev-libs/libpcre2[jit] )
427 - )
428 - ssl? (
429 - !libressl? ( dev-libs/openssl:0=[zlib?] )
430 - libressl? ( dev-libs/libressl:0= )
431 - )
432 - slz? ( dev-libs/libslz:= )
433 - zlib? ( sys-libs/zlib )
434 - lua? ( dev-lang/lua:5.3 )
435 - device-atlas? ( dev-libs/device-atlas-api-c )"
436 -RDEPEND="${DEPEND}"
437 -
438 -S="${WORKDIR}/${MY_P}"
439 -
440 -DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
441 -CONTRIBS=( halog iprange )
442 -# ip6range is present in 1.6, but broken.
443 -ver_test $PV -ge 1.7.0 && CONTRIBS+=( ip6range spoa_example tcploop )
444 -# TODO: mod_defender - requires apache / APR, modsecurity - the same
445 -ver_test $PV -ge 1.8.0 && CONTRIBS+=( hpack )
446 -
447 -haproxy_use() {
448 - (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
449 -
450 - usex "${1}" "USE_${2}=1" "USE_${2}="
451 -}
452 -
453 -pkg_setup() {
454 - enewgroup haproxy
455 - enewuser haproxy -1 -1 -1 haproxy
456 -
457 - if use net_ns; then
458 - CONFIG_CHECK="~NET_NS"
459 - linux-info_pkg_setup
460 - fi
461 -}
462 -
463 -src_compile() {
464 - local -a args=(
465 - V=1
466 - TARGET=linux2628
467 - USE_GETADDRINFO=1
468 - USE_TFO=1
469 - )
470 -
471 - # TODO: PCRE2_WIDTH?
472 - args+=( $(haproxy_use threads THREAD) )
473 - args+=( $(haproxy_use crypt LIBCRYPT) )
474 - args+=( $(haproxy_use net_ns NS) )
475 - args+=( $(haproxy_use pcre PCRE) )
476 - args+=( $(haproxy_use pcre-jit PCRE_JIT) )
477 - args+=( $(haproxy_use pcre2 PCRE2) )
478 - args+=( $(haproxy_use pcre2-jit PCRE2_JIT) )
479 - args+=( $(haproxy_use ssl OPENSSL) )
480 - args+=( $(haproxy_use slz SLZ) )
481 - args+=( $(haproxy_use zlib ZLIB) )
482 - args+=( $(haproxy_use lua LUA) )
483 - args+=( $(haproxy_use 51degrees 51DEGREES) )
484 - args+=( $(haproxy_use device-atlas DEVICEATLAS) )
485 - args+=( $(haproxy_use wurfl WURFL) )
486 - args+=( $(haproxy_use systemd SYSTEMD) )
487 -
488 - # For now, until the strict-aliasing breakage will be fixed
489 - append-cflags -fno-strict-aliasing
490 -
491 - emake CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
492 - emake -C contrib/systemd SBINDIR=/usr/sbin
493 -
494 - if use tools ; then
495 - for contrib in ${CONTRIBS[@]} ; do
496 - # Those two includes are a workaround for hpack Makefile missing those
497 - emake -C contrib/${contrib} \
498 - CFLAGS="${CFLAGS} -I../../include/ -I../../ebtree/" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
499 - done
500 - fi
501 -}
502 -
503 -src_install() {
504 - dosbin haproxy
505 - dosym ../sbin/haproxy /usr/bin/haproxy
506 -
507 - newconfd "${FILESDIR}/${PN}.confd" $PN
508 - newinitd "${FILESDIR}/${PN}.initd-r6" $PN
509 -
510 - doman doc/haproxy.1
511 -
512 - systemd_dounit contrib/systemd/haproxy.service
513 -
514 - einstalldocs
515 -
516 - # The errorfiles are used by upstream defaults.
517 - insinto /etc/haproxy/errors/
518 - doins examples/errorfiles/*
519 -
520 - if use doc; then
521 - dodoc ROADMAP doc/*.txt
522 - #if use lua; then
523 - # TODO: doc/lua-api/
524 - #fi
525 - fi
526 -
527 - if use tools ; then
528 - has halog "${CONTRIBS[@]}" && dobin contrib/halog/halog
529 - has "iprange" "${CONTRIBS[@]}" && newbin contrib/iprange/iprange haproxy_iprange
530 - has "ip6range" "${CONTRIBS[@]}" && newbin contrib/ip6range/ip6range haproxy_ip6range
531 - has "spoa_example" "${CONTRIBS[@]}" && newbin contrib/spoa_example/spoa haproxy_spoa_example
532 - has "spoa_example" "${CONTRIBS[@]}" && newdoc contrib/spoa_example/README README.spoa_example
533 - has "tcploop" "${CONTRIBS[@]}" && newbin contrib/tcploop/tcploop haproxy_tcploop
534 - has "hpack" "${CONTRIBS[@]}" && newbin contrib/hpack/gen-rht haproxy_hpack
535 - fi
536 -
537 - if use examples ; then
538 - docinto examples
539 - dodoc examples/*.cfg
540 - dodoc examples/seamless_reload.txt
541 - fi
542 -
543 - if use vim-syntax ; then
544 - insinto /usr/share/vim/vimfiles/syntax
545 - doins examples/haproxy.vim
546 - fi
547 -}
548 -
549 -pkg_postinst() {
550 - if [[ ! -f "${EROOT}/etc/haproxy/haproxy.cfg" ]] ; then
551 - ewarn "You need to create /etc/haproxy/haproxy.cfg before you start the haproxy service."
552 - ewarn "It's best practice to not run haproxy as root, user and group haproxy was therefore created."
553 - ewarn "Make use of them with the \"user\" and \"group\" directives."
554 -
555 - if [[ -d "${EROOT}/usr/share/doc/${PF}" ]]; then
556 - einfo "Please consult the installed documentation for learning the configuration file's syntax."
557 - einfo "The documentation and sample configuration files are installed here:"
558 - einfo " ${EROOT}/usr/share/doc/${PF}"
559 - fi
560 - fi
561 -}