From 8b4ace9c50842c5b83401ea7b179dcab940387e1 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Wed, 23 Sep 2020 10:22:15 +0100 Subject: gentoo resync : 23.09.2020 --- net-proxy/haproxy/Manifest | 8 ++ net-proxy/haproxy/haproxy-1.8.26.ebuild | 169 ++++++++++++++++++++++++++++++ net-proxy/haproxy/haproxy-2.0.17.ebuild | 180 ++++++++++++++++++++++++++++++++ net-proxy/haproxy/haproxy-2.1.8.ebuild | 180 ++++++++++++++++++++++++++++++++ net-proxy/haproxy/haproxy-2.2.3.ebuild | 180 ++++++++++++++++++++++++++++++++ 5 files changed, 717 insertions(+) create mode 100644 net-proxy/haproxy/haproxy-1.8.26.ebuild create mode 100644 net-proxy/haproxy/haproxy-2.0.17.ebuild create mode 100644 net-proxy/haproxy/haproxy-2.1.8.ebuild create mode 100644 net-proxy/haproxy/haproxy-2.2.3.ebuild (limited to 'net-proxy/haproxy') diff --git a/net-proxy/haproxy/Manifest b/net-proxy/haproxy/Manifest index cecc7e9d7bfe..2511ed80ea37 100644 --- a/net-proxy/haproxy/Manifest +++ b/net-proxy/haproxy/Manifest @@ -1,24 +1,32 @@ AUX haproxy.confd 610 BLAKE2B 89c6ea0c2f623bbe7aa80a4f42de1d7fb38a2fa6e9edb5b9c758ee1c5140e750fa6be046e4854c94806a609bd3b487f2553bfeafb1db43871032731425b54f59 SHA512 80a6e109432c7e751e9e1063853f73d3269c4c3967728a90cf94230cb32308b396f9f9ad7795b74b919dae4f61e5a29a9ae7badf0908148accbe0e8ca2238913 AUX haproxy.initd-r6 1705 BLAKE2B af8b9ad2fcb499d7fec97fe4210af8685a15881aa98634551bad8ec90bd2fe412a7af337fcb5f3ced7715433fb1d98fa175ecb83fa61108802973976109a7c6d SHA512 59693dfb0ae004559e57fb751ebd4abc85a982733699230ff51aa94a2bb7db9875bc63f6a03355b7434448736beb513e923b2ad9c70661f4110e4b2ad2bba753 DIST haproxy-1.8.25.tar.gz 2184002 BLAKE2B d6ea39af0109eee679d87dde258038bbb38ccf12796b2e6a7172067fce6bd0f10485e2a3d89ca5b3596529db4e34d511bbb194b019c7403703cb636573b0438d SHA512 655eb4056989a3fee321ea9278a2085b0a999e522293f1f6229ebb8d17f3d33cb78abb4fd55a06d0218082e632b2d42de105575d0acd0c1b49996d4b45aa78e8 +DIST haproxy-1.8.26.tar.gz 2205531 BLAKE2B 87aaeb3df6668752ec9242bda86b9b28339ad6926ee3ad16c606239693daa0d957271a76e270bf7d2d64102024121d4e9c1458da0f2e1d9bb8188856c0f68949 SHA512 a88f1fab0c234140e949ca12a87a09d7be1e0888bf2022a19c971727af08e579e3e6318d87411772915df6d73880710e6afdab842b622b6c0fa02020fa5c9425 DIST haproxy-2.0.14.tar.gz 2651320 BLAKE2B dd5aed78e52b3d3dd295f3883d45adf8795efac93cf6c23fbe39be031f29d19adad0afb400e8041281413f4570bc074f06d9cd88bee672789311e56f57b258d0 SHA512 6b63b713a1009eff59a2622fa93462deb8794c910685840f142711a61be88ea228c7cb2ec7ca50bba0803288625e1a65b2d2f87ffbcedfd23debfbbbb5d96993 DIST haproxy-2.0.15.tar.gz 2672167 BLAKE2B 19ffa210a95800e20f5aecbf0a2a99fb977003ba08de4604264ad5d51bcacf51f1898d7c782bfab08653aaf30b706e190fa1caabda1e1a8bd4638c69bae14308 SHA512 cf856b62f0d2e295ebca727e543eab0d91a8188c7ee6ec81f7d42b92b93678996ef05909cfd1d7aeab83208b6a2fc0a20c28a54d119fbbdf20451fc6a7343016 DIST haproxy-2.0.16.tar.gz 2675207 BLAKE2B 0fd26967e20e52ae7be3c6013f3cf49f84e2370fc8eda98acdbd27570579a203f2f123a1d7b2187e23e9897fb40085aaa6420b343dc1abcf2b490df65dbf2401 SHA512 7b634b292fc72aa41d4ba94bef27cfc975c5aeb549d178b2fc24ac5d29a7b92313e218330be70e10294f758e35cf44658f527f5be2fe187bb2e9a7a7116ff381 +DIST haproxy-2.0.17.tar.gz 2676783 BLAKE2B ee17afdf3b34bc28fe810746709ef5cb07cbcc3d7508ab13349f67b59584dfd53d6f2f926615b87095b6f130560a529c480957d62e2943bc0936e1b905896fa9 SHA512 edcd061534ef9a6d7eab9692dccbb22fb7a3bf145cbf555646763c0fd72f7f13d41482744072286327a48951397a11822f1708b26be24b7bc5a327f516ca8816 DIST haproxy-2.1.4.tar.gz 2684568 BLAKE2B 0618e069e6cf6fd20eb9fad0cfcb5ca1714d4001a794e20ce60d812741f4f65d44088c46599e4181cb79536566a940d748030552d0bd010ba14d1552cf7156f4 SHA512 fd029ac1ec877fa89a9410944439b66795b1392b6c8416aaa7978943170530c3826ba50ea706366f3f7785b7cffed58497cb362fc2480dd6920a99af4f920d98 DIST haproxy-2.1.7.tar.gz 2709999 BLAKE2B 74f6fb687d2e8d793773046e3a0919051b52eba0c4a91570ad3c6cf798b66daddaecf173c686d8474deb655d67524d7640753e1f5643cc4af4c339f3104d49bb SHA512 d3338f128042f40e2969094a614eb840b1bf7409efa4f85aed7f45411af8532d2f2371436902e7b987b661580f9c21439fc027a65bb2d352cb86711a26545adb +DIST haproxy-2.1.8.tar.gz 2715203 BLAKE2B fdf0896c8ee7a10268f422058f5a75c2b245da1bffed765dc618f24d18c95704724022f229b82e8df0cf2220dd3b9aa295825a7a6087009123841bead071974f SHA512 6aaf1822e88189344dadc0ab64ccba3268a913a8676a375039cbe5447d5f54957668b23f1314bf68f97c195400f5817a08dd898318368075f73c1a2cca366a78 DIST haproxy-2.2.0.tar.gz 2866916 BLAKE2B 176234efefee72beb1b46e7e8bb2455edc4135323b834a73870e30ca7a439b24cbb62568cb2aacd9d6b4d5c2234ebe7524de119a3ac2ec1c1f701de03a174933 SHA512 25cff09acba29ba36f045d45f894d26a13eea3e71c3e1f868446e739eed1fcfee8fc4af8da2914eef7ecbfe266a498f931cc6ec6c3e73b8874c140618269f480 DIST haproxy-2.2.1.tar.gz 2868436 BLAKE2B 042718186a3b95d506b2fae54db4fa9b03c2f33806ac8392b4465d38a60cf86c9a41b4872286672754d91ad3634c7886a65b96cd3198a82c242ad2b531dd2998 SHA512 2a08003f55c1ec3bda5cad475ca6c3a62f6d6f87fbaaf42facd8bc5579548f8d972124283740e9728b832b38ea87e61a94d8b9685351a68e5ea1f1000deab32b +DIST haproxy-2.2.3.tar.gz 2872195 BLAKE2B 266375aeca17ea0053956d3fd8a4077da70e308501042b67433722f0ed2efbc85438d8cd7a6d7c7a3184349ff6cf6ed5ae90d05a150b6fda1077400f0769d75a SHA512 db99a5069537b6a3f161ad0a32ed884e81e27ed471d7c5f74b0655580c3eb1248376c5b252a9b998bead4fc5c05f28fda9e2280b8b05447bc5bc2d3c8fb55825 EBUILD haproxy-1.8.25-r1.ebuild 4806 BLAKE2B af3c97529af6f1f5e13344ef66c8cddca311cf0c52d9a02dccf5031ef51f090cb7ab356002d78161f1182e84d1da381b08ff2b678e455b27c82f0a6efc414c24 SHA512 07beb412bb20437d94ff8e829741845400ed58f32e5ecc358cbd13ea777b802bf8ce188d7b9b6a9db43bad7bcc1b6136055ed23677ce6b57c8097f03ca607fdc +EBUILD haproxy-1.8.26.ebuild 4806 BLAKE2B af3c97529af6f1f5e13344ef66c8cddca311cf0c52d9a02dccf5031ef51f090cb7ab356002d78161f1182e84d1da381b08ff2b678e455b27c82f0a6efc414c24 SHA512 07beb412bb20437d94ff8e829741845400ed58f32e5ecc358cbd13ea777b802bf8ce188d7b9b6a9db43bad7bcc1b6136055ed23677ce6b57c8097f03ca607fdc EBUILD haproxy-2.0.14-r1.ebuild 5345 BLAKE2B df4570054d3ed94729d8d1b7414a61798973c716f68631ce4f487902e4d0f04ab0fb93cf45b5104c8c4b9541787f12c1cb00e72809447b9a6484ca15322e00e7 SHA512 6bad2f674656e9ed6277c691962cab5add403d6b4ceb7a65f5b7d4e6da4fdf50888c6b9f9a6aee74b8de0dc8f433e93b7c1c0e337a90f64f9be2a3389190ca85 EBUILD haproxy-2.0.14.ebuild 5242 BLAKE2B 208fe423b99ed61c827ff682764eabc638d60c9821b6a3bed62dca12c7573c9bd674a1aa52edd46d4b68611d89796c631bcb9e0a27ebfa69086abdcf37b77db6 SHA512 c52730946f4abd1414917dba166b867e897bcb7ac52e79a73777ed6b8c923289be54089559c92e1409e580a1b6123855545c09b8c4338d2f6f4fa39766e21235 EBUILD haproxy-2.0.15.ebuild 5346 BLAKE2B 4447cc7757537aa0d8dec607a2cadb8e0ca177eb5d2304ddfeece9af1f7e36463f535f8c00341aa604f6ef2bcdbf0772b5b19a0eb87d247244428e15b0c41f17 SHA512 f07a595c679fe8db7a6f8cf63cf30c95851430e50f1289ca3a6589ef52ad817bd6d2f9d6a44f6e382c2e3a7c6c122e7cb76a79b95dd4dbc0206c0c33afabc0cd EBUILD haproxy-2.0.16.ebuild 5346 BLAKE2B 4447cc7757537aa0d8dec607a2cadb8e0ca177eb5d2304ddfeece9af1f7e36463f535f8c00341aa604f6ef2bcdbf0772b5b19a0eb87d247244428e15b0c41f17 SHA512 f07a595c679fe8db7a6f8cf63cf30c95851430e50f1289ca3a6589ef52ad817bd6d2f9d6a44f6e382c2e3a7c6c122e7cb76a79b95dd4dbc0206c0c33afabc0cd +EBUILD haproxy-2.0.17.ebuild 5346 BLAKE2B 4447cc7757537aa0d8dec607a2cadb8e0ca177eb5d2304ddfeece9af1f7e36463f535f8c00341aa604f6ef2bcdbf0772b5b19a0eb87d247244428e15b0c41f17 SHA512 f07a595c679fe8db7a6f8cf63cf30c95851430e50f1289ca3a6589ef52ad817bd6d2f9d6a44f6e382c2e3a7c6c122e7cb76a79b95dd4dbc0206c0c33afabc0cd EBUILD haproxy-2.0.9999.ebuild 5224 BLAKE2B 65616d45e46a318de40c7edd0a12843741784181a62f6991b49137fb2e04e479634851138b2ead576c82d3e8160d0e6706ce78da9bb81addf41ef6e2ecd18f4a SHA512 e6b4a5f154e17f96d124ccb723ab5bdcb389f89995a98e65d2f3199780d502b99da4defdba724c13ec6889bf82ec332e5757383c6b7cdd8b01786689e58e872b EBUILD haproxy-2.1.4-r1.ebuild 5345 BLAKE2B df4570054d3ed94729d8d1b7414a61798973c716f68631ce4f487902e4d0f04ab0fb93cf45b5104c8c4b9541787f12c1cb00e72809447b9a6484ca15322e00e7 SHA512 6bad2f674656e9ed6277c691962cab5add403d6b4ceb7a65f5b7d4e6da4fdf50888c6b9f9a6aee74b8de0dc8f433e93b7c1c0e337a90f64f9be2a3389190ca85 EBUILD haproxy-2.1.4.ebuild 5242 BLAKE2B 208fe423b99ed61c827ff682764eabc638d60c9821b6a3bed62dca12c7573c9bd674a1aa52edd46d4b68611d89796c631bcb9e0a27ebfa69086abdcf37b77db6 SHA512 c52730946f4abd1414917dba166b867e897bcb7ac52e79a73777ed6b8c923289be54089559c92e1409e580a1b6123855545c09b8c4338d2f6f4fa39766e21235 EBUILD haproxy-2.1.7.ebuild 5346 BLAKE2B 4447cc7757537aa0d8dec607a2cadb8e0ca177eb5d2304ddfeece9af1f7e36463f535f8c00341aa604f6ef2bcdbf0772b5b19a0eb87d247244428e15b0c41f17 SHA512 f07a595c679fe8db7a6f8cf63cf30c95851430e50f1289ca3a6589ef52ad817bd6d2f9d6a44f6e382c2e3a7c6c122e7cb76a79b95dd4dbc0206c0c33afabc0cd +EBUILD haproxy-2.1.8.ebuild 5346 BLAKE2B 4447cc7757537aa0d8dec607a2cadb8e0ca177eb5d2304ddfeece9af1f7e36463f535f8c00341aa604f6ef2bcdbf0772b5b19a0eb87d247244428e15b0c41f17 SHA512 f07a595c679fe8db7a6f8cf63cf30c95851430e50f1289ca3a6589ef52ad817bd6d2f9d6a44f6e382c2e3a7c6c122e7cb76a79b95dd4dbc0206c0c33afabc0cd EBUILD haproxy-2.1.9999.ebuild 5346 BLAKE2B 4447cc7757537aa0d8dec607a2cadb8e0ca177eb5d2304ddfeece9af1f7e36463f535f8c00341aa604f6ef2bcdbf0772b5b19a0eb87d247244428e15b0c41f17 SHA512 f07a595c679fe8db7a6f8cf63cf30c95851430e50f1289ca3a6589ef52ad817bd6d2f9d6a44f6e382c2e3a7c6c122e7cb76a79b95dd4dbc0206c0c33afabc0cd EBUILD haproxy-2.2.0.ebuild 5346 BLAKE2B 4447cc7757537aa0d8dec607a2cadb8e0ca177eb5d2304ddfeece9af1f7e36463f535f8c00341aa604f6ef2bcdbf0772b5b19a0eb87d247244428e15b0c41f17 SHA512 f07a595c679fe8db7a6f8cf63cf30c95851430e50f1289ca3a6589ef52ad817bd6d2f9d6a44f6e382c2e3a7c6c122e7cb76a79b95dd4dbc0206c0c33afabc0cd EBUILD haproxy-2.2.1.ebuild 5346 BLAKE2B 4447cc7757537aa0d8dec607a2cadb8e0ca177eb5d2304ddfeece9af1f7e36463f535f8c00341aa604f6ef2bcdbf0772b5b19a0eb87d247244428e15b0c41f17 SHA512 f07a595c679fe8db7a6f8cf63cf30c95851430e50f1289ca3a6589ef52ad817bd6d2f9d6a44f6e382c2e3a7c6c122e7cb76a79b95dd4dbc0206c0c33afabc0cd +EBUILD haproxy-2.2.3.ebuild 5346 BLAKE2B 4447cc7757537aa0d8dec607a2cadb8e0ca177eb5d2304ddfeece9af1f7e36463f535f8c00341aa604f6ef2bcdbf0772b5b19a0eb87d247244428e15b0c41f17 SHA512 f07a595c679fe8db7a6f8cf63cf30c95851430e50f1289ca3a6589ef52ad817bd6d2f9d6a44f6e382c2e3a7c6c122e7cb76a79b95dd4dbc0206c0c33afabc0cd EBUILD haproxy-2.2.9999.ebuild 5346 BLAKE2B 4447cc7757537aa0d8dec607a2cadb8e0ca177eb5d2304ddfeece9af1f7e36463f535f8c00341aa604f6ef2bcdbf0772b5b19a0eb87d247244428e15b0c41f17 SHA512 f07a595c679fe8db7a6f8cf63cf30c95851430e50f1289ca3a6589ef52ad817bd6d2f9d6a44f6e382c2e3a7c6c122e7cb76a79b95dd4dbc0206c0c33afabc0cd MISC metadata.xml 2148 BLAKE2B 2f273c8d5c4704b482cf5b09e038415e0faa6ecba7297f99d0c55d96ba0b8f0bfa50b21dc857680951c3b4794be98f8781a6d1dcfb622ec5f6827648cfdd247e SHA512 91834d33a145ce6f887f83849ea90da984cf131e657824e63fb44b49761dc9999c00796fb20879cc670b83a2f4aae2263aeacc1dc6bf71b9db34a21ef9a3026d diff --git a/net-proxy/haproxy/haproxy-1.8.26.ebuild b/net-proxy/haproxy/haproxy-1.8.26.ebuild new file mode 100644 index 000000000000..2c5c63d0d07c --- /dev/null +++ b/net-proxy/haproxy/haproxy-1.8.26.ebuild @@ -0,0 +1,169 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +[[ ${PV} == *9999 ]] && SCM="git-r3" +inherit toolchain-funcs flag-o-matic systemd linux-info $SCM + +MY_P="${PN}-${PV/_beta/-dev}" + +DESCRIPTION="A TCP/HTTP reverse proxy for high availability environments" +HOMEPAGE="http://www.haproxy.org" +if [[ ${PV} != *9999 ]]; then + SRC_URI="http://haproxy.1wt.eu/download/$(ver_cut 1-2)/src/${MY_P}.tar.gz" + KEYWORDS="~amd64 ~arm ~ppc ~x86" +else + EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(ver_cut 1-2).git/" + EGIT_BRANCH=master +fi + +LICENSE="GPL-2 LGPL-2.1" +SLOT="0" +IUSE="+crypt doc examples libressl slz net_ns +pcre pcre-jit pcre2 pcre2-jit ssl +systemd +threads tools vim-syntax +zlib lua device-atlas 51degrees wurfl" +REQUIRED_USE="pcre-jit? ( pcre ) + pcre2-jit? ( pcre2 ) + pcre? ( !pcre2 ) + device-atlas? ( pcre ) + ?? ( slz zlib )" + +DEPEND=" + pcre? ( + dev-libs/libpcre + pcre-jit? ( dev-libs/libpcre[jit] ) + ) + pcre2? ( + dev-libs/libpcre + pcre2-jit? ( dev-libs/libpcre2[jit] ) + ) + ssl? ( + !libressl? ( dev-libs/openssl:0=[zlib?] ) + libressl? ( dev-libs/libressl:0= ) + ) + slz? ( dev-libs/libslz:= ) + zlib? ( sys-libs/zlib ) + lua? ( dev-lang/lua:5.3 ) + device-atlas? ( dev-libs/device-atlas-api-c )" +RDEPEND="${DEPEND} + acct-group/haproxy + acct-user/haproxy" + +S="${WORKDIR}/${MY_P}" + +DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README ) +CONTRIBS=( halog iprange ) +# ip6range is present in 1.6, but broken. +ver_test $PV -ge 1.7.0 && CONTRIBS+=( ip6range spoa_example tcploop ) +# TODO: mod_defender - requires apache / APR, modsecurity - the same +ver_test $PV -ge 1.8.0 && CONTRIBS+=( hpack ) + +haproxy_use() { + (( $# != 2 )) && die "${FUNCNAME} " + + usex "${1}" "USE_${2}=1" "USE_${2}=" +} + +pkg_setup() { + if use net_ns; then + CONFIG_CHECK="~NET_NS" + linux-info_pkg_setup + fi +} + +src_compile() { + local -a args=( + V=1 + TARGET=linux2628 + USE_GETADDRINFO=1 + USE_TFO=1 + ) + + # TODO: PCRE2_WIDTH? + args+=( $(haproxy_use threads THREAD) ) + args+=( $(haproxy_use crypt LIBCRYPT) ) + args+=( $(haproxy_use net_ns NS) ) + args+=( $(haproxy_use pcre PCRE) ) + args+=( $(haproxy_use pcre-jit PCRE_JIT) ) + args+=( $(haproxy_use ssl OPENSSL) ) + args+=( $(haproxy_use slz SLZ) ) + args+=( $(haproxy_use zlib ZLIB) ) + args+=( $(haproxy_use lua LUA) ) + args+=( $(haproxy_use 51degrees 51DEGREES) ) + args+=( $(haproxy_use device-atlas DEVICEATLAS) ) + args+=( $(haproxy_use wurfl WURFL) ) + args+=( $(haproxy_use systemd SYSTEMD) ) + + # For now, until the strict-aliasing breakage will be fixed + append-cflags -fno-strict-aliasing + + emake CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]} + emake -C contrib/systemd SBINDIR=/usr/sbin + + if use tools ; then + for contrib in ${CONTRIBS[@]} ; do + emake -C contrib/${contrib} \ + CFLAGS="${CFLAGS}" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]} + done + fi +} + +src_install() { + dosbin haproxy + dosym ../sbin/haproxy /usr/bin/haproxy + + newconfd "${FILESDIR}/${PN}.confd" $PN + newinitd "${FILESDIR}/${PN}.initd-r6" $PN + + doman doc/haproxy.1 + + systemd_dounit contrib/systemd/haproxy.service + + einstalldocs + + # The errorfiles are used by upstream defaults. + insinto /etc/haproxy/errors/ + doins examples/errorfiles/* + + if use doc; then + dodoc ROADMAP doc/*.txt + #if use lua; then + # TODO: doc/lua-api/ + #fi + fi + + if use tools ; then + has halog "${CONTRIBS[@]}" && dobin contrib/halog/halog + has "iprange" "${CONTRIBS[@]}" && newbin contrib/iprange/iprange haproxy_iprange + has "ip6range" "${CONTRIBS[@]}" && newbin contrib/ip6range/ip6range haproxy_ip6range + has "spoa_example" "${CONTRIBS[@]}" && newbin contrib/spoa_example/spoa haproxy_spoa_example + has "spoa_example" "${CONTRIBS[@]}" && newdoc contrib/spoa_example/README README.spoa_example + has "tcploop" "${CONTRIBS[@]}" && newbin contrib/tcploop/tcploop haproxy_tcploop + has "hpack" "${CONTRIBS[@]}" && newbin contrib/hpack/gen-rht haproxy_hpack + fi + + if use examples ; then + docinto examples + dodoc examples/*.cfg + dodoc examples/seamless_reload.txt + fi + + if use vim-syntax ; then + insinto /usr/share/vim/vimfiles/syntax + doins examples/haproxy.vim + fi +} + +pkg_postinst() { + if [[ ! -f "${EROOT}/etc/haproxy/haproxy.cfg" ]] ; then + ewarn "You need to create /etc/haproxy/haproxy.cfg before you start the haproxy service." + ewarn "It's best practice to not run haproxy as root, user and group haproxy was therefore created." + ewarn "Make use of them with the \"user\" and \"group\" directives." + + if [[ -d "${EROOT}/usr/share/doc/${PF}" ]]; then + einfo "Please consult the installed documentation for learning the configuration file's syntax." + einfo "The documentation and sample configuration files are installed here:" + einfo " ${EROOT}/usr/share/doc/${PF}" + fi + fi +} diff --git a/net-proxy/haproxy/haproxy-2.0.17.ebuild b/net-proxy/haproxy/haproxy-2.0.17.ebuild new file mode 100644 index 000000000000..d1c45681b560 --- /dev/null +++ b/net-proxy/haproxy/haproxy-2.0.17.ebuild @@ -0,0 +1,180 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +[[ ${PV} == *9999 ]] && SCM="git-r3" +inherit toolchain-funcs flag-o-matic systemd linux-info $SCM + +MY_P="${PN}-${PV/_beta/-dev}" + +DESCRIPTION="A TCP/HTTP reverse proxy for high availability environments" +HOMEPAGE="http://www.haproxy.org" +if [[ ${PV} != *9999 ]]; then + SRC_URI="http://haproxy.1wt.eu/download/$(ver_cut 1-2)/src/${MY_P}.tar.gz" + KEYWORDS="~amd64 ~arm ~ppc ~x86" +else + EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(ver_cut 1-2).git/" + EGIT_BRANCH=master +fi + +LICENSE="GPL-2 LGPL-2.1" +SLOT="0" +IUSE="+crypt doc examples libressl slz +net_ns +pcre pcre-jit pcre2 pcre2-jit prometheus-exporter +ssl systemd +threads tools vim-syntax +zlib lua device-atlas 51degrees wurfl" +REQUIRED_USE="pcre-jit? ( pcre ) + pcre2-jit? ( pcre2 ) + pcre? ( !pcre2 ) + device-atlas? ( pcre ) + ?? ( slz zlib )" + +DEPEND=" + pcre? ( + dev-libs/libpcre + pcre-jit? ( dev-libs/libpcre[jit] ) + ) + pcre2? ( + dev-libs/libpcre + pcre2-jit? ( dev-libs/libpcre2[jit] ) + ) + ssl? ( + !libressl? ( dev-libs/openssl:0=[zlib?] ) + libressl? ( dev-libs/libressl:0= ) + ) + slz? ( dev-libs/libslz:= ) + zlib? ( sys-libs/zlib ) + lua? ( dev-lang/lua:5.3 ) + device-atlas? ( dev-libs/device-atlas-api-c )" +RDEPEND="${DEPEND} + acct-group/haproxy + acct-user/haproxy" + +S="${WORKDIR}/${MY_P}" + +DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README ) +CONTRIBS=( halog iprange ) +# ip6range is present in 1.6, but broken. +ver_test $PV -ge 1.7.0 && CONTRIBS+=( ip6range spoa_example tcploop ) +# TODO: mod_defender - requires apache / APR, modsecurity - the same +ver_test $PV -ge 1.8.0 && CONTRIBS+=( hpack ) + +haproxy_use() { + (( $# != 2 )) && die "${FUNCNAME} " + + usex "${1}" "USE_${2}=1" "USE_${2}=" +} + +pkg_setup() { + if use net_ns; then + CONFIG_CHECK="~NET_NS" + linux-info_pkg_setup + fi +} + +src_compile() { + local -a args=( + V=1 + TARGET=linux-glibc + ) + + # TODO: PCRE2_WIDTH? + args+=( $(haproxy_use threads THREAD) ) + args+=( $(haproxy_use crypt LIBCRYPT) ) + args+=( $(haproxy_use net_ns NS) ) + args+=( $(haproxy_use pcre PCRE) ) + args+=( $(haproxy_use pcre-jit PCRE_JIT) ) + args+=( $(haproxy_use pcre2 PCRE2) ) + args+=( $(haproxy_use pcre2-jit PCRE2_JIT) ) + args+=( $(haproxy_use ssl OPENSSL) ) + args+=( $(haproxy_use slz SLZ) ) + args+=( $(haproxy_use zlib ZLIB) ) + args+=( $(haproxy_use lua LUA) ) + args+=( $(haproxy_use 51degrees 51DEGREES) ) + args+=( $(haproxy_use device-atlas DEVICEATLAS) ) + args+=( $(haproxy_use wurfl WURFL) ) + args+=( $(haproxy_use systemd SYSTEMD) ) + + # For now, until the strict-aliasing breakage will be fixed + append-cflags -fno-strict-aliasing + + # Bug #668002 + if use ppc || use arm || use hppa; then + TARGET_LDFLAGS=-latomic + fi + + if use prometheus-exporter; then + EXTRA_OBJS="contrib/prometheus-exporter/service-prometheus.o" + fi + + # HAProxy really needs some of those "SPEC_CFLAGS", like -fno-strict-aliasing + emake CFLAGS="${CFLAGS} \$(SPEC_CFLAGS)" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) EXTRA_OBJS="${EXTRA_OBJS}" TARGET_LDFLAGS="${TARGET_LDFLAGS}" ${args[@]} + emake -C contrib/systemd SBINDIR=/usr/sbin + + if use tools ; then + for contrib in ${CONTRIBS[@]} ; do + # Those two includes are a workaround for hpack Makefile missing those + emake -C contrib/${contrib} \ + CFLAGS="${CFLAGS} -I../../include/ -I../../ebtree/" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]} + done + fi +} + +src_install() { + dosbin haproxy + dosym ../sbin/haproxy /usr/bin/haproxy + + newconfd "${FILESDIR}/${PN}.confd" $PN + newinitd "${FILESDIR}/${PN}.initd-r6" $PN + + doman doc/haproxy.1 + + systemd_dounit contrib/systemd/haproxy.service + + einstalldocs + + # The errorfiles are used by upstream defaults. + insinto /etc/haproxy/errors/ + doins examples/errorfiles/* + + if use doc; then + dodoc ROADMAP doc/*.txt + #if use lua; then + # TODO: doc/lua-api/ + #fi + fi + + if use tools ; then + has halog "${CONTRIBS[@]}" && dobin contrib/halog/halog + has "iprange" "${CONTRIBS[@]}" && newbin contrib/iprange/iprange haproxy_iprange + has "ip6range" "${CONTRIBS[@]}" && newbin contrib/ip6range/ip6range haproxy_ip6range + has "spoa_example" "${CONTRIBS[@]}" && newbin contrib/spoa_example/spoa haproxy_spoa_example + has "spoa_example" "${CONTRIBS[@]}" && newdoc contrib/spoa_example/README README.spoa_example + has "tcploop" "${CONTRIBS[@]}" && newbin contrib/tcploop/tcploop haproxy_tcploop + has "hpack" "${CONTRIBS[@]}" && newbin contrib/hpack/gen-rht haproxy_hpack + fi + + if use examples ; then + docinto examples + dodoc examples/*.cfg + dodoc doc/seamless_reload.txt + fi + + if use vim-syntax ; then + insinto /usr/share/vim/vimfiles/syntax + doins contrib/syntax-highlight/haproxy.vim + fi +} + +pkg_postinst() { + if [[ ! -f "${EROOT}/etc/haproxy/haproxy.cfg" ]] ; then + ewarn "You need to create /etc/haproxy/haproxy.cfg before you start the haproxy service." + ewarn "It's best practice to not run haproxy as root, user and group haproxy was therefore created." + ewarn "Make use of them with the \"user\" and \"group\" directives." + + if [[ -d "${EROOT}/usr/share/doc/${PF}" ]]; then + einfo "Please consult the installed documentation for learning the configuration file's syntax." + einfo "The documentation and sample configuration files are installed here:" + einfo " ${EROOT}/usr/share/doc/${PF}" + fi + fi +} diff --git a/net-proxy/haproxy/haproxy-2.1.8.ebuild b/net-proxy/haproxy/haproxy-2.1.8.ebuild new file mode 100644 index 000000000000..d1c45681b560 --- /dev/null +++ b/net-proxy/haproxy/haproxy-2.1.8.ebuild @@ -0,0 +1,180 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +[[ ${PV} == *9999 ]] && SCM="git-r3" +inherit toolchain-funcs flag-o-matic systemd linux-info $SCM + +MY_P="${PN}-${PV/_beta/-dev}" + +DESCRIPTION="A TCP/HTTP reverse proxy for high availability environments" +HOMEPAGE="http://www.haproxy.org" +if [[ ${PV} != *9999 ]]; then + SRC_URI="http://haproxy.1wt.eu/download/$(ver_cut 1-2)/src/${MY_P}.tar.gz" + KEYWORDS="~amd64 ~arm ~ppc ~x86" +else + EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(ver_cut 1-2).git/" + EGIT_BRANCH=master +fi + +LICENSE="GPL-2 LGPL-2.1" +SLOT="0" +IUSE="+crypt doc examples libressl slz +net_ns +pcre pcre-jit pcre2 pcre2-jit prometheus-exporter +ssl systemd +threads tools vim-syntax +zlib lua device-atlas 51degrees wurfl" +REQUIRED_USE="pcre-jit? ( pcre ) + pcre2-jit? ( pcre2 ) + pcre? ( !pcre2 ) + device-atlas? ( pcre ) + ?? ( slz zlib )" + +DEPEND=" + pcre? ( + dev-libs/libpcre + pcre-jit? ( dev-libs/libpcre[jit] ) + ) + pcre2? ( + dev-libs/libpcre + pcre2-jit? ( dev-libs/libpcre2[jit] ) + ) + ssl? ( + !libressl? ( dev-libs/openssl:0=[zlib?] ) + libressl? ( dev-libs/libressl:0= ) + ) + slz? ( dev-libs/libslz:= ) + zlib? ( sys-libs/zlib ) + lua? ( dev-lang/lua:5.3 ) + device-atlas? ( dev-libs/device-atlas-api-c )" +RDEPEND="${DEPEND} + acct-group/haproxy + acct-user/haproxy" + +S="${WORKDIR}/${MY_P}" + +DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README ) +CONTRIBS=( halog iprange ) +# ip6range is present in 1.6, but broken. +ver_test $PV -ge 1.7.0 && CONTRIBS+=( ip6range spoa_example tcploop ) +# TODO: mod_defender - requires apache / APR, modsecurity - the same +ver_test $PV -ge 1.8.0 && CONTRIBS+=( hpack ) + +haproxy_use() { + (( $# != 2 )) && die "${FUNCNAME} " + + usex "${1}" "USE_${2}=1" "USE_${2}=" +} + +pkg_setup() { + if use net_ns; then + CONFIG_CHECK="~NET_NS" + linux-info_pkg_setup + fi +} + +src_compile() { + local -a args=( + V=1 + TARGET=linux-glibc + ) + + # TODO: PCRE2_WIDTH? + args+=( $(haproxy_use threads THREAD) ) + args+=( $(haproxy_use crypt LIBCRYPT) ) + args+=( $(haproxy_use net_ns NS) ) + args+=( $(haproxy_use pcre PCRE) ) + args+=( $(haproxy_use pcre-jit PCRE_JIT) ) + args+=( $(haproxy_use pcre2 PCRE2) ) + args+=( $(haproxy_use pcre2-jit PCRE2_JIT) ) + args+=( $(haproxy_use ssl OPENSSL) ) + args+=( $(haproxy_use slz SLZ) ) + args+=( $(haproxy_use zlib ZLIB) ) + args+=( $(haproxy_use lua LUA) ) + args+=( $(haproxy_use 51degrees 51DEGREES) ) + args+=( $(haproxy_use device-atlas DEVICEATLAS) ) + args+=( $(haproxy_use wurfl WURFL) ) + args+=( $(haproxy_use systemd SYSTEMD) ) + + # For now, until the strict-aliasing breakage will be fixed + append-cflags -fno-strict-aliasing + + # Bug #668002 + if use ppc || use arm || use hppa; then + TARGET_LDFLAGS=-latomic + fi + + if use prometheus-exporter; then + EXTRA_OBJS="contrib/prometheus-exporter/service-prometheus.o" + fi + + # HAProxy really needs some of those "SPEC_CFLAGS", like -fno-strict-aliasing + emake CFLAGS="${CFLAGS} \$(SPEC_CFLAGS)" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) EXTRA_OBJS="${EXTRA_OBJS}" TARGET_LDFLAGS="${TARGET_LDFLAGS}" ${args[@]} + emake -C contrib/systemd SBINDIR=/usr/sbin + + if use tools ; then + for contrib in ${CONTRIBS[@]} ; do + # Those two includes are a workaround for hpack Makefile missing those + emake -C contrib/${contrib} \ + CFLAGS="${CFLAGS} -I../../include/ -I../../ebtree/" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]} + done + fi +} + +src_install() { + dosbin haproxy + dosym ../sbin/haproxy /usr/bin/haproxy + + newconfd "${FILESDIR}/${PN}.confd" $PN + newinitd "${FILESDIR}/${PN}.initd-r6" $PN + + doman doc/haproxy.1 + + systemd_dounit contrib/systemd/haproxy.service + + einstalldocs + + # The errorfiles are used by upstream defaults. + insinto /etc/haproxy/errors/ + doins examples/errorfiles/* + + if use doc; then + dodoc ROADMAP doc/*.txt + #if use lua; then + # TODO: doc/lua-api/ + #fi + fi + + if use tools ; then + has halog "${CONTRIBS[@]}" && dobin contrib/halog/halog + has "iprange" "${CONTRIBS[@]}" && newbin contrib/iprange/iprange haproxy_iprange + has "ip6range" "${CONTRIBS[@]}" && newbin contrib/ip6range/ip6range haproxy_ip6range + has "spoa_example" "${CONTRIBS[@]}" && newbin contrib/spoa_example/spoa haproxy_spoa_example + has "spoa_example" "${CONTRIBS[@]}" && newdoc contrib/spoa_example/README README.spoa_example + has "tcploop" "${CONTRIBS[@]}" && newbin contrib/tcploop/tcploop haproxy_tcploop + has "hpack" "${CONTRIBS[@]}" && newbin contrib/hpack/gen-rht haproxy_hpack + fi + + if use examples ; then + docinto examples + dodoc examples/*.cfg + dodoc doc/seamless_reload.txt + fi + + if use vim-syntax ; then + insinto /usr/share/vim/vimfiles/syntax + doins contrib/syntax-highlight/haproxy.vim + fi +} + +pkg_postinst() { + if [[ ! -f "${EROOT}/etc/haproxy/haproxy.cfg" ]] ; then + ewarn "You need to create /etc/haproxy/haproxy.cfg before you start the haproxy service." + ewarn "It's best practice to not run haproxy as root, user and group haproxy was therefore created." + ewarn "Make use of them with the \"user\" and \"group\" directives." + + if [[ -d "${EROOT}/usr/share/doc/${PF}" ]]; then + einfo "Please consult the installed documentation for learning the configuration file's syntax." + einfo "The documentation and sample configuration files are installed here:" + einfo " ${EROOT}/usr/share/doc/${PF}" + fi + fi +} diff --git a/net-proxy/haproxy/haproxy-2.2.3.ebuild b/net-proxy/haproxy/haproxy-2.2.3.ebuild new file mode 100644 index 000000000000..d1c45681b560 --- /dev/null +++ b/net-proxy/haproxy/haproxy-2.2.3.ebuild @@ -0,0 +1,180 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +[[ ${PV} == *9999 ]] && SCM="git-r3" +inherit toolchain-funcs flag-o-matic systemd linux-info $SCM + +MY_P="${PN}-${PV/_beta/-dev}" + +DESCRIPTION="A TCP/HTTP reverse proxy for high availability environments" +HOMEPAGE="http://www.haproxy.org" +if [[ ${PV} != *9999 ]]; then + SRC_URI="http://haproxy.1wt.eu/download/$(ver_cut 1-2)/src/${MY_P}.tar.gz" + KEYWORDS="~amd64 ~arm ~ppc ~x86" +else + EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(ver_cut 1-2).git/" + EGIT_BRANCH=master +fi + +LICENSE="GPL-2 LGPL-2.1" +SLOT="0" +IUSE="+crypt doc examples libressl slz +net_ns +pcre pcre-jit pcre2 pcre2-jit prometheus-exporter +ssl systemd +threads tools vim-syntax +zlib lua device-atlas 51degrees wurfl" +REQUIRED_USE="pcre-jit? ( pcre ) + pcre2-jit? ( pcre2 ) + pcre? ( !pcre2 ) + device-atlas? ( pcre ) + ?? ( slz zlib )" + +DEPEND=" + pcre? ( + dev-libs/libpcre + pcre-jit? ( dev-libs/libpcre[jit] ) + ) + pcre2? ( + dev-libs/libpcre + pcre2-jit? ( dev-libs/libpcre2[jit] ) + ) + ssl? ( + !libressl? ( dev-libs/openssl:0=[zlib?] ) + libressl? ( dev-libs/libressl:0= ) + ) + slz? ( dev-libs/libslz:= ) + zlib? ( sys-libs/zlib ) + lua? ( dev-lang/lua:5.3 ) + device-atlas? ( dev-libs/device-atlas-api-c )" +RDEPEND="${DEPEND} + acct-group/haproxy + acct-user/haproxy" + +S="${WORKDIR}/${MY_P}" + +DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README ) +CONTRIBS=( halog iprange ) +# ip6range is present in 1.6, but broken. +ver_test $PV -ge 1.7.0 && CONTRIBS+=( ip6range spoa_example tcploop ) +# TODO: mod_defender - requires apache / APR, modsecurity - the same +ver_test $PV -ge 1.8.0 && CONTRIBS+=( hpack ) + +haproxy_use() { + (( $# != 2 )) && die "${FUNCNAME} " + + usex "${1}" "USE_${2}=1" "USE_${2}=" +} + +pkg_setup() { + if use net_ns; then + CONFIG_CHECK="~NET_NS" + linux-info_pkg_setup + fi +} + +src_compile() { + local -a args=( + V=1 + TARGET=linux-glibc + ) + + # TODO: PCRE2_WIDTH? + args+=( $(haproxy_use threads THREAD) ) + args+=( $(haproxy_use crypt LIBCRYPT) ) + args+=( $(haproxy_use net_ns NS) ) + args+=( $(haproxy_use pcre PCRE) ) + args+=( $(haproxy_use pcre-jit PCRE_JIT) ) + args+=( $(haproxy_use pcre2 PCRE2) ) + args+=( $(haproxy_use pcre2-jit PCRE2_JIT) ) + args+=( $(haproxy_use ssl OPENSSL) ) + args+=( $(haproxy_use slz SLZ) ) + args+=( $(haproxy_use zlib ZLIB) ) + args+=( $(haproxy_use lua LUA) ) + args+=( $(haproxy_use 51degrees 51DEGREES) ) + args+=( $(haproxy_use device-atlas DEVICEATLAS) ) + args+=( $(haproxy_use wurfl WURFL) ) + args+=( $(haproxy_use systemd SYSTEMD) ) + + # For now, until the strict-aliasing breakage will be fixed + append-cflags -fno-strict-aliasing + + # Bug #668002 + if use ppc || use arm || use hppa; then + TARGET_LDFLAGS=-latomic + fi + + if use prometheus-exporter; then + EXTRA_OBJS="contrib/prometheus-exporter/service-prometheus.o" + fi + + # HAProxy really needs some of those "SPEC_CFLAGS", like -fno-strict-aliasing + emake CFLAGS="${CFLAGS} \$(SPEC_CFLAGS)" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) EXTRA_OBJS="${EXTRA_OBJS}" TARGET_LDFLAGS="${TARGET_LDFLAGS}" ${args[@]} + emake -C contrib/systemd SBINDIR=/usr/sbin + + if use tools ; then + for contrib in ${CONTRIBS[@]} ; do + # Those two includes are a workaround for hpack Makefile missing those + emake -C contrib/${contrib} \ + CFLAGS="${CFLAGS} -I../../include/ -I../../ebtree/" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]} + done + fi +} + +src_install() { + dosbin haproxy + dosym ../sbin/haproxy /usr/bin/haproxy + + newconfd "${FILESDIR}/${PN}.confd" $PN + newinitd "${FILESDIR}/${PN}.initd-r6" $PN + + doman doc/haproxy.1 + + systemd_dounit contrib/systemd/haproxy.service + + einstalldocs + + # The errorfiles are used by upstream defaults. + insinto /etc/haproxy/errors/ + doins examples/errorfiles/* + + if use doc; then + dodoc ROADMAP doc/*.txt + #if use lua; then + # TODO: doc/lua-api/ + #fi + fi + + if use tools ; then + has halog "${CONTRIBS[@]}" && dobin contrib/halog/halog + has "iprange" "${CONTRIBS[@]}" && newbin contrib/iprange/iprange haproxy_iprange + has "ip6range" "${CONTRIBS[@]}" && newbin contrib/ip6range/ip6range haproxy_ip6range + has "spoa_example" "${CONTRIBS[@]}" && newbin contrib/spoa_example/spoa haproxy_spoa_example + has "spoa_example" "${CONTRIBS[@]}" && newdoc contrib/spoa_example/README README.spoa_example + has "tcploop" "${CONTRIBS[@]}" && newbin contrib/tcploop/tcploop haproxy_tcploop + has "hpack" "${CONTRIBS[@]}" && newbin contrib/hpack/gen-rht haproxy_hpack + fi + + if use examples ; then + docinto examples + dodoc examples/*.cfg + dodoc doc/seamless_reload.txt + fi + + if use vim-syntax ; then + insinto /usr/share/vim/vimfiles/syntax + doins contrib/syntax-highlight/haproxy.vim + fi +} + +pkg_postinst() { + if [[ ! -f "${EROOT}/etc/haproxy/haproxy.cfg" ]] ; then + ewarn "You need to create /etc/haproxy/haproxy.cfg before you start the haproxy service." + ewarn "It's best practice to not run haproxy as root, user and group haproxy was therefore created." + ewarn "Make use of them with the \"user\" and \"group\" directives." + + if [[ -d "${EROOT}/usr/share/doc/${PF}" ]]; then + einfo "Please consult the installed documentation for learning the configuration file's syntax." + einfo "The documentation and sample configuration files are installed here:" + einfo " ${EROOT}/usr/share/doc/${PF}" + fi + fi +} -- cgit v1.2.3