From fd70f5e3ed54d5e013c11a3f3e632e80838171d0 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 23 Jul 2022 02:48:52 +0100 Subject: gentoo auto-resync : 23:07:2022 - 02:48:51 --- net-proxy/Manifest.gz | Bin 5366 -> 5363 bytes net-proxy/haproxy/Manifest | 10 +- net-proxy/haproxy/haproxy-2.4.9999.ebuild | 4 - net-proxy/haproxy/haproxy-2.6.1.ebuild | 181 ------------------------------ net-proxy/haproxy/haproxy-2.6.2.ebuild | 177 +++++++++++++++++++++++++++++ net-proxy/haproxy/haproxy-2.6.9999.ebuild | 4 - net-proxy/haproxy/haproxy-9999.ebuild | 4 - 7 files changed, 182 insertions(+), 198 deletions(-) delete mode 100644 net-proxy/haproxy/haproxy-2.6.1.ebuild create mode 100644 net-proxy/haproxy/haproxy-2.6.2.ebuild (limited to 'net-proxy') diff --git a/net-proxy/Manifest.gz b/net-proxy/Manifest.gz index 92fd6dee1994..6fed45869a2e 100644 Binary files a/net-proxy/Manifest.gz and b/net-proxy/Manifest.gz differ diff --git a/net-proxy/haproxy/Manifest b/net-proxy/haproxy/Manifest index d983dd1dc71e..71d6e133f802 100644 --- a/net-proxy/haproxy/Manifest +++ b/net-proxy/haproxy/Manifest @@ -9,18 +9,18 @@ DIST haproxy-2.4.14.tar.gz 3613642 BLAKE2B b45af8f62cefead1f471b0b61e9bc262dc25e DIST haproxy-2.4.17.tar.gz 3623854 BLAKE2B 54797eb6a16a100951ee9e0bb972a7fbdd8ffd22bd1feccdf41743d86ff37b71de54109504ae339007533d41b507b1abb74d8219e4a06320a13e0fce3557b999 SHA512 98d46b6dbafd95977a32a6479266f3b9fe6e6ed57e39182a3d031add60dabfdaa7494083109a75eaa3e4b15d0293b11081f9b06556eee1777ede40ed6c002a7f DIST haproxy-2.5.4.tar.gz 3819082 BLAKE2B fabc62ebaa968a11a49a6dd131198af31a49adbe73bcae82124ca752c2c90c1d77346621c9d804a10bca8ff254580aa7fbaca774f9df1a6a99ec112375d84a50 SHA512 95eb1ad9121a93cc77f0dd14e0080e18935cd45dc7dc511ab6dd0ecbdbb967bbde5eaa83f70157086796603560b979689f7d50b0cfba93d0245544c3a8c28a87 DIST haproxy-2.5.7.tar.gz 3832801 BLAKE2B 6d54135b56f84129dea497ddc935fecf593abccfb21fc647c7d166f9c1aa4abc670c66bf13e0923e353627d83d47345f632ae8212672c3b3da7a757fd5d24d7c SHA512 cf6994508d559401a84e1304c2b6829952a9b3a14365d03436da42ec7e4553c201ffde9e524044dfa48813e8e614d24095a87b0fae7d9145ce5e66b953666ee9 -DIST haproxy-2.6.1.tar.gz 3976025 BLAKE2B 0ddb100edce46b4d2ab80b6812f139657352464afab7187c7572e1c930230778fcb652f395c356f496b746d0aae17098604b1bc7f1db41b82522796f822e822c SHA512 003c74cb7acfd5da71b8b3cdc2d75820fd7c354c411d2703c60824bd4babfd4a209f87f5a94b1488a1fb4c575db1f694209072cc99821553407b6a8ba4d2d9e5 +DIST haproxy-2.6.2.tar.gz 3978933 BLAKE2B 8d080b175f574718fac6c58b9681a50d40d8ea4a562a05466668ee9ebe95c065aaa3eab33115c69cca356207f91927c2b949c0ec7d354fdad413ae91a41e60cd SHA512 8eef882145ce8da409d2fbd6fa5b7d383b9d52f8147ef697d61c512c07a8aa8029ae742b5682af5fe736c34398a5265ce9dc189e938f47395cf9e775471b5f55 EBUILD haproxy-2.2.17.ebuild 5356 BLAKE2B 3e66fd23b24ac10f251ca4c0b20b9fc7f51c55a7235ea362b22f71f9e581c36c93dcb4046cc14dcf687669eb64a71e221f7affd9e811cf94361e4e86754fb3bd SHA512 316ba774a164527afb0c56da9fe3433cc3c96becef081388b5756d819e0962d15a61d67388e9776ee194582a1e7dd97105ee58e194c94689047aad38b20509c1 EBUILD haproxy-2.2.21.ebuild 5358 BLAKE2B 74e840c6a726c6c00e26de01e8ed0e9923a7a7623a9984a67a5d2322fe7be38eb26559cce3fc1bcfadeb00246e42c0ed076a2b2662776f596e14a8f9ab1f5d12 SHA512 2049483a3f1eb1907573fcb134d9cfff2b27dc50a45df9025c3e734a1bde76d4cc7f5c0affdf52877889d267b32bb1fcc402dd1f8d9338004e9aac2aac879dd7 EBUILD haproxy-2.2.24.ebuild 5333 BLAKE2B 8814d4213f00ee1a095d88361e4ec82530f29e6b2c616cd5953dbfb2a1a5e286f83c5995e6344e0f49cd1a9b057cc31ab9b68034587ff716e09d97227f1eb4f2 SHA512 359a68d2054f4260d0b375d46e19ba391aee72e6cbe5e51e8c098916b42e229372830668bccf44935eea81f01848d76751df85a00f10de74df0a86785b624490 EBUILD haproxy-2.2.9999.ebuild 5333 BLAKE2B 8814d4213f00ee1a095d88361e4ec82530f29e6b2c616cd5953dbfb2a1a5e286f83c5995e6344e0f49cd1a9b057cc31ab9b68034587ff716e09d97227f1eb4f2 SHA512 359a68d2054f4260d0b375d46e19ba391aee72e6cbe5e51e8c098916b42e229372830668bccf44935eea81f01848d76751df85a00f10de74df0a86785b624490 EBUILD haproxy-2.4.14.ebuild 5603 BLAKE2B fe8ce7c4e262f9c7ec28b0409192a4165eaba2beb70eaea23affe3623eb0c977a6402dfca1bc70e48e09441a8918caed2632c63855963799eb8d9cb3b07dbf10 SHA512 2d10f3f0aebc2ca6d8cb0835a5b58a37d74b19850e80be1b819256a330bd1d14666fddcd8f0f80551cd426e015953f44d4cabcf95fccc8b95bae9b7d41f91a97 EBUILD haproxy-2.4.17.ebuild 5624 BLAKE2B 2bb250df90ffe2f545ae3767ba91fbcf435a1fe7403463d2a875454c2d0c871ebf7e1e5572af78f47d2767511fbb70e35c54be50b93073c6a649b985e8c9440d SHA512 262bebe786f159b771fc582cad856620c9b13fcf26204fcf19fb199753d7cd59de29a93e4d97e1a02be1f172ad41e113891fc7b96dd25416397ba8cdd86f47bb -EBUILD haproxy-2.4.9999.ebuild 5624 BLAKE2B 2bb250df90ffe2f545ae3767ba91fbcf435a1fe7403463d2a875454c2d0c871ebf7e1e5572af78f47d2767511fbb70e35c54be50b93073c6a649b985e8c9440d SHA512 262bebe786f159b771fc582cad856620c9b13fcf26204fcf19fb199753d7cd59de29a93e4d97e1a02be1f172ad41e113891fc7b96dd25416397ba8cdd86f47bb +EBUILD haproxy-2.4.9999.ebuild 5578 BLAKE2B 2cf102a86cfe405a0606a6dff4bdd1f386bf78430e42b79115ed9b2d8e5f5b3e6c613f8adbbfd0ea8b09f62086a310057c39bfaabd03848abaa229a1eed6778a SHA512 2b840e45636ce1ad922e4dc9be46e195f3bf566545fe2517f9dd3493d6e3a8eb882ef21edc124b1fd6c13192bbdf1ee24084bcf4d7e629d26e352394f0d60eab EBUILD haproxy-2.5.4.ebuild 5603 BLAKE2B fe8ce7c4e262f9c7ec28b0409192a4165eaba2beb70eaea23affe3623eb0c977a6402dfca1bc70e48e09441a8918caed2632c63855963799eb8d9cb3b07dbf10 SHA512 2d10f3f0aebc2ca6d8cb0835a5b58a37d74b19850e80be1b819256a330bd1d14666fddcd8f0f80551cd426e015953f44d4cabcf95fccc8b95bae9b7d41f91a97 EBUILD haproxy-2.5.7.ebuild 5571 BLAKE2B 4a356c40d93c8f3aa2c88cb37bbe541fa897ab0fe0b7bb88302288c7b988d68e08f71a74f63a007b4fe5e701ffd74b44afd40ee8f7574f1d56ddce2259ab858d SHA512 33371bd457ddbfbd4e63d36a08841a1567ecac63cbebbc318fda193b634899deb6471b1c17e235655bd6152138f8360d7ddf1751d578b6e736233d181dde40bd EBUILD haproxy-2.5.9999.ebuild 5571 BLAKE2B 4a356c40d93c8f3aa2c88cb37bbe541fa897ab0fe0b7bb88302288c7b988d68e08f71a74f63a007b4fe5e701ffd74b44afd40ee8f7574f1d56ddce2259ab858d SHA512 33371bd457ddbfbd4e63d36a08841a1567ecac63cbebbc318fda193b634899deb6471b1c17e235655bd6152138f8360d7ddf1751d578b6e736233d181dde40bd -EBUILD haproxy-2.6.1.ebuild 5616 BLAKE2B d40107699f1b1fa608bfb49db002b73185c36de1705ecd5289d31d63b3a803df3a704d93f5d5abfc2e4094e7e565687e09d5952941e80a19cf3286d09f8bc075 SHA512 7f66322eaef76800bd330a3762fd04267982cdd99aa515d657b55ff60b7c5851541e82c1f791d502f0ae70b13b45a2f496422071a015853066bb5deb949b00b8 -EBUILD haproxy-2.6.9999.ebuild 5616 BLAKE2B d40107699f1b1fa608bfb49db002b73185c36de1705ecd5289d31d63b3a803df3a704d93f5d5abfc2e4094e7e565687e09d5952941e80a19cf3286d09f8bc075 SHA512 7f66322eaef76800bd330a3762fd04267982cdd99aa515d657b55ff60b7c5851541e82c1f791d502f0ae70b13b45a2f496422071a015853066bb5deb949b00b8 -EBUILD haproxy-9999.ebuild 5616 BLAKE2B d40107699f1b1fa608bfb49db002b73185c36de1705ecd5289d31d63b3a803df3a704d93f5d5abfc2e4094e7e565687e09d5952941e80a19cf3286d09f8bc075 SHA512 7f66322eaef76800bd330a3762fd04267982cdd99aa515d657b55ff60b7c5851541e82c1f791d502f0ae70b13b45a2f496422071a015853066bb5deb949b00b8 +EBUILD haproxy-2.6.2.ebuild 5570 BLAKE2B a6f86bdfc03906cda6311dcf4e511a914526bfb02f3381d6b84d9b93370514e9b3c7afe996407a0344c745c4956b1b418db44e0c2b84b1f413c272bd3aa91994 SHA512 da2b1aa6336c609ecbc2d0e47d740df3ce5a0dc8b53398e997df970acc3cb970fe36277670dde4973d8cfcdd761a1536da9a43f0f2578a19767d8e048e09aa0c +EBUILD haproxy-2.6.9999.ebuild 5570 BLAKE2B a6f86bdfc03906cda6311dcf4e511a914526bfb02f3381d6b84d9b93370514e9b3c7afe996407a0344c745c4956b1b418db44e0c2b84b1f413c272bd3aa91994 SHA512 da2b1aa6336c609ecbc2d0e47d740df3ce5a0dc8b53398e997df970acc3cb970fe36277670dde4973d8cfcdd761a1536da9a43f0f2578a19767d8e048e09aa0c +EBUILD haproxy-9999.ebuild 5570 BLAKE2B a6f86bdfc03906cda6311dcf4e511a914526bfb02f3381d6b84d9b93370514e9b3c7afe996407a0344c745c4956b1b418db44e0c2b84b1f413c272bd3aa91994 SHA512 da2b1aa6336c609ecbc2d0e47d740df3ce5a0dc8b53398e997df970acc3cb970fe36277670dde4973d8cfcdd761a1536da9a43f0f2578a19767d8e048e09aa0c MISC metadata.xml 2063 BLAKE2B ddd51cff72847b617a457ac2baee4dd18a90a6a23e0982bc932ab8d3d101312dc2265884d38fcdc1a1cbb3d982b078e5b03a3c13fce07568d9d477688d210b09 SHA512 2198d3735f32f9c22787b1b43fd59bd6a0018ae25e104ee34ce0f27682ad8d6405a37c1c890b5eb41deabe5a5011d07d379e5df780bd8ab2877bd435bb875a1e diff --git a/net-proxy/haproxy/haproxy-2.4.9999.ebuild b/net-proxy/haproxy/haproxy-2.4.9999.ebuild index fe83c6a1fb10..a8f7f3e7ffd3 100644 --- a/net-proxy/haproxy/haproxy-2.4.9999.ebuild +++ b/net-proxy/haproxy/haproxy-2.4.9999.ebuild @@ -53,10 +53,6 @@ S="${WORKDIR}/${MY_P}" DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README ) EXTRAS=( admin/halog admin/iprange dev/tcploop dev/hpack ) -PATCHES=( - "${FILESDIR}"/${PN}-lua54.patch -) - haproxy_use() { (( $# != 2 )) && die "${FUNCNAME} " diff --git a/net-proxy/haproxy/haproxy-2.6.1.ebuild b/net-proxy/haproxy/haproxy-2.6.1.ebuild deleted file mode 100644 index dbf2cbf0aea1..000000000000 --- a/net-proxy/haproxy/haproxy-2.6.1.ebuild +++ /dev/null @@ -1,181 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" - -LUA_COMPAT=( lua5-4 lua5-3 ) - -[[ ${PV} == *9999 ]] && SCM="git-r3" -inherit toolchain-funcs flag-o-matic lua-single 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 ~arm64 ~ppc ~x86" -elif [[ ${PV} == 9999 ]]; then - EGIT_REPO_URI="https://git.haproxy.org/git/haproxy.git/" - EGIT_BRANCH=master -else - EGIT_REPO_URI="https://git.haproxy.org/git/haproxy-$(ver_cut 1-2).git/" - EGIT_BRANCH=master -fi - -LICENSE="GPL-2 LGPL-2.1" -SLOT="0/$(ver_cut 1-2)" -IUSE="+crypt doc examples +slz +net_ns +pcre pcre-jit prometheus-exporter -ssl systemd +threads tools vim-syntax zlib lua 51degrees wurfl" -REQUIRED_USE="pcre-jit? ( pcre ) - lua? ( ${LUA_REQUIRED_USE} ) - ?? ( slz zlib )" - -BDEPEND="virtual/pkgconfig" -DEPEND=" - crypt? ( virtual/libcrypt:= ) - pcre? ( - dev-libs/libpcre2:= - pcre-jit? ( dev-libs/libpcre2:=[jit] ) - ) - ssl? ( - dev-libs/openssl:0= - ) - systemd? ( sys-apps/systemd ) - zlib? ( sys-libs/zlib ) - lua? ( ${LUA_DEPS} )" -RDEPEND="${DEPEND} - acct-group/haproxy - acct-user/haproxy" - -S="${WORKDIR}/${MY_P}" - -DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README ) -EXTRAS=( admin/halog admin/iprange dev/tcploop dev/hpack ) - -PATCHES=( - "${FILESDIR}"/${PN}-lua54.patch -) - -haproxy_use() { - (( $# != 2 )) && die "${FUNCNAME} " - - usex "${1}" "USE_${2}=1" "USE_${2}=" -} - -pkg_setup() { - use lua && lua-single_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 - # Switching to PCRE2 by default, bug 838013 - PCRE= - PCRE_JIT= - ) - - # TODO: PCRE2_WIDTH? - args+=( $(haproxy_use threads THREAD) ) - args+=( $(haproxy_use crypt LIBCRYPT) ) - args+=( $(haproxy_use net_ns NS) ) - args+=( $(haproxy_use pcre PCRE2) ) - args+=( $(haproxy_use pcre-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 wurfl WURFL) ) - args+=( $(haproxy_use systemd SYSTEMD) ) - args+=( $(haproxy_use prometheus-exporter PROMEX) ) - - # Bug #668002 - if use ppc || use arm || use hppa; then - TARGET_LDFLAGS=-latomic - 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}" PCRE_LIB="${ESYSROOT}"/usr/$(get_libdir) ${args[@]} - emake -C admin/systemd CFLAGS="${CFLAGS} \$(SPEC_CFLAGS)" LDFLAGS="${LDFLAGS}" CC="$(tc-getCC)" EXTRA_OBJS="${EXTRA_OBJS}" TARGET_LDFLAGS="${TARGET_LDFLAGS}" PCRE_LIB="${ESYSROOT}"/usr/$(get_libdir) SBINDIR=/usr/sbin - - if use tools ; then - for extra in ${EXTRAS[@]} ; do - if [ "${extra}" = "admin/halog" ]; then - emake CFLAGS="${CFLAGS} \$(SPEC_CFLAGS)" LDFLAGS="${LDFLAGS}" CC="$(tc-getCC)" EXTRA_OBJS="${EXTRA_OBJS}" TARGET_LDFLAGS="${TARGET_LDFLAGS}" PCRE_LIB="${ESYSROOT}"/usr/$(get_libdir) ${args[@]} admin/halog/halog - elif [ "${extra}" = "dev/hpack" ]; then - emake CFLAGS="${CFLAGS} \$(SPEC_CFLAGS)" LDFLAGS="${LDFLAGS}" CC="$(tc-getCC)" EXTRA_OBJS="${EXTRA_OBJS}" TARGET_LDFLAGS="${TARGET_LDFLAGS}" PCRE_LIB="${ESYSROOT}"/usr/$(get_libdir) ${args[@]} dev/hpack/{decode,gen-enc,gen-rht} - else - # Those two includes are a workaround for hpack Makefile missing those - emake -C ${extra} \ - CFLAGS="${CFLAGS} -I../../include/ -I../../ebtree/" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC="$(tc-getCC)" ${args[@]} - fi - done - fi -} - -src_install() { - dosbin haproxy - dosym ../sbin/haproxy /usr/bin/haproxy - - newconfd "${FILESDIR}/${PN}.confd" ${PN} - newinitd "${FILESDIR}/${PN}.initd-r7" ${PN} - - doman doc/haproxy.1 - - systemd_dounit admin/systemd/haproxy.service - - einstalldocs - - # The errorfiles are used by upstream defaults. - insinto /etc/haproxy/errors/ - doins examples/errorfiles/* - - if use doc; then - dodoc doc/*.txt - #if use lua; then - # TODO: doc/lua-api/ - #fi - fi - - if use tools ; then - has admin/halog "${EXTRAS[@]}" && dobin admin/halog/halog - has admin/iprange "${EXTRAS[@]}" && { newbin admin/iprange/iprange haproxy_iprange; newbin admin/iprange/ip6range haproxy_ip6range; } - has dev/tcploop "${EXTRAS[@]}" && newbin dev/tcploop/tcploop haproxy_tcploop - has dev/hpack "${EXTRAS[@]}" && { - newbin dev/hpack/gen-rht haproxy_gen-rht - newbin dev/hpack/gen-enc haproxy_gen-enc - newbin dev/hpack/decode haproxy_decode - } - 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 admin/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.6.2.ebuild b/net-proxy/haproxy/haproxy-2.6.2.ebuild new file mode 100644 index 000000000000..5fc0953b5485 --- /dev/null +++ b/net-proxy/haproxy/haproxy-2.6.2.ebuild @@ -0,0 +1,177 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +LUA_COMPAT=( lua5-4 lua5-3 ) + +[[ ${PV} == *9999 ]] && SCM="git-r3" +inherit toolchain-funcs flag-o-matic lua-single 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 ~arm64 ~ppc ~x86" +elif [[ ${PV} == 9999 ]]; then + EGIT_REPO_URI="https://git.haproxy.org/git/haproxy.git/" + EGIT_BRANCH=master +else + EGIT_REPO_URI="https://git.haproxy.org/git/haproxy-$(ver_cut 1-2).git/" + EGIT_BRANCH=master +fi + +LICENSE="GPL-2 LGPL-2.1" +SLOT="0/$(ver_cut 1-2)" +IUSE="+crypt doc examples +slz +net_ns +pcre pcre-jit prometheus-exporter +ssl systemd +threads tools vim-syntax zlib lua 51degrees wurfl" +REQUIRED_USE="pcre-jit? ( pcre ) + lua? ( ${LUA_REQUIRED_USE} ) + ?? ( slz zlib )" + +BDEPEND="virtual/pkgconfig" +DEPEND=" + crypt? ( virtual/libcrypt:= ) + pcre? ( + dev-libs/libpcre2:= + pcre-jit? ( dev-libs/libpcre2:=[jit] ) + ) + ssl? ( + dev-libs/openssl:0= + ) + systemd? ( sys-apps/systemd ) + zlib? ( sys-libs/zlib ) + lua? ( ${LUA_DEPS} )" +RDEPEND="${DEPEND} + acct-group/haproxy + acct-user/haproxy" + +S="${WORKDIR}/${MY_P}" + +DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README ) +EXTRAS=( admin/halog admin/iprange dev/tcploop dev/hpack ) + +haproxy_use() { + (( $# != 2 )) && die "${FUNCNAME} " + + usex "${1}" "USE_${2}=1" "USE_${2}=" +} + +pkg_setup() { + use lua && lua-single_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 + # Switching to PCRE2 by default, bug 838013 + PCRE= + PCRE_JIT= + ) + + # TODO: PCRE2_WIDTH? + args+=( $(haproxy_use threads THREAD) ) + args+=( $(haproxy_use crypt LIBCRYPT) ) + args+=( $(haproxy_use net_ns NS) ) + args+=( $(haproxy_use pcre PCRE2) ) + args+=( $(haproxy_use pcre-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 wurfl WURFL) ) + args+=( $(haproxy_use systemd SYSTEMD) ) + args+=( $(haproxy_use prometheus-exporter PROMEX) ) + + # Bug #668002 + if use ppc || use arm || use hppa; then + TARGET_LDFLAGS=-latomic + 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}" PCRE_LIB="${ESYSROOT}"/usr/$(get_libdir) ${args[@]} + emake -C admin/systemd CFLAGS="${CFLAGS} \$(SPEC_CFLAGS)" LDFLAGS="${LDFLAGS}" CC="$(tc-getCC)" EXTRA_OBJS="${EXTRA_OBJS}" TARGET_LDFLAGS="${TARGET_LDFLAGS}" PCRE_LIB="${ESYSROOT}"/usr/$(get_libdir) SBINDIR=/usr/sbin + + if use tools ; then + for extra in ${EXTRAS[@]} ; do + if [ "${extra}" = "admin/halog" ]; then + emake CFLAGS="${CFLAGS} \$(SPEC_CFLAGS)" LDFLAGS="${LDFLAGS}" CC="$(tc-getCC)" EXTRA_OBJS="${EXTRA_OBJS}" TARGET_LDFLAGS="${TARGET_LDFLAGS}" PCRE_LIB="${ESYSROOT}"/usr/$(get_libdir) ${args[@]} admin/halog/halog + elif [ "${extra}" = "dev/hpack" ]; then + emake CFLAGS="${CFLAGS} \$(SPEC_CFLAGS)" LDFLAGS="${LDFLAGS}" CC="$(tc-getCC)" EXTRA_OBJS="${EXTRA_OBJS}" TARGET_LDFLAGS="${TARGET_LDFLAGS}" PCRE_LIB="${ESYSROOT}"/usr/$(get_libdir) ${args[@]} dev/hpack/{decode,gen-enc,gen-rht} + else + # Those two includes are a workaround for hpack Makefile missing those + emake -C ${extra} \ + CFLAGS="${CFLAGS} -I../../include/ -I../../ebtree/" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC="$(tc-getCC)" ${args[@]} + fi + done + fi +} + +src_install() { + dosbin haproxy + dosym ../sbin/haproxy /usr/bin/haproxy + + newconfd "${FILESDIR}/${PN}.confd" ${PN} + newinitd "${FILESDIR}/${PN}.initd-r7" ${PN} + + doman doc/haproxy.1 + + systemd_dounit admin/systemd/haproxy.service + + einstalldocs + + # The errorfiles are used by upstream defaults. + insinto /etc/haproxy/errors/ + doins examples/errorfiles/* + + if use doc; then + dodoc doc/*.txt + #if use lua; then + # TODO: doc/lua-api/ + #fi + fi + + if use tools ; then + has admin/halog "${EXTRAS[@]}" && dobin admin/halog/halog + has admin/iprange "${EXTRAS[@]}" && { newbin admin/iprange/iprange haproxy_iprange; newbin admin/iprange/ip6range haproxy_ip6range; } + has dev/tcploop "${EXTRAS[@]}" && newbin dev/tcploop/tcploop haproxy_tcploop + has dev/hpack "${EXTRAS[@]}" && { + newbin dev/hpack/gen-rht haproxy_gen-rht + newbin dev/hpack/gen-enc haproxy_gen-enc + newbin dev/hpack/decode haproxy_decode + } + 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 admin/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.6.9999.ebuild b/net-proxy/haproxy/haproxy-2.6.9999.ebuild index dbf2cbf0aea1..5fc0953b5485 100644 --- a/net-proxy/haproxy/haproxy-2.6.9999.ebuild +++ b/net-proxy/haproxy/haproxy-2.6.9999.ebuild @@ -53,10 +53,6 @@ S="${WORKDIR}/${MY_P}" DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README ) EXTRAS=( admin/halog admin/iprange dev/tcploop dev/hpack ) -PATCHES=( - "${FILESDIR}"/${PN}-lua54.patch -) - haproxy_use() { (( $# != 2 )) && die "${FUNCNAME} " diff --git a/net-proxy/haproxy/haproxy-9999.ebuild b/net-proxy/haproxy/haproxy-9999.ebuild index dbf2cbf0aea1..5fc0953b5485 100644 --- a/net-proxy/haproxy/haproxy-9999.ebuild +++ b/net-proxy/haproxy/haproxy-9999.ebuild @@ -53,10 +53,6 @@ S="${WORKDIR}/${MY_P}" DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README ) EXTRAS=( admin/halog admin/iprange dev/tcploop dev/hpack ) -PATCHES=( - "${FILESDIR}"/${PN}-lua54.patch -) - haproxy_use() { (( $# != 2 )) && die "${FUNCNAME} " -- cgit v1.2.3