* [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/, net-proxy/haproxy/files/
@ 2015-10-16 20:11 Christian Ruppert
0 siblings, 0 replies; 11+ messages in thread
From: Christian Ruppert @ 2015-10-16 20:11 UTC (permalink / raw
To: gentoo-commits
commit: baa4e242781638ae2d093ed51017b3b89a8c47e9
Author: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
AuthorDate: Fri Oct 16 20:09:47 2015 +0000
Commit: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
CommitDate: Fri Oct 16 20:10:20 2015 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=baa4e242
net-proxy/haproxy: Version bump to 1.6.0. Also fixes bug 555864
Package-Manager: portage-2.2.23
net-proxy/haproxy/Manifest | 1 +
net-proxy/haproxy/files/haproxy.confd | 14 +++
net-proxy/haproxy/files/haproxy.initd-r3 | 75 ++++++++++++++
net-proxy/haproxy/haproxy-1.6.0.ebuild | 161 +++++++++++++++++++++++++++++++
net-proxy/haproxy/metadata.xml | 1 +
5 files changed, 252 insertions(+)
diff --git a/net-proxy/haproxy/Manifest b/net-proxy/haproxy/Manifest
index 7f4d4fe..f2ed0d7 100644
--- a/net-proxy/haproxy/Manifest
+++ b/net-proxy/haproxy/Manifest
@@ -1,2 +1,3 @@
DIST haproxy-1.4.26.tar.gz 837280 SHA256 a8787dae723c045eebd0ed9e0213514f909a67325d64e963eaf50c35b147d3d3 SHA512 f21901069f651f3320c2b7cb6aee96fced5d4d5d4a73eec0d94dd8bd109a391d8da85026389e7209f85026cdefc1b879afcfd0a9bc0970e41aedd59e35935454 WHIRLPOOL 406b7f8bb4b9b3f6b8080f58431a804abea1d834ef9b8d86ede328b27e4f3fe944fbdae5bad8c3f7da75c81c92ff0e030950e09feac28eac4f763e511b5e7dce
DIST haproxy-1.5.14.tar.gz 1345345 SHA256 9565dd38649064d0350a2883fa81ccfe92eb17dcda457ebdc01535e1ab0c8f99 SHA512 83d6101fd402f37845ab3febc914335e4c6d9bdebbb0ff81c8e048d5252ffa5a1b77c4250a434fed5dd541ef1f1f2c47d969b59f7a51d6ab9aea38a8646a9798 WHIRLPOOL 7d2c580589b9b31e1eba169e4bf930ac42d2564e21eb1c25adbdd39b701abd221fd671ebc227167ab956a48b2c30eeb740a6394355a8fa748c408ee42fdff6fc
+DIST haproxy-1.6.0.tar.gz 1538022 SHA256 e83a272b7d3638cf1d37bba58d3e75f497c1862315ee5bb7f5efc1d98d26e25b SHA512 44bfcd040c87e0c3e7d925bb671009e8ed568a7a32ae32ac5d58921417aaa458b772a1368876fee8bf9252106fb315c1c3d29b7f03739a239567b86fb3c25e8e WHIRLPOOL 06afedc7dc7110e0985864f6d955261489997fd55644a16320203e47e14fc6f3bbb9020b772dfc571c01c76c7a55c8883a910f5b0553e70d4f321c1a14d97a2d
diff --git a/net-proxy/haproxy/files/haproxy.confd b/net-proxy/haproxy/files/haproxy.confd
new file mode 100644
index 0000000..5a989a7
--- /dev/null
+++ b/net-proxy/haproxy/files/haproxy.confd
@@ -0,0 +1,14 @@
+# HAProxy config file(s), space separated
+#CONFIGS="/etc/haproxy/haproxy.cfg"
+
+# Additional HAProxy command line options
+HAPROXY_OPTS=""
+
+# If you want to make use ot the new seamless reload you can just write your own
+# reload_seamless function here. It will be called by the init script.
+# For more information on how to use that feature please have a look at the
+# "seamless_reload.txt" documentation file (requires net-proxy/haproxy[examples])
+#reload_seamless() {
+# checkpath -d -m 0700 haproxy:haproxy "/var/run/haproxy/"
+# socat /var/run/haproxy/socket - <<< "show servers state" > /var/run/haproxy/global.state
+#}
diff --git a/net-proxy/haproxy/files/haproxy.initd-r3 b/net-proxy/haproxy/files/haproxy.initd-r3
new file mode 100644
index 0000000..4b3a0e6
--- /dev/null
+++ b/net-proxy/haproxy/files/haproxy.initd-r3
@@ -0,0 +1,75 @@
+#!/sbin/runscript
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+extra_commands="checkconfig"
+extra_started_commands="reload"
+
+command="/usr/bin/haproxy"
+
+pidfile="${HAPROXY_PIDFILE:-/var/run/${SVCNAME}.pid}"
+
+configs=
+
+if [ -z "${CONFIGS}" ]; then
+ if [ -f "/etc/haproxy/${SVCNAME}.cfg" ]; then
+ CONFIGS=/etc/haproxy/${SVCNAME}.cfg
+ elif [ -f "/etc/${SVCNAME}.cfg" ]; then
+ CONFIGS=/etc/${SVCNAME}.cfg # Deprecated
+ fi
+fi
+
+for conf in $CONFIGS; do
+ configs="${configs} -f ${conf}"
+done
+
+command_args="-D -p ${pidfile} ${configs} ${HAPROXY_OPTS}"
+
+depend() {
+ need net
+ use dns logger
+}
+
+checkconfig() {
+ if [ -z "${CONFIGS}" ]; then
+ eerror "No config(s) has been specified"
+ return 1
+ fi
+
+ for conf in $CONFIGS; do
+ if [ ! -f "${conf}" ]; then
+ eerror "${conf} does not exist!"
+ return 1
+ fi
+ done
+
+ ebegin "Checking ${CONFIGS}"
+ $command -q -c $configs $HAPROXY_OPTS
+ eend $?
+}
+
+start_pre() {
+ if [ "${RC_CMD}" != "restart" ]; then
+ checkconfig || return 1
+ fi
+}
+
+stop_pre() {
+ if [ "${RC_CMD}" = "restart" ]; then
+ checkconfig || return 1
+ fi
+}
+
+reload() {
+ checkconfig || { eerror "Reloading failed, please fix your config(s) first"; return 1; }
+
+ if [ "$(command -v reload_seamless)" = "reload_seamless" ]; then
+ einfo "Calling user-defined reload_seamless()"
+ reload_seamless || { eerror "reload_seamless() failed!"; return 1; }
+ fi
+
+ ebegin "Reloading ${SVCNAME}"
+ $command -D -p "${pidfile}" $configs $HAPROXY_OPTS -sf $(cat "${pidfile}")
+ eend $?
+}
diff --git a/net-proxy/haproxy/haproxy-1.6.0.ebuild b/net-proxy/haproxy/haproxy-1.6.0.ebuild
new file mode 100644
index 0000000..e9cd80d
--- /dev/null
+++ b/net-proxy/haproxy/haproxy-1.6.0.ebuild
@@ -0,0 +1,161 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+
+inherit user versionator toolchain-funcs flag-o-matic systemd linux-info
+
+MY_P="${PN}-${PV/_beta/-dev}"
+
+DESCRIPTION="A TCP/HTTP reverse proxy for high availability environments"
+HOMEPAGE="http://haproxy.1wt.eu"
+SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
+
+LICENSE="GPL-2 LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86"
+IUSE="+crypt doc examples net_ns +pcre pcre-jit ssl tools vim-syntax +zlib" # lua
+
+DEPEND="pcre? ( dev-libs/libpcre
+ pcre-jit? ( dev-libs/libpcre[jit] )
+ )
+ ssl? ( dev-libs/openssl:0[zlib?] )
+ zlib? ( sys-libs/zlib )"
+# lua? ( dev-lang/lua:5.3 )
+RDEPEND="${DEPEND}"
+
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+ enewgroup haproxy
+ enewuser haproxy -1 -1 -1 haproxy
+
+ if use net_ns; then
+ CONFIG_CHECK="~NET_NS"
+ linux-info_pkg_setup
+ fi
+}
+
+src_prepare() {
+ sed -e 's:@SBINDIR@:'/usr/bin':' contrib/systemd/haproxy.service.in \
+ > contrib/systemd/haproxy.service || die
+
+ sed -ie 's:/usr/sbin/haproxy:/usr/bin/haproxy:' src/haproxy-systemd-wrapper.c || die
+}
+
+src_compile() {
+ local args="TARGET=linux2628 USE_GETADDRINFO=1"
+
+ if use crypt ; then
+ args="${args} USE_LIBCRYPT=1"
+ else
+ args="${args} USE_LIBCRYPT="
+ fi
+
+# bug 541042
+# if use lua; then
+# args="${args} USE_LUA=1"
+# else
+ args="${args} USE_LUA="
+# fi
+
+ if use net_ns; then
+ args="${args} USE_NS=1"
+ else
+ args="${args} USE_NS="
+ fi
+
+ if use pcre ; then
+ args="${args} USE_PCRE=1"
+ if use pcre-jit; then
+ args="${args} USE_PCRE_JIT=1"
+ else
+ args="${args} USE_PCRE_JIT="
+ fi
+ else
+ args="${args} USE_PCRE= USE_PCRE_JIT="
+ fi
+
+# if use kernel_linux; then
+# args="${args} USE_LINUX_SPLICE=1 USE_LINUX_TPROXY=1"
+# else
+# args="${args} USE_LINUX_SPLICE= USE_LINUX_TPROXY="
+# fi
+
+ if use ssl ; then
+ args="${args} USE_OPENSSL=1"
+ else
+ args="${args} USE_OPENSSL="
+ fi
+
+ if use zlib ; then
+ args="${args} USE_ZLIB=1"
+ else
+ args="${args} USE_ZLIB="
+ fi
+
+ # For now, until the strict-aliasing breakage will be fixed
+ append-cflags -fno-strict-aliasing
+
+ emake CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args}
+
+ if use tools ; then
+ for contrib in halog iprange ; do
+ emake -C contrib/${contrib} \
+ CFLAGS="${CFLAGS}" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args}
+ done
+ fi
+}
+
+src_install() {
+ dobin haproxy
+
+ newconfd "${FILESDIR}/${PN}.confd" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r3" $PN
+
+ dodoc CHANGELOG CONTRIBUTING MAINTAINERS
+ doman doc/haproxy.1
+
+ dobin haproxy-systemd-wrapper
+ systemd_dounit contrib/systemd/haproxy.service
+
+ if use doc; then
+ dodoc ROADMAP doc/{close-options,configuration,cookie-options,intro,linux-syn-cookies,management,proxy-protocol}.txt
+ fi
+
+ if use tools ; then
+ for contrib in halog iprange ; do
+ dobin contrib/${contrib}/${contrib}
+ done
+ fi
+
+ if use net_ns && use doc; then
+ dodoc doc/network-namespaces.txt
+ 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 "${ROOT}/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 "${ROOT}/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 " ${ROOT}usr/share/doc/${PF}"
+ fi
+ fi
+}
diff --git a/net-proxy/haproxy/metadata.xml b/net-proxy/haproxy/metadata.xml
index 2691f32..40f681e 100644
--- a/net-proxy/haproxy/metadata.xml
+++ b/net-proxy/haproxy/metadata.xml
@@ -19,6 +19,7 @@ It can:
Its event-driven architecture allows it to easily handle thousands of simultaneous connections on hundreds of instances without risking the system's stability.
</longdescription>
<use>
+ <flag name="net_ns">Enable network namespace support (CONFIG_NET_NS)</flag>
<flag name="pcre-jit">Use JIT support for PCRE</flag>
<flag name="tools">Install additional tools (halog, iprange)</flag>
</use>
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/, net-proxy/haproxy/files/
@ 2016-10-15 14:52 Patrice Clement
0 siblings, 0 replies; 11+ messages in thread
From: Patrice Clement @ 2016-10-15 14:52 UTC (permalink / raw
To: gentoo-commits
commit: 2bfe6e3f45c9c3a26b44bdceaff67839504a19de
Author: Bertrand Jacquin <bertrand <AT> jacquin <DOT> bzh>
AuthorDate: Wed Oct 5 21:10:17 2016 +0000
Commit: Patrice Clement <monsieurp <AT> gentoo <DOT> org>
CommitDate: Sat Oct 15 14:52:33 2016 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2bfe6e3f
net-proxy/haproxy: major improvements.
* Move to /run.
* Remove commented USE_LINUX_SPLICE since declaration is implicit.
* Remove commented USE_LINUX_TPROXY since declaration is implicit.
* Keep lua for live ebuild.
Gentoo-Bug: https://bugs.gentoo.org/332633
Package-Manager: portage-2.3.0
Closes: https://github.com/gentoo/gentoo/pull/2486
Signed-off-by: Patrice Clement <monsieurp <AT> gentoo.org>
net-proxy/haproxy/files/haproxy.confd | 4 ++--
net-proxy/haproxy/files/haproxy.initd-r2 | 4 ++--
net-proxy/haproxy/files/haproxy.initd-r3 | 4 ++--
net-proxy/haproxy/haproxy-1.6.9.ebuild | 11 +----------
net-proxy/haproxy/haproxy-9999.ebuild | 4 ----
5 files changed, 7 insertions(+), 20 deletions(-)
diff --git a/net-proxy/haproxy/files/haproxy.confd b/net-proxy/haproxy/files/haproxy.confd
index 5a989a7..30739eb 100644
--- a/net-proxy/haproxy/files/haproxy.confd
+++ b/net-proxy/haproxy/files/haproxy.confd
@@ -9,6 +9,6 @@ HAPROXY_OPTS=""
# For more information on how to use that feature please have a look at the
# "seamless_reload.txt" documentation file (requires net-proxy/haproxy[examples])
#reload_seamless() {
-# checkpath -d -m 0700 haproxy:haproxy "/var/run/haproxy/"
-# socat /var/run/haproxy/socket - <<< "show servers state" > /var/run/haproxy/global.state
+# checkpath -d -m 0700 haproxy:haproxy "/run/haproxy/"
+# socat /run/haproxy/socket - <<< "show servers state" > /run/haproxy/global.state
#}
diff --git a/net-proxy/haproxy/files/haproxy.initd-r2 b/net-proxy/haproxy/files/haproxy.initd-r2
index 39a5bb4..15c5eb5 100644
--- a/net-proxy/haproxy/files/haproxy.initd-r2
+++ b/net-proxy/haproxy/files/haproxy.initd-r2
@@ -1,5 +1,5 @@
#!/sbin/openrc-run
-# Copyright 1999-2012 Gentoo Foundation
+# Copyright 1999-2016 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
@@ -7,7 +7,7 @@ extra_commands="checkconfig"
extra_started_commands="reload"
command="/usr/bin/haproxy"
-pidfile="/var/run/${SVCNAME}.pid"
+pidfile="/run/${SVCNAME}.pid"
if [ -z "${CONFFILE}" -a -d "/etc/haproxy" -a -f "/etc/haproxy/${SVCNAME}.cfg" ]; then
CONFFILE=/etc/haproxy/${SVCNAME}.cfg
diff --git a/net-proxy/haproxy/files/haproxy.initd-r3 b/net-proxy/haproxy/files/haproxy.initd-r3
index 92665cd..60ec31a 100644
--- a/net-proxy/haproxy/files/haproxy.initd-r3
+++ b/net-proxy/haproxy/files/haproxy.initd-r3
@@ -1,5 +1,5 @@
#!/sbin/openrc-run
-# Copyright 1999-2015 Gentoo Foundation
+# Copyright 1999-2016 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
@@ -8,7 +8,7 @@ extra_started_commands="reload"
command="/usr/bin/haproxy"
-pidfile="${HAPROXY_PIDFILE:-/var/run/${SVCNAME}.pid}"
+pidfile="${HAPROXY_PIDFILE:-/run/${SVCNAME}.pid}"
configs=
diff --git a/net-proxy/haproxy/haproxy-1.6.9.ebuild b/net-proxy/haproxy/haproxy-1.6.9.ebuild
index c9a98ed..8f3c3a0 100644
--- a/net-proxy/haproxy/haproxy-1.6.9.ebuild
+++ b/net-proxy/haproxy/haproxy-1.6.9.ebuild
@@ -15,7 +15,7 @@ SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/$
LICENSE="GPL-2 LGPL-2.1"
SLOT="0"
KEYWORDS="~amd64 ~arm ~ppc ~x86"
-IUSE="+crypt doc examples libressl slz net_ns +pcre pcre-jit ssl tools vim-syntax +zlib" # lua
+IUSE="+crypt doc examples libressl slz net_ns +pcre pcre-jit ssl tools vim-syntax +zlib"
REQUIRED_USE="pcre-jit? ( pcre )
?? ( slz zlib )"
@@ -30,7 +30,6 @@ DEPEND="
)
slz? ( dev-libs/libslz:= )
zlib? ( sys-libs/zlib )"
-# lua? ( dev-lang/lua:5.3 )
RDEPEND="${DEPEND}"
S="${WORKDIR}/${MY_P}"
@@ -69,17 +68,9 @@ src_compile() {
)
args+=( $(haproxy_use crypt LIBCRYPT) )
-
-# bug 541042
-# args+=( $(haproxy_use lua LUA) )
-
args+=( $(haproxy_use net_ns NS) )
args+=( $(haproxy_use pcre PCRE) )
args+=( $(haproxy_use pcre-jit PCRE_JIT) )
-
-# args+=( $(haproxy_use kernel_linux LINUX_SPLICE) )
-# args+=( $(haproxy_use kernel_linux LINUX_TPROXY) )
-
args+=( $(haproxy_use ssl OPENSSL) )
args+=( $(haproxy_use slz SLZ) )
args+=( $(haproxy_use zlib ZLIB) )
diff --git a/net-proxy/haproxy/haproxy-9999.ebuild b/net-proxy/haproxy/haproxy-9999.ebuild
index 4100bfa..97a58d9 100644
--- a/net-proxy/haproxy/haproxy-9999.ebuild
+++ b/net-proxy/haproxy/haproxy-9999.ebuild
@@ -76,10 +76,6 @@ src_compile() {
args+=( $(haproxy_use net_ns NS) )
args+=( $(haproxy_use pcre PCRE) )
args+=( $(haproxy_use pcre-jit PCRE_JIT) )
-
-# args+=( $(haproxy_use kernel_linux LINUX_SPLICE) )
-# args+=( $(haproxy_use kernel_linux LINUX_TPROXY) )
-
args+=( $(haproxy_use ssl OPENSSL) )
args+=( $(haproxy_use slz SLZ) )
args+=( $(haproxy_use zlib ZLIB) )
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/, net-proxy/haproxy/files/
@ 2016-12-05 15:56 Robin H. Johnson
0 siblings, 0 replies; 11+ messages in thread
From: Robin H. Johnson @ 2016-12-05 15:56 UTC (permalink / raw
To: gentoo-commits
commit: e9676800911f550b2dd174a5916bc4e555ad0159
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
AuthorDate: Mon Dec 5 00:53:39 2016 +0000
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
CommitDate: Mon Dec 5 15:56:22 2016 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e9676800
net-proxy/haproxy: 9999-style builds for current major versions.
Package-Manager: portage-2.3.2
net-proxy/haproxy/files/haproxy-1.7-contrib.patch | 42 ++++++++++++++++
net-proxy/haproxy/haproxy-1.6.9999.ebuild | 57 ++++++++++++++--------
...oxy-1.6.9999.ebuild => haproxy-1.7.9999.ebuild} | 57 ++++++++++++++--------
net-proxy/haproxy/metadata.xml | 3 ++
4 files changed, 121 insertions(+), 38 deletions(-)
diff --git a/net-proxy/haproxy/files/haproxy-1.7-contrib.patch b/net-proxy/haproxy/files/haproxy-1.7-contrib.patch
new file mode 100644
index 00000000..836c4cf
--- /dev/null
+++ b/net-proxy/haproxy/files/haproxy-1.7-contrib.patch
@@ -0,0 +1,42 @@
+diff -Nuar --exclude '*~' haproxy-1.7.9999.orig/contrib/tcploop/Makefile haproxy-1.7.9999/contrib/tcploop/Makefile
+--- haproxy-1.7.9999.orig/contrib/tcploop/Makefile 2016-12-04 16:08:05.497256646 -0800
++++ haproxy-1.7.9999/contrib/tcploop/Makefile 2016-12-04 16:12:20.558141392 -0800
+@@ -5,7 +5,7 @@
+ OBJS = tcploop
+
+ tcploop: tcploop.c
+- $(CC) $(OPTIMIZE) $(DEFINE) $(INCLUDE) -o $@ $^
++ $(CC) $(OPTIMIZE) $(DEFINE) $(INCLUDE) $(LDFLAGS) -o $@ $^ $(LIBS)
+
+ clean:
+ rm -f $(OBJS) *.[oas] *~
+diff -Nuar --exclude '*~' haproxy-1.7.9999.orig/contrib/tcploop/tcploop.c haproxy-1.7.9999/contrib/tcploop/tcploop.c
+--- haproxy-1.7.9999.orig/contrib/tcploop/tcploop.c 2016-12-04 16:08:05.498256665 -0800
++++ haproxy-1.7.9999/contrib/tcploop/tcploop.c 2016-12-04 16:11:13.877864378 -0800
+@@ -39,6 +39,7 @@
+ #include <ctype.h>
+ #include <errno.h>
+ #include <fcntl.h>
++#include <limits.h>
+ #include <netdb.h>
+ #include <poll.h>
+ #include <signal.h>
+diff -Nuar --exclude '*~' haproxy-1.7.9999.orig/contrib/spoa_example/Makefile haproxy-1.7.9999/contrib/spoa_example/Makefile
+--- haproxy-1.7.9999.orig/contrib/spoa_example/Makefile 2016-12-04 15:56:49.068302156 -0800
++++ haproxy-1.7.9999/contrib/spoa_example/Makefile 2016-12-04 15:58:51.360644213 -0800
+@@ -6,13 +6,13 @@
+ LD = $(CC)
+
+ CFLAGS = -g -O2 -Wall -Werror -pthread
+-LDFLAGS = -lpthread
++LIBS = -lpthread
+
+ OBJS = spoa.o
+
+
+ spoa: $(OBJS)
+- $(LD) $(LDFLAGS) -o $@ $^
++ $(LD) $(LDFLAGS) -o $@ $^ $(LIBS)
+
+ install: spoa
+ install spoa $(DESTDIR)$(BINDIR)
diff --git a/net-proxy/haproxy/haproxy-1.6.9999.ebuild b/net-proxy/haproxy/haproxy-1.6.9999.ebuild
index 97a58d9..df81d1e 100644
--- a/net-proxy/haproxy/haproxy-1.6.9999.ebuild
+++ b/net-proxy/haproxy/haproxy-1.6.9999.ebuild
@@ -4,18 +4,24 @@
EAPI="6"
-inherit user versionator toolchain-funcs flag-o-matic systemd linux-info git-r3
+[[ ${PV} == *9999 ]] && SCM="git-r3"
+inherit user versionator 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://haproxy.1wt.eu"
-EGIT_REPO_URI="http://master.formilux.org/git/people/willy/haproxy.git"
+if [[ ${PV} != *9999 ]]; then
+ SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
+ KEYWORDS="~amd64 ~arm ~ppc ~x86"
+else
+ EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 1-2).git/"
+ EGIT_BRANCH=master
+fi
LICENSE="GPL-2 LGPL-2.1"
SLOT="0"
-KEYWORDS=""
-IUSE="+crypt doc examples libressl slz net_ns +pcre pcre-jit ssl tools vim-syntax +zlib" # lua
+IUSE="+crypt doc examples libressl slz net_ns +pcre pcre-jit ssl tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
REQUIRED_USE="pcre-jit? ( pcre )
?? ( slz zlib )"
@@ -29,13 +35,18 @@ DEPEND="
libressl? ( dev-libs/libressl:0= )
)
slz? ( dev-libs/libslz:= )
- zlib? ( sys-libs/zlib )"
-# lua? ( dev-lang/lua:5.3 )
+ zlib? ( sys-libs/zlib )
+ lua? ( dev-lang/lua:5.3 )
+ device-atlas? ( dev-libs/device-atlas-api-c )"
RDEPEND="${DEPEND}"
S="${WORKDIR}/${MY_P}"
-DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS )
+DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
+version_is_at_least 1.7.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.7-contrib.patch )
+CONTRIBS=( halog iprange )
+# ip6range is present in 1.6, but broken.
+version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
haproxy_use() {
(( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
@@ -66,19 +77,20 @@ src_compile() {
local -a args=(
TARGET=linux2628
USE_GETADDRINFO=1
+ USE_TFO=1
)
args+=( $(haproxy_use crypt LIBCRYPT) )
-
-# bug 541042
-# args+=( $(haproxy_use lua LUA) )
-
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) )
# For now, until the strict-aliasing breakage will be fixed
append-cflags -fno-strict-aliasing
@@ -86,7 +98,7 @@ src_compile() {
emake CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
if use tools ; then
- for contrib in halog iprange ; do
+ for contrib in ${CONTRIBS[@]} ; do
emake -C contrib/${contrib} \
CFLAGS="${CFLAGS}" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
done
@@ -106,17 +118,24 @@ src_install() {
einstalldocs
+ # The errorfiles are used by upstream defaults.
+ insinto /etc/haproxy/errors/
+ doins examples/errorfiles/*
+
if use doc; then
- dodoc ROADMAP doc/{close-options,configuration,cookie-options,intro,linux-syn-cookies,management,proxy-protocol}.txt
+ dodoc ROADMAP doc/*.txt
+ #if use lua; then
+ # TODO: doc/lua-api/
+ #fi
fi
if use tools ; then
- dobin contrib/halog/halog
- newbin contrib/iprange/iprange haproxy_iprange
- fi
-
- if use net_ns && use doc; then
- dodoc doc/network-namespaces.txt
+ 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
fi
if use examples ; then
diff --git a/net-proxy/haproxy/haproxy-1.6.9999.ebuild b/net-proxy/haproxy/haproxy-1.7.9999.ebuild
similarity index 64%
copy from net-proxy/haproxy/haproxy-1.6.9999.ebuild
copy to net-proxy/haproxy/haproxy-1.7.9999.ebuild
index 97a58d9..df81d1e 100644
--- a/net-proxy/haproxy/haproxy-1.6.9999.ebuild
+++ b/net-proxy/haproxy/haproxy-1.7.9999.ebuild
@@ -4,18 +4,24 @@
EAPI="6"
-inherit user versionator toolchain-funcs flag-o-matic systemd linux-info git-r3
+[[ ${PV} == *9999 ]] && SCM="git-r3"
+inherit user versionator 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://haproxy.1wt.eu"
-EGIT_REPO_URI="http://master.formilux.org/git/people/willy/haproxy.git"
+if [[ ${PV} != *9999 ]]; then
+ SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
+ KEYWORDS="~amd64 ~arm ~ppc ~x86"
+else
+ EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 1-2).git/"
+ EGIT_BRANCH=master
+fi
LICENSE="GPL-2 LGPL-2.1"
SLOT="0"
-KEYWORDS=""
-IUSE="+crypt doc examples libressl slz net_ns +pcre pcre-jit ssl tools vim-syntax +zlib" # lua
+IUSE="+crypt doc examples libressl slz net_ns +pcre pcre-jit ssl tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
REQUIRED_USE="pcre-jit? ( pcre )
?? ( slz zlib )"
@@ -29,13 +35,18 @@ DEPEND="
libressl? ( dev-libs/libressl:0= )
)
slz? ( dev-libs/libslz:= )
- zlib? ( sys-libs/zlib )"
-# lua? ( dev-lang/lua:5.3 )
+ zlib? ( sys-libs/zlib )
+ lua? ( dev-lang/lua:5.3 )
+ device-atlas? ( dev-libs/device-atlas-api-c )"
RDEPEND="${DEPEND}"
S="${WORKDIR}/${MY_P}"
-DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS )
+DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
+version_is_at_least 1.7.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.7-contrib.patch )
+CONTRIBS=( halog iprange )
+# ip6range is present in 1.6, but broken.
+version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
haproxy_use() {
(( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
@@ -66,19 +77,20 @@ src_compile() {
local -a args=(
TARGET=linux2628
USE_GETADDRINFO=1
+ USE_TFO=1
)
args+=( $(haproxy_use crypt LIBCRYPT) )
-
-# bug 541042
-# args+=( $(haproxy_use lua LUA) )
-
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) )
# For now, until the strict-aliasing breakage will be fixed
append-cflags -fno-strict-aliasing
@@ -86,7 +98,7 @@ src_compile() {
emake CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
if use tools ; then
- for contrib in halog iprange ; do
+ for contrib in ${CONTRIBS[@]} ; do
emake -C contrib/${contrib} \
CFLAGS="${CFLAGS}" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
done
@@ -106,17 +118,24 @@ src_install() {
einstalldocs
+ # The errorfiles are used by upstream defaults.
+ insinto /etc/haproxy/errors/
+ doins examples/errorfiles/*
+
if use doc; then
- dodoc ROADMAP doc/{close-options,configuration,cookie-options,intro,linux-syn-cookies,management,proxy-protocol}.txt
+ dodoc ROADMAP doc/*.txt
+ #if use lua; then
+ # TODO: doc/lua-api/
+ #fi
fi
if use tools ; then
- dobin contrib/halog/halog
- newbin contrib/iprange/iprange haproxy_iprange
- fi
-
- if use net_ns && use doc; then
- dodoc doc/network-namespaces.txt
+ 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
fi
if use examples ; then
diff --git a/net-proxy/haproxy/metadata.xml b/net-proxy/haproxy/metadata.xml
index 2aaccf1..fe6d5f4 100644
--- a/net-proxy/haproxy/metadata.xml
+++ b/net-proxy/haproxy/metadata.xml
@@ -23,5 +23,8 @@ Its event-driven architecture allows it to easily handle thousands of simultaneo
<flag name="pcre-jit">Use JIT support for PCRE</flag>
<flag name="slz">Use <pkg>dev-libs/libslz</pkg> compression library</flag>
<flag name="tools">Install additional tools (halog, iprange)</flag>
+ <flag name="device-atlas">Device Detection using Device Atlas</flag>
+ <flag name="51degrees">Device Detection using 51 Degrees</flag>
+ <flag name="wurfl">Device Detection using WURFL</flag>
</use>
</pkgmetadata>
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/, net-proxy/haproxy/files/
@ 2017-06-21 18:22 Patrick Lauer
0 siblings, 0 replies; 11+ messages in thread
From: Patrick Lauer @ 2017-06-21 18:22 UTC (permalink / raw
To: gentoo-commits
commit: 0bf76b7ba9fdcae0455599ddb348b1e79b65b413
Author: Patrick Lauer <patrick <AT> gentoo <DOT> org>
AuthorDate: Wed Jun 21 18:19:57 2017 +0000
Commit: Patrick Lauer <patrick <AT> gentoo <DOT> org>
CommitDate: Wed Jun 21 18:21:17 2017 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0bf76b7b
net-proxy/haproxy: Fix init script (openrc_default_stop -> default_stop) #620418
Package-Manager: Portage-2.3.6, Repoman-2.3.2
RepoMan-Options: --force
.../files/{haproxy.initd-r3 => haproxy.initd-r4} | 4 +-
...roxy-1.6.11.ebuild => haproxy-1.6.11-r1.ebuild} | 2 +-
...roxy-1.6.12.ebuild => haproxy-1.6.12-r1.ebuild} | 2 +-
...roxy-1.6.13.ebuild => haproxy-1.6.13-r1.ebuild} | 2 +-
...oxy-1.7.6.ebuild => haproxy-1.6.9999-r1.ebuild} | 2 +-
net-proxy/haproxy/haproxy-1.6.9999.ebuild | 165 ---------------------
...aproxy-1.7.5.ebuild => haproxy-1.7.5-r1.ebuild} | 2 +-
...aproxy-1.7.6.ebuild => haproxy-1.7.6-r1.ebuild} | 2 +-
...oxy-1.7.6.ebuild => haproxy-1.7.9999-r1.ebuild} | 2 +-
net-proxy/haproxy/haproxy-1.7.9999.ebuild | 165 ---------------------
10 files changed, 9 insertions(+), 339 deletions(-)
diff --git a/net-proxy/haproxy/files/haproxy.initd-r3 b/net-proxy/haproxy/files/haproxy.initd-r4
similarity index 95%
rename from net-proxy/haproxy/files/haproxy.initd-r3
rename to net-proxy/haproxy/files/haproxy.initd-r4
index abba9f86534..c37719b1675 100644
--- a/net-proxy/haproxy/files/haproxy.initd-r3
+++ b/net-proxy/haproxy/files/haproxy.initd-r4
@@ -1,5 +1,5 @@
#!/sbin/openrc-run
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
extra_commands="checkconfig"
@@ -66,7 +66,7 @@ stop() {
_t="$(mktemp)"
for _pid in $(cat ${pidfile}) ; do
echo "${_pid}" > "${_t}"
- pidfile="${_t}" openrc_default_stop
+ pidfile="${_t}" default_stop
done
rm -f "${_t}"
}
diff --git a/net-proxy/haproxy/haproxy-1.6.11.ebuild b/net-proxy/haproxy/haproxy-1.6.11-r1.ebuild
similarity index 99%
rename from net-proxy/haproxy/haproxy-1.6.11.ebuild
rename to net-proxy/haproxy/haproxy-1.6.11-r1.ebuild
index 39b23851f90..06254314e42 100644
--- a/net-proxy/haproxy/haproxy-1.6.11.ebuild
+++ b/net-proxy/haproxy/haproxy-1.6.11-r1.ebuild
@@ -108,7 +108,7 @@ src_install() {
dobin haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r3" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r4" $PN
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-1.6.12.ebuild b/net-proxy/haproxy/haproxy-1.6.12-r1.ebuild
similarity index 99%
rename from net-proxy/haproxy/haproxy-1.6.12.ebuild
rename to net-proxy/haproxy/haproxy-1.6.12-r1.ebuild
index e1c758115e5..11493f63057 100644
--- a/net-proxy/haproxy/haproxy-1.6.12.ebuild
+++ b/net-proxy/haproxy/haproxy-1.6.12-r1.ebuild
@@ -108,7 +108,7 @@ src_install() {
dobin haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r3" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r4" $PN
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-1.6.13.ebuild b/net-proxy/haproxy/haproxy-1.6.13-r1.ebuild
similarity index 99%
rename from net-proxy/haproxy/haproxy-1.6.13.ebuild
rename to net-proxy/haproxy/haproxy-1.6.13-r1.ebuild
index e1c758115e5..11493f63057 100644
--- a/net-proxy/haproxy/haproxy-1.6.13.ebuild
+++ b/net-proxy/haproxy/haproxy-1.6.13-r1.ebuild
@@ -108,7 +108,7 @@ src_install() {
dobin haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r3" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r4" $PN
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-1.7.6.ebuild b/net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild
similarity index 99%
copy from net-proxy/haproxy/haproxy-1.7.6.ebuild
copy to net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild
index c0a7cc341e6..dc6dcf334d8 100644
--- a/net-proxy/haproxy/haproxy-1.7.6.ebuild
+++ b/net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild
@@ -109,7 +109,7 @@ src_install() {
dobin haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r3" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r4" $PN
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-1.6.9999.ebuild b/net-proxy/haproxy/haproxy-1.6.9999.ebuild
deleted file mode 100644
index 713e9e895bd..00000000000
--- a/net-proxy/haproxy/haproxy-1.6.9999.ebuild
+++ /dev/null
@@ -1,165 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="6"
-
-[[ ${PV} == *9999 ]] && SCM="git-r3"
-inherit user versionator 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://haproxy.1wt.eu"
-if [[ ${PV} != *9999 ]]; then
- SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
- KEYWORDS="~amd64 ~arm ~ppc ~x86"
-else
- EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 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 ssl tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
-REQUIRED_USE="pcre-jit? ( pcre )
- device-atlas? ( pcre )
- ?? ( slz zlib )"
-
-DEPEND="
- pcre? (
- dev-libs/libpcre
- pcre-jit? ( dev-libs/libpcre[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}"
-
-S="${WORKDIR}/${MY_P}"
-
-DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
-version_is_at_least 1.7.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.7-contrib.patch )
-CONTRIBS=( halog iprange )
-# ip6range is present in 1.6, but broken.
-version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
-
-haproxy_use() {
- (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
-
- usex "${1}" "USE_${2}=1" "USE_${2}="
-}
-
-pkg_setup() {
- enewgroup haproxy
- enewuser haproxy -1 -1 -1 haproxy
-
- if use net_ns; then
- CONFIG_CHECK="~NET_NS"
- linux-info_pkg_setup
- fi
-}
-
-src_prepare() {
- default
-
- sed -e 's:@SBINDIR@:'/usr/bin':' contrib/systemd/haproxy.service.in \
- > contrib/systemd/haproxy.service || die
-
- sed -ie 's:/usr/sbin/haproxy:/usr/bin/haproxy:' src/haproxy-systemd-wrapper.c || die
-}
-
-src_compile() {
- local -a args=(
- TARGET=linux2628
- USE_GETADDRINFO=1
- USE_TFO=1
- )
-
- 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) )
-
- # For now, until the strict-aliasing breakage will be fixed
- append-cflags -fno-strict-aliasing
-
- emake CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
-
- 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() {
- dobin haproxy
-
- newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r3" $PN
-
- doman doc/haproxy.1
-
- dobin haproxy-systemd-wrapper
- 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
- 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-1.7.5.ebuild b/net-proxy/haproxy/haproxy-1.7.5-r1.ebuild
similarity index 99%
rename from net-proxy/haproxy/haproxy-1.7.5.ebuild
rename to net-proxy/haproxy/haproxy-1.7.5-r1.ebuild
index c0a7cc341e6..dc6dcf334d8 100644
--- a/net-proxy/haproxy/haproxy-1.7.5.ebuild
+++ b/net-proxy/haproxy/haproxy-1.7.5-r1.ebuild
@@ -109,7 +109,7 @@ src_install() {
dobin haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r3" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r4" $PN
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-1.7.6.ebuild b/net-proxy/haproxy/haproxy-1.7.6-r1.ebuild
similarity index 99%
copy from net-proxy/haproxy/haproxy-1.7.6.ebuild
copy to net-proxy/haproxy/haproxy-1.7.6-r1.ebuild
index c0a7cc341e6..dc6dcf334d8 100644
--- a/net-proxy/haproxy/haproxy-1.7.6.ebuild
+++ b/net-proxy/haproxy/haproxy-1.7.6-r1.ebuild
@@ -109,7 +109,7 @@ src_install() {
dobin haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r3" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r4" $PN
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-1.7.6.ebuild b/net-proxy/haproxy/haproxy-1.7.9999-r1.ebuild
similarity index 99%
rename from net-proxy/haproxy/haproxy-1.7.6.ebuild
rename to net-proxy/haproxy/haproxy-1.7.9999-r1.ebuild
index c0a7cc341e6..dc6dcf334d8 100644
--- a/net-proxy/haproxy/haproxy-1.7.6.ebuild
+++ b/net-proxy/haproxy/haproxy-1.7.9999-r1.ebuild
@@ -109,7 +109,7 @@ src_install() {
dobin haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r3" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r4" $PN
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-1.7.9999.ebuild b/net-proxy/haproxy/haproxy-1.7.9999.ebuild
deleted file mode 100644
index 713e9e895bd..00000000000
--- a/net-proxy/haproxy/haproxy-1.7.9999.ebuild
+++ /dev/null
@@ -1,165 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="6"
-
-[[ ${PV} == *9999 ]] && SCM="git-r3"
-inherit user versionator 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://haproxy.1wt.eu"
-if [[ ${PV} != *9999 ]]; then
- SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
- KEYWORDS="~amd64 ~arm ~ppc ~x86"
-else
- EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 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 ssl tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
-REQUIRED_USE="pcre-jit? ( pcre )
- device-atlas? ( pcre )
- ?? ( slz zlib )"
-
-DEPEND="
- pcre? (
- dev-libs/libpcre
- pcre-jit? ( dev-libs/libpcre[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}"
-
-S="${WORKDIR}/${MY_P}"
-
-DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
-version_is_at_least 1.7.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.7-contrib.patch )
-CONTRIBS=( halog iprange )
-# ip6range is present in 1.6, but broken.
-version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
-
-haproxy_use() {
- (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
-
- usex "${1}" "USE_${2}=1" "USE_${2}="
-}
-
-pkg_setup() {
- enewgroup haproxy
- enewuser haproxy -1 -1 -1 haproxy
-
- if use net_ns; then
- CONFIG_CHECK="~NET_NS"
- linux-info_pkg_setup
- fi
-}
-
-src_prepare() {
- default
-
- sed -e 's:@SBINDIR@:'/usr/bin':' contrib/systemd/haproxy.service.in \
- > contrib/systemd/haproxy.service || die
-
- sed -ie 's:/usr/sbin/haproxy:/usr/bin/haproxy:' src/haproxy-systemd-wrapper.c || die
-}
-
-src_compile() {
- local -a args=(
- TARGET=linux2628
- USE_GETADDRINFO=1
- USE_TFO=1
- )
-
- 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) )
-
- # For now, until the strict-aliasing breakage will be fixed
- append-cflags -fno-strict-aliasing
-
- emake CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
-
- 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() {
- dobin haproxy
-
- newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r3" $PN
-
- doman doc/haproxy.1
-
- dobin haproxy-systemd-wrapper
- 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
- 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
-}
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/, net-proxy/haproxy/files/
@ 2017-07-04 22:22 Robin H. Johnson
0 siblings, 0 replies; 11+ messages in thread
From: Robin H. Johnson @ 2017-07-04 22:22 UTC (permalink / raw
To: gentoo-commits
commit: 6b2cb49fea06e38d1437e96f7d8a12e8fd6711e1
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
AuthorDate: Tue Jul 4 22:20:55 2017 +0000
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
CommitDate: Tue Jul 4 22:22:25 2017 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6b2cb49f
net-proxy/haproxy: bump & file moves.
- Add 1.7.7 release.
- move haproxy & haproxy-systemd-wrapper binaries to sbin to match
upstream & other distros, place symlinks in old location.
Package-Manager: portage-2.3.6
Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org>
net-proxy/haproxy/Manifest | 1 +
net-proxy/haproxy/files/haproxy.initd-r5 | 85 +++++++++++++
net-proxy/haproxy/haproxy-1.5.19-r1.ebuild | 135 +++++++++++++++++++++
...1.6.9999-r1.ebuild => haproxy-1.6.13-r2.ebuild} | 19 +--
net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild | 18 +--
...oxy-1.6.9999-r1.ebuild => haproxy-1.7.7.ebuild} | 18 +--
net-proxy/haproxy/haproxy-1.7.9999-r1.ebuild | 18 +--
7 files changed, 245 insertions(+), 49 deletions(-)
diff --git a/net-proxy/haproxy/Manifest b/net-proxy/haproxy/Manifest
index 84a3b66e25f..d529fb21be3 100644
--- a/net-proxy/haproxy/Manifest
+++ b/net-proxy/haproxy/Manifest
@@ -5,3 +5,4 @@ DIST haproxy-1.6.12.tar.gz 1580114 SHA256 9bdf2bf855991dc4e0bf9b1ba2b1a322fc23f1
DIST haproxy-1.6.13.tar.gz 1580214 SHA256 7d318583f3a1bf185e857bd40449004b29c95547c89bbb36718f284e29502a1b SHA512 ffed3b347e0cd9cefdc379c91890a3c104d6848b976a9f28984878a9c2d05ca7ddea678f7a93f75cb9d29ae2be921e5a5bd295b1a8771765b099d1c619ded7a3 WHIRLPOOL 70176ee090dacbbdc822c74bba137589f168482c560734c06b98dc23b4d957ed1e016309f11f25a0b486bc6917633455f1174dc6688d6aef53667c61b83a9ff3
DIST haproxy-1.7.5.tar.gz 1743979 SHA256 b04d7db6383c662eb0a421a95af7becac6d9744a1abf0df6b0280c1e61416121 SHA512 9fc62b492b4eb80039511339d6e677107f4ba842f275d4be216a70a0d3d0463c819e10e365a7e9fe2e95e0b446b00350b4ee161e98bd724ca2e0e4e60bea5734 WHIRLPOOL be176d9f237dcb36edaf223b86f3dc9baa964b4bffcba2af1aa267bbcaf2dee00b110c3dc70abc8aa96e37f55a9c99f29f416d9ecce3a62a712769647515b3ae
DIST haproxy-1.7.6.tar.gz 1744267 SHA256 88f84beba34d08a5495d908ca76866e033e6046e7c74f9477b9d5316f8c3d32a SHA512 89de0ba58f98419dd86befede9cb1d30adcbcc6671605d9c41871f0dec5ef89392258781ab41451582f179f8b2fec586bfe5d0694f8e11c3a25cb3d313613737 WHIRLPOOL 100c9d402be3ccf695dabf1fa6aa6d8ef79b8275076acbfd36252d9a7cfa3eeccce9d67fc4730923ec5e647cb99065a982a0541578fd84f0926bd104b381b5fd
+DIST haproxy-1.7.7.tar.gz 1745024 SHA256 81196ca449e4ada45fbd743fe3804bb82c25563ff9653e136872181ee5603ae2 SHA512 aa4720962e94b00c2b6090f62fb875e8977783256d877eb799b6a48c884833bac00b12d04fabd440011007e2af1914e0d67ab485026a447d8a61d58128d04a5a WHIRLPOOL d730dd21f1d8c2132297011e3dfbbbc12b6aa2cc61b67ee1cb9001b9f320e1e403ba917b81c8159fc7e2b43a0e3c95fd27172e1c86aada4963d3a4ecaebb3e2e
diff --git a/net-proxy/haproxy/files/haproxy.initd-r5 b/net-proxy/haproxy/files/haproxy.initd-r5
new file mode 100644
index 00000000000..0f2435f7433
--- /dev/null
+++ b/net-proxy/haproxy/files/haproxy.initd-r5
@@ -0,0 +1,85 @@
+#!/sbin/openrc-run
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+extra_commands="checkconfig"
+extra_started_commands="reload"
+
+command="/usr/sbin/haproxy"
+
+pidfile="${HAPROXY_PIDFILE:-/run/${SVCNAME}.pid}"
+
+configs=
+
+if [ -z "${CONFIGS}" ]; then
+ if [ -f "/etc/haproxy/${SVCNAME}.cfg" ]; then
+ CONFIGS=/etc/haproxy/${SVCNAME}.cfg
+ elif [ -f "/etc/${SVCNAME}.cfg" ]; then
+ CONFIGS=/etc/${SVCNAME}.cfg # Deprecated
+ fi
+fi
+
+for conf in $CONFIGS; do
+ configs="${configs} -f ${conf}"
+done
+
+command_args="-D -p ${pidfile} ${configs} ${HAPROXY_OPTS}"
+
+depend() {
+ need net
+ use dns logger
+}
+
+checkconfig() {
+ if [ -z "${CONFIGS}" ]; then
+ eerror "No config(s) has been specified"
+ return 1
+ fi
+
+ for conf in $CONFIGS; do
+ if [ ! -f "${conf}" ]; then
+ eerror "${conf} does not exist!"
+ return 1
+ fi
+ done
+
+ ebegin "Checking ${CONFIGS}"
+ $command -q -c $configs $HAPROXY_OPTS
+ eend $?
+}
+
+start_pre() {
+ if [ "${RC_CMD}" != "restart" ]; then
+ checkconfig || return 1
+ fi
+}
+
+stop_pre() {
+ if [ "${RC_CMD}" = "restart" ]; then
+ checkconfig || return 1
+ fi
+}
+
+stop() {
+ local _t _pid
+
+ _t="$(mktemp)"
+ for _pid in $(cat ${pidfile}) ; do
+ echo "${_pid}" > "${_t}"
+ pidfile="${_t}" default_stop
+ done
+ rm -f "${_t}"
+}
+
+reload() {
+ checkconfig || { eerror "Reloading failed, please fix your config(s) first"; return 1; }
+
+ if [ "$(command -v reload_seamless)" = "reload_seamless" ]; then
+ einfo "Calling user-defined reload_seamless()"
+ reload_seamless || { eerror "reload_seamless() failed!"; return 1; }
+ fi
+
+ ebegin "Reloading ${SVCNAME}"
+ $command -D -p "${pidfile}" $configs $HAPROXY_OPTS -sf $(cat "${pidfile}")
+ eend $?
+}
diff --git a/net-proxy/haproxy/haproxy-1.5.19-r1.ebuild b/net-proxy/haproxy/haproxy-1.5.19-r1.ebuild
new file mode 100644
index 00000000000..2b0bc8af0a4
--- /dev/null
+++ b/net-proxy/haproxy/haproxy-1.5.19-r1.ebuild
@@ -0,0 +1,135 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="5"
+
+inherit user versionator toolchain-funcs flag-o-matic systemd
+
+MY_P="${PN}-${PV/_beta/-dev}"
+
+DESCRIPTION="A TCP/HTTP reverse proxy for high availability environments"
+HOMEPAGE="http://haproxy.1wt.eu"
+SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
+
+LICENSE="GPL-2 LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~ppc ~x86"
+IUSE="+crypt examples libressl +pcre pcre-jit ssl tools vim-syntax +zlib"
+
+DEPEND="
+ pcre? (
+ dev-libs/libpcre
+ pcre-jit? ( dev-libs/libpcre[jit] )
+ )
+ ssl? (
+ !libressl? ( dev-libs/openssl:0=[zlib?] )
+ libressl? ( dev-libs/libressl:0= )
+ )
+ zlib? ( sys-libs/zlib )"
+RDEPEND="${DEPEND}"
+
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+ enewgroup haproxy
+ enewuser haproxy -1 -1 -1 haproxy
+}
+
+src_compile() {
+ local args="TARGET=linux2628 USE_GETADDRINFO=1"
+
+ if use pcre ; then
+ args="${args} USE_PCRE=1"
+ if use pcre-jit; then
+ args="${args} USE_PCRE_JIT=1"
+ else
+ args="${args} USE_PCRE_JIT="
+ fi
+ else
+ args="${args} USE_PCRE= USE_PCRE_JIT="
+ fi
+
+# if use kernel_linux; then
+# args="${args} USE_LINUX_SPLICE=1 USE_LINUX_TPROXY=1"
+# else
+# args="${args} USE_LINUX_SPLICE= USE_LINUX_TPROXY="
+# fi
+
+ if use crypt ; then
+ args="${args} USE_LIBCRYPT=1"
+ else
+ args="${args} USE_LIBCRYPT="
+ fi
+
+ if use ssl ; then
+ args="${args} USE_OPENSSL=1"
+ else
+ args="${args} USE_OPENSSL="
+ fi
+
+ if use zlib ; then
+ args="${args} USE_ZLIB=1"
+ else
+ args="${args} USE_ZLIB="
+ fi
+
+ # 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 halog iprange ; do
+ emake -C contrib/${contrib} \
+ CFLAGS="${CFLAGS}" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args}
+ done
+ fi
+}
+
+src_install() {
+ dosbin haproxy
+ dosym /usr/sbin/haproxy /usr/bin/haproxy
+
+ newinitd "${FILESDIR}/haproxy.initd-r5" haproxy
+
+ # Don't install useless files
+# rm examples/build.cfg doc/*gpl.txt
+
+ dodoc CHANGELOG ROADMAP doc/{configuration,haproxy-en}.txt
+ doman doc/haproxy.1
+
+ dosbin haproxy-systemd-wrapper
+ dosym /usr/sbin/haproxy-systemd-wrapper /usr/bin/haproxy-systemd-wrapper
+ systemd_dounit contrib/systemd/haproxy.service
+
+ if use tools ; then
+ for contrib in halog iprange ; do
+ dobin contrib/${contrib}/${contrib}
+ done
+ fi
+
+ if use examples ; then
+ docinto examples
+ dodoc examples/*.cfg
+ fi
+
+ if use vim-syntax ; then
+ insinto /usr/share/vim/vimfiles/syntax
+ doins examples/haproxy.vim
+ fi
+}
+
+pkg_postinst() {
+ if [[ ! -f "${ROOT}/etc/haproxy.cfg" ]] ; then
+ ewarn "You need to create /etc/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 "${ROOT}/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 " ${ROOT}usr/share/doc/${PF}"
+ fi
+ fi
+}
diff --git a/net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild b/net-proxy/haproxy/haproxy-1.6.13-r2.ebuild
similarity index 92%
copy from net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild
copy to net-proxy/haproxy/haproxy-1.6.13-r2.ebuild
index dc6dcf334d8..5d3f45d2f51 100644
--- a/net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild
+++ b/net-proxy/haproxy/haproxy-1.6.13-r2.ebuild
@@ -22,7 +22,6 @@ LICENSE="GPL-2 LGPL-2.1"
SLOT="0"
IUSE="+crypt doc examples libressl slz net_ns +pcre pcre-jit ssl tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
REQUIRED_USE="pcre-jit? ( pcre )
- device-atlas? ( pcre )
?? ( slz zlib )"
DEPEND="
@@ -64,15 +63,6 @@ pkg_setup() {
fi
}
-src_prepare() {
- default
-
- sed -e 's:@SBINDIR@:'/usr/bin':' contrib/systemd/haproxy.service.in \
- > contrib/systemd/haproxy.service || die
-
- sed -ie 's:/usr/sbin/haproxy:/usr/bin/haproxy:' src/haproxy-systemd-wrapper.c || die
-}
-
src_compile() {
local -a args=(
TARGET=linux2628
@@ -96,6 +86,7 @@ src_compile() {
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
@@ -106,14 +97,16 @@ src_compile() {
}
src_install() {
- dobin haproxy
+ dosbin haproxy
+ dosym /usr/sbin/haproxy /usr/bin/haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r4" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r5" $PN
doman doc/haproxy.1
- dobin haproxy-systemd-wrapper
+ dosbin haproxy-systemd-wrapper
+ dosym /usr/sbin/haproxy-systemd-wrapper /usr/bin/haproxy-systemd-wrapper
systemd_dounit contrib/systemd/haproxy.service
einstalldocs
diff --git a/net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild b/net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild
index dc6dcf334d8..43c58bdf5bc 100644
--- a/net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild
+++ b/net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild
@@ -64,15 +64,6 @@ pkg_setup() {
fi
}
-src_prepare() {
- default
-
- sed -e 's:@SBINDIR@:'/usr/bin':' contrib/systemd/haproxy.service.in \
- > contrib/systemd/haproxy.service || die
-
- sed -ie 's:/usr/sbin/haproxy:/usr/bin/haproxy:' src/haproxy-systemd-wrapper.c || die
-}
-
src_compile() {
local -a args=(
TARGET=linux2628
@@ -96,6 +87,7 @@ src_compile() {
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
@@ -106,14 +98,16 @@ src_compile() {
}
src_install() {
- dobin haproxy
+ dosbin haproxy
+ dosym /usr/sbin/haproxy /usr/bin/haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r4" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r5" $PN
doman doc/haproxy.1
- dobin haproxy-systemd-wrapper
+ dosbin haproxy-systemd-wrapper
+ dosym /usr/sbin/haproxy-systemd-wrapper /usr/bin/haproxy-systemd-wrapper
systemd_dounit contrib/systemd/haproxy.service
einstalldocs
diff --git a/net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild b/net-proxy/haproxy/haproxy-1.7.7.ebuild
similarity index 93%
copy from net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild
copy to net-proxy/haproxy/haproxy-1.7.7.ebuild
index dc6dcf334d8..43c58bdf5bc 100644
--- a/net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild
+++ b/net-proxy/haproxy/haproxy-1.7.7.ebuild
@@ -64,15 +64,6 @@ pkg_setup() {
fi
}
-src_prepare() {
- default
-
- sed -e 's:@SBINDIR@:'/usr/bin':' contrib/systemd/haproxy.service.in \
- > contrib/systemd/haproxy.service || die
-
- sed -ie 's:/usr/sbin/haproxy:/usr/bin/haproxy:' src/haproxy-systemd-wrapper.c || die
-}
-
src_compile() {
local -a args=(
TARGET=linux2628
@@ -96,6 +87,7 @@ src_compile() {
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
@@ -106,14 +98,16 @@ src_compile() {
}
src_install() {
- dobin haproxy
+ dosbin haproxy
+ dosym /usr/sbin/haproxy /usr/bin/haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r4" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r5" $PN
doman doc/haproxy.1
- dobin haproxy-systemd-wrapper
+ dosbin haproxy-systemd-wrapper
+ dosym /usr/sbin/haproxy-systemd-wrapper /usr/bin/haproxy-systemd-wrapper
systemd_dounit contrib/systemd/haproxy.service
einstalldocs
diff --git a/net-proxy/haproxy/haproxy-1.7.9999-r1.ebuild b/net-proxy/haproxy/haproxy-1.7.9999-r1.ebuild
index dc6dcf334d8..43c58bdf5bc 100644
--- a/net-proxy/haproxy/haproxy-1.7.9999-r1.ebuild
+++ b/net-proxy/haproxy/haproxy-1.7.9999-r1.ebuild
@@ -64,15 +64,6 @@ pkg_setup() {
fi
}
-src_prepare() {
- default
-
- sed -e 's:@SBINDIR@:'/usr/bin':' contrib/systemd/haproxy.service.in \
- > contrib/systemd/haproxy.service || die
-
- sed -ie 's:/usr/sbin/haproxy:/usr/bin/haproxy:' src/haproxy-systemd-wrapper.c || die
-}
-
src_compile() {
local -a args=(
TARGET=linux2628
@@ -96,6 +87,7 @@ src_compile() {
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
@@ -106,14 +98,16 @@ src_compile() {
}
src_install() {
- dobin haproxy
+ dosbin haproxy
+ dosym /usr/sbin/haproxy /usr/bin/haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r4" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r5" $PN
doman doc/haproxy.1
- dobin haproxy-systemd-wrapper
+ dosbin haproxy-systemd-wrapper
+ dosym /usr/sbin/haproxy-systemd-wrapper /usr/bin/haproxy-systemd-wrapper
systemd_dounit contrib/systemd/haproxy.service
einstalldocs
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/, net-proxy/haproxy/files/
@ 2017-11-30 7:21 Patrick Lauer
0 siblings, 0 replies; 11+ messages in thread
From: Patrick Lauer @ 2017-11-30 7:21 UTC (permalink / raw
To: gentoo-commits
commit: 1016c8d09a77369c4b37e511bf6b3f03922f7c23
Author: Patrick Lauer <patrick <AT> gentoo <DOT> org>
AuthorDate: Thu Nov 30 07:20:59 2017 +0000
Commit: Patrick Lauer <patrick <AT> gentoo <DOT> org>
CommitDate: Thu Nov 30 07:20:59 2017 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1016c8d0
net-proxy/haproxy: Fix init script
The change in https://bugs.gentoo.org/show_bug.cgi?id=584410 only worked because of
multiple bugs interacting.
Due to variable shadowing https://bugs.gentoo.org/show_bug.cgi?id=639164 the loop did not
actually work, and the /run/haproxy.pid was used in every loop iteration.
This only worked because of a bug in openrc: https://bugs.gentoo.org/show_bug.cgi?id=639218
which was fixed in 0.34.11
So before it killed all processes called haproxy if nbproc > 1 in the config
(which means multiple haproxy instances are all killed if one is stopped!)
After the bugfix it doesn't kill, so we're back to the original situation of leftover
processes. And we don't want to rely on the cgroup killer!
The fix is obviously to use start-stop-daemon directly instead of calling openrc
internals that don't do what you think they do.
Package-Manager: Portage-2.3.16, Repoman-2.3.6
RepoMan-Options: --force
net-proxy/haproxy/Manifest | 4 +-
net-proxy/haproxy/files/haproxy.initd-r4 | 85 -----------
.../files/{haproxy.initd-r5 => haproxy.initd-r6} | 2 +-
...y-1.5.19-r1.ebuild => haproxy-1.5.19-r2.ebuild} | 2 +-
...y-1.6.11-r1.ebuild => haproxy-1.6.11-r2.ebuild} | 2 +-
...y-1.6.13-r2.ebuild => haproxy-1.6.13-r3.ebuild} | 2 +-
...oxy-1.7.8.ebuild => haproxy-1.6.9999-r2.ebuild} | 2 +-
net-proxy/haproxy/haproxy-1.7.7.ebuild | 159 ---------------------
...aproxy-1.7.9.ebuild => haproxy-1.7.9-r1.ebuild} | 2 +-
net-proxy/haproxy/haproxy-1.7.9999-r1.ebuild | 159 ---------------------
...6.9999-r1.ebuild => haproxy-1.7.9999-r2.ebuild} | 2 +-
11 files changed, 8 insertions(+), 413 deletions(-)
diff --git a/net-proxy/haproxy/Manifest b/net-proxy/haproxy/Manifest
index 23588fa5466..4b41f47b5f0 100644
--- a/net-proxy/haproxy/Manifest
+++ b/net-proxy/haproxy/Manifest
@@ -2,6 +2,4 @@ DIST haproxy-1.5.14.tar.gz 1345345 SHA256 9565dd38649064d0350a2883fa81ccfe92eb17
DIST haproxy-1.5.19.tar.gz 1362834 SHA256 e00ae2a633da614967f2e3ebebdb817ec537cba8383b833fc8d9a506876e0d5e SHA512 3462458350d76fe5634428f7b443f21e2d8d4a171ab6254736db2d64587707d11d0df1d851d629c5a2cdfb2858e98cc9345d592859c6d6d8a352b57542dc465a WHIRLPOOL 0cb297dd48e8b9e0c2d6291aa7549c0b6b11e75c58ace3bd50205d7218cf95187129126b21cd13572e0287fc5b311c94ad2ccf664ff30d83a3bc782aea7714ff
DIST haproxy-1.6.11.tar.gz 1574029 SHA256 62fe982edb102a9f55205792bc14b0d05745cc7993cd6bee5d73cd3c5ae16ace SHA512 73ff1c7301197b3bd75a3b1355787419676854d132ce2dcdacb2a296e297dcdfc52b0c571a4fb715e369f1126e1a58196fabb21f828c880f15904032da78e434 WHIRLPOOL 4454c51da89bb089579aefcf54093fd4c09b42918e81e41772d263ebc19f243a37b42135a02c4012705e4cc31370f377cf0b429e81707f307cffe9ed23f5183b
DIST haproxy-1.6.13.tar.gz 1580214 SHA256 7d318583f3a1bf185e857bd40449004b29c95547c89bbb36718f284e29502a1b SHA512 ffed3b347e0cd9cefdc379c91890a3c104d6848b976a9f28984878a9c2d05ca7ddea678f7a93f75cb9d29ae2be921e5a5bd295b1a8771765b099d1c619ded7a3 WHIRLPOOL 70176ee090dacbbdc822c74bba137589f168482c560734c06b98dc23b4d957ed1e016309f11f25a0b486bc6917633455f1174dc6688d6aef53667c61b83a9ff3
-DIST haproxy-1.7.7.tar.gz 1745024 SHA256 81196ca449e4ada45fbd743fe3804bb82c25563ff9653e136872181ee5603ae2 SHA512 aa4720962e94b00c2b6090f62fb875e8977783256d877eb799b6a48c884833bac00b12d04fabd440011007e2af1914e0d67ab485026a447d8a61d58128d04a5a WHIRLPOOL d730dd21f1d8c2132297011e3dfbbbc12b6aa2cc61b67ee1cb9001b9f320e1e403ba917b81c8159fc7e2b43a0e3c95fd27172e1c86aada4963d3a4ecaebb3e2e
-DIST haproxy-1.7.8.tar.gz 1746321 SHA256 ec90153ccedd20ad4015d3eaf76b502ff1f61b431d54c22b8457b5784a9ae142 SHA512 e1d65c8a4607c01d52628f36f8c7342096267130a0f949474746f571158e4f795281f78765004c214a0527f74ce180760f9cc910d3650d30026776076d721c0c WHIRLPOOL f781963b2cf80bfb6219399120821a4dd035dd89c07dc4191d45e2a7e4eaf6e8439f4eaa3174dd7a93ceb6f156d9124806f9c6490f8715bf127f37f0b33f9e17
-DIST haproxy-1.7.9.tar.gz 1748159 SHA256 1072337e54fa188dc6e0cfe3ba4c2200b07082e321cbfe5a0882d85d54db068e SHA512 d1ed791bc9607dbeabcfc6a1853cf258e28b3a079923b63d3bf97504dd59e64a5f5f44f9da968c23c12b4279e8d45ff3bd39418942ca6f00d9d548c9a0ccfd73 WHIRLPOOL efd7671925bfd260c0fce9d611ca24f3253a5553677687e5a136f6371a85852caaa4069df9bd1ba3ebe0d86ebdeef5e3c139609fc922eb0c10467cf28570e151
+DIST haproxy-1.7.9.tar.gz 1748159 BLAKE2B 6826ad3519ff300fb1c91992014834543f971fade8a8b89956d4cd1fc0000b1b3e259586a21ee9fa8ca0ee1f4520517dfc328d83d7a858f469f0366df6e3da43 SHA512 d1ed791bc9607dbeabcfc6a1853cf258e28b3a079923b63d3bf97504dd59e64a5f5f44f9da968c23c12b4279e8d45ff3bd39418942ca6f00d9d548c9a0ccfd73
diff --git a/net-proxy/haproxy/files/haproxy.initd-r4 b/net-proxy/haproxy/files/haproxy.initd-r4
deleted file mode 100644
index c37719b1675..00000000000
--- a/net-proxy/haproxy/files/haproxy.initd-r4
+++ /dev/null
@@ -1,85 +0,0 @@
-#!/sbin/openrc-run
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-extra_commands="checkconfig"
-extra_started_commands="reload"
-
-command="/usr/bin/haproxy"
-
-pidfile="${HAPROXY_PIDFILE:-/run/${SVCNAME}.pid}"
-
-configs=
-
-if [ -z "${CONFIGS}" ]; then
- if [ -f "/etc/haproxy/${SVCNAME}.cfg" ]; then
- CONFIGS=/etc/haproxy/${SVCNAME}.cfg
- elif [ -f "/etc/${SVCNAME}.cfg" ]; then
- CONFIGS=/etc/${SVCNAME}.cfg # Deprecated
- fi
-fi
-
-for conf in $CONFIGS; do
- configs="${configs} -f ${conf}"
-done
-
-command_args="-D -p ${pidfile} ${configs} ${HAPROXY_OPTS}"
-
-depend() {
- need net
- use dns logger
-}
-
-checkconfig() {
- if [ -z "${CONFIGS}" ]; then
- eerror "No config(s) has been specified"
- return 1
- fi
-
- for conf in $CONFIGS; do
- if [ ! -f "${conf}" ]; then
- eerror "${conf} does not exist!"
- return 1
- fi
- done
-
- ebegin "Checking ${CONFIGS}"
- $command -q -c $configs $HAPROXY_OPTS
- eend $?
-}
-
-start_pre() {
- if [ "${RC_CMD}" != "restart" ]; then
- checkconfig || return 1
- fi
-}
-
-stop_pre() {
- if [ "${RC_CMD}" = "restart" ]; then
- checkconfig || return 1
- fi
-}
-
-stop() {
- local _t _pid
-
- _t="$(mktemp)"
- for _pid in $(cat ${pidfile}) ; do
- echo "${_pid}" > "${_t}"
- pidfile="${_t}" default_stop
- done
- rm -f "${_t}"
-}
-
-reload() {
- checkconfig || { eerror "Reloading failed, please fix your config(s) first"; return 1; }
-
- if [ "$(command -v reload_seamless)" = "reload_seamless" ]; then
- einfo "Calling user-defined reload_seamless()"
- reload_seamless || { eerror "reload_seamless() failed!"; return 1; }
- fi
-
- ebegin "Reloading ${SVCNAME}"
- $command -D -p "${pidfile}" $configs $HAPROXY_OPTS -sf $(cat "${pidfile}")
- eend $?
-}
diff --git a/net-proxy/haproxy/files/haproxy.initd-r5 b/net-proxy/haproxy/files/haproxy.initd-r6
similarity index 97%
rename from net-proxy/haproxy/files/haproxy.initd-r5
rename to net-proxy/haproxy/files/haproxy.initd-r6
index 0f2435f7433..9b7c5fe973b 100644
--- a/net-proxy/haproxy/files/haproxy.initd-r5
+++ b/net-proxy/haproxy/files/haproxy.initd-r6
@@ -66,7 +66,7 @@ stop() {
_t="$(mktemp)"
for _pid in $(cat ${pidfile}) ; do
echo "${_pid}" > "${_t}"
- pidfile="${_t}" default_stop
+ start-stop-daemon --stop --pidfile="${_t}"
done
rm -f "${_t}"
}
diff --git a/net-proxy/haproxy/haproxy-1.5.19-r1.ebuild b/net-proxy/haproxy/haproxy-1.5.19-r2.ebuild
similarity index 98%
rename from net-proxy/haproxy/haproxy-1.5.19-r1.ebuild
rename to net-proxy/haproxy/haproxy-1.5.19-r2.ebuild
index 2b0bc8af0a4..7b4655b91af 100644
--- a/net-proxy/haproxy/haproxy-1.5.19-r1.ebuild
+++ b/net-proxy/haproxy/haproxy-1.5.19-r2.ebuild
@@ -91,7 +91,7 @@ src_install() {
dosbin haproxy
dosym /usr/sbin/haproxy /usr/bin/haproxy
- newinitd "${FILESDIR}/haproxy.initd-r5" haproxy
+ newinitd "${FILESDIR}/haproxy.initd-r6" haproxy
# Don't install useless files
# rm examples/build.cfg doc/*gpl.txt
diff --git a/net-proxy/haproxy/haproxy-1.6.11-r1.ebuild b/net-proxy/haproxy/haproxy-1.6.11-r2.ebuild
similarity index 99%
rename from net-proxy/haproxy/haproxy-1.6.11-r1.ebuild
rename to net-proxy/haproxy/haproxy-1.6.11-r2.ebuild
index 06254314e42..9b9f889a0e0 100644
--- a/net-proxy/haproxy/haproxy-1.6.11-r1.ebuild
+++ b/net-proxy/haproxy/haproxy-1.6.11-r2.ebuild
@@ -108,7 +108,7 @@ src_install() {
dobin haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r4" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r6" $PN
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-1.6.13-r2.ebuild b/net-proxy/haproxy/haproxy-1.6.13-r3.ebuild
similarity index 99%
rename from net-proxy/haproxy/haproxy-1.6.13-r2.ebuild
rename to net-proxy/haproxy/haproxy-1.6.13-r3.ebuild
index 5d3f45d2f51..1f40cd754eb 100644
--- a/net-proxy/haproxy/haproxy-1.6.13-r2.ebuild
+++ b/net-proxy/haproxy/haproxy-1.6.13-r3.ebuild
@@ -101,7 +101,7 @@ src_install() {
dosym /usr/sbin/haproxy /usr/bin/haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r5" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r6" $PN
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-1.7.8.ebuild b/net-proxy/haproxy/haproxy-1.6.9999-r2.ebuild
similarity index 99%
rename from net-proxy/haproxy/haproxy-1.7.8.ebuild
rename to net-proxy/haproxy/haproxy-1.6.9999-r2.ebuild
index 43c58bdf5bc..6c77e7061ac 100644
--- a/net-proxy/haproxy/haproxy-1.7.8.ebuild
+++ b/net-proxy/haproxy/haproxy-1.6.9999-r2.ebuild
@@ -102,7 +102,7 @@ src_install() {
dosym /usr/sbin/haproxy /usr/bin/haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r5" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r6" $PN
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-1.7.7.ebuild b/net-proxy/haproxy/haproxy-1.7.7.ebuild
deleted file mode 100644
index 43c58bdf5bc..00000000000
--- a/net-proxy/haproxy/haproxy-1.7.7.ebuild
+++ /dev/null
@@ -1,159 +0,0 @@
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="6"
-
-[[ ${PV} == *9999 ]] && SCM="git-r3"
-inherit user versionator 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://haproxy.1wt.eu"
-if [[ ${PV} != *9999 ]]; then
- SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
- KEYWORDS="~amd64 ~arm ~ppc ~x86"
-else
- EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 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 ssl tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
-REQUIRED_USE="pcre-jit? ( pcre )
- device-atlas? ( pcre )
- ?? ( slz zlib )"
-
-DEPEND="
- pcre? (
- dev-libs/libpcre
- pcre-jit? ( dev-libs/libpcre[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}"
-
-S="${WORKDIR}/${MY_P}"
-
-DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
-version_is_at_least 1.7.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.7-contrib.patch )
-CONTRIBS=( halog iprange )
-# ip6range is present in 1.6, but broken.
-version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
-
-haproxy_use() {
- (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
-
- usex "${1}" "USE_${2}=1" "USE_${2}="
-}
-
-pkg_setup() {
- enewgroup haproxy
- enewuser haproxy -1 -1 -1 haproxy
-
- if use net_ns; then
- CONFIG_CHECK="~NET_NS"
- linux-info_pkg_setup
- fi
-}
-
-src_compile() {
- local -a args=(
- TARGET=linux2628
- USE_GETADDRINFO=1
- USE_TFO=1
- )
-
- 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) )
-
- # 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 /usr/sbin/haproxy /usr/bin/haproxy
-
- newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r5" $PN
-
- doman doc/haproxy.1
-
- dosbin haproxy-systemd-wrapper
- dosym /usr/sbin/haproxy-systemd-wrapper /usr/bin/haproxy-systemd-wrapper
- 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
- 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-1.7.9.ebuild b/net-proxy/haproxy/haproxy-1.7.9-r1.ebuild
similarity index 99%
rename from net-proxy/haproxy/haproxy-1.7.9.ebuild
rename to net-proxy/haproxy/haproxy-1.7.9-r1.ebuild
index 43c58bdf5bc..6c77e7061ac 100644
--- a/net-proxy/haproxy/haproxy-1.7.9.ebuild
+++ b/net-proxy/haproxy/haproxy-1.7.9-r1.ebuild
@@ -102,7 +102,7 @@ src_install() {
dosym /usr/sbin/haproxy /usr/bin/haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r5" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r6" $PN
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-1.7.9999-r1.ebuild b/net-proxy/haproxy/haproxy-1.7.9999-r1.ebuild
deleted file mode 100644
index 43c58bdf5bc..00000000000
--- a/net-proxy/haproxy/haproxy-1.7.9999-r1.ebuild
+++ /dev/null
@@ -1,159 +0,0 @@
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="6"
-
-[[ ${PV} == *9999 ]] && SCM="git-r3"
-inherit user versionator 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://haproxy.1wt.eu"
-if [[ ${PV} != *9999 ]]; then
- SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
- KEYWORDS="~amd64 ~arm ~ppc ~x86"
-else
- EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 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 ssl tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
-REQUIRED_USE="pcre-jit? ( pcre )
- device-atlas? ( pcre )
- ?? ( slz zlib )"
-
-DEPEND="
- pcre? (
- dev-libs/libpcre
- pcre-jit? ( dev-libs/libpcre[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}"
-
-S="${WORKDIR}/${MY_P}"
-
-DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
-version_is_at_least 1.7.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.7-contrib.patch )
-CONTRIBS=( halog iprange )
-# ip6range is present in 1.6, but broken.
-version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
-
-haproxy_use() {
- (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
-
- usex "${1}" "USE_${2}=1" "USE_${2}="
-}
-
-pkg_setup() {
- enewgroup haproxy
- enewuser haproxy -1 -1 -1 haproxy
-
- if use net_ns; then
- CONFIG_CHECK="~NET_NS"
- linux-info_pkg_setup
- fi
-}
-
-src_compile() {
- local -a args=(
- TARGET=linux2628
- USE_GETADDRINFO=1
- USE_TFO=1
- )
-
- 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) )
-
- # 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 /usr/sbin/haproxy /usr/bin/haproxy
-
- newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r5" $PN
-
- doman doc/haproxy.1
-
- dosbin haproxy-systemd-wrapper
- dosym /usr/sbin/haproxy-systemd-wrapper /usr/bin/haproxy-systemd-wrapper
- 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
- 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-1.6.9999-r1.ebuild b/net-proxy/haproxy/haproxy-1.7.9999-r2.ebuild
similarity index 99%
rename from net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild
rename to net-proxy/haproxy/haproxy-1.7.9999-r2.ebuild
index 43c58bdf5bc..6c77e7061ac 100644
--- a/net-proxy/haproxy/haproxy-1.6.9999-r1.ebuild
+++ b/net-proxy/haproxy/haproxy-1.7.9999-r2.ebuild
@@ -102,7 +102,7 @@ src_install() {
dosym /usr/sbin/haproxy /usr/bin/haproxy
newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r5" $PN
+ newinitd "${FILESDIR}/${PN}.initd-r6" $PN
doman doc/haproxy.1
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/, net-proxy/haproxy/files/
@ 2017-11-30 10:53 Christian Ruppert
0 siblings, 0 replies; 11+ messages in thread
From: Christian Ruppert @ 2017-11-30 10:53 UTC (permalink / raw
To: gentoo-commits
commit: ce51abd31589184eb86587cf0d784ead6eb821f5
Author: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
AuthorDate: Thu Nov 30 10:52:34 2017 +0000
Commit: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
CommitDate: Thu Nov 30 10:53:11 2017 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ce51abd3
net-proxy/haproxy: HAProxy 1.8.0 re bug 639040
Package-Manager: Portage-2.3.16, Repoman-2.3.6
net-proxy/haproxy/Manifest | 1 +
net-proxy/haproxy/files/haproxy-1.8-contrib.patch | 81 ++++++++++
net-proxy/haproxy/haproxy-1.8.0.ebuild | 171 ++++++++++++++++++++++
net-proxy/haproxy/metadata.xml | 2 +
4 files changed, 255 insertions(+)
diff --git a/net-proxy/haproxy/Manifest b/net-proxy/haproxy/Manifest
index 4b41f47b5f0..a5314a77b67 100644
--- a/net-proxy/haproxy/Manifest
+++ b/net-proxy/haproxy/Manifest
@@ -3,3 +3,4 @@ DIST haproxy-1.5.19.tar.gz 1362834 SHA256 e00ae2a633da614967f2e3ebebdb817ec537cb
DIST haproxy-1.6.11.tar.gz 1574029 SHA256 62fe982edb102a9f55205792bc14b0d05745cc7993cd6bee5d73cd3c5ae16ace SHA512 73ff1c7301197b3bd75a3b1355787419676854d132ce2dcdacb2a296e297dcdfc52b0c571a4fb715e369f1126e1a58196fabb21f828c880f15904032da78e434 WHIRLPOOL 4454c51da89bb089579aefcf54093fd4c09b42918e81e41772d263ebc19f243a37b42135a02c4012705e4cc31370f377cf0b429e81707f307cffe9ed23f5183b
DIST haproxy-1.6.13.tar.gz 1580214 SHA256 7d318583f3a1bf185e857bd40449004b29c95547c89bbb36718f284e29502a1b SHA512 ffed3b347e0cd9cefdc379c91890a3c104d6848b976a9f28984878a9c2d05ca7ddea678f7a93f75cb9d29ae2be921e5a5bd295b1a8771765b099d1c619ded7a3 WHIRLPOOL 70176ee090dacbbdc822c74bba137589f168482c560734c06b98dc23b4d957ed1e016309f11f25a0b486bc6917633455f1174dc6688d6aef53667c61b83a9ff3
DIST haproxy-1.7.9.tar.gz 1748159 BLAKE2B 6826ad3519ff300fb1c91992014834543f971fade8a8b89956d4cd1fc0000b1b3e259586a21ee9fa8ca0ee1f4520517dfc328d83d7a858f469f0366df6e3da43 SHA512 d1ed791bc9607dbeabcfc6a1853cf258e28b3a079923b63d3bf97504dd59e64a5f5f44f9da968c23c12b4279e8d45ff3bd39418942ca6f00d9d548c9a0ccfd73
+DIST haproxy-1.8.0.tar.gz 2036854 BLAKE2B c7cebcb3e27f61f8fd65e084c8557c6ecbde07a9517c5950330b315cc76a4ced86272ca7b75a292380a867229be5e2b4e65514d4daae276472fa4d6a7919798c SHA512 7461c49cc00e7d6baf08dad9aba77e2b5cbbb532a902131838b0cc670a9ea85232f2da7187c3463c3bb76ca6955e17ce7eeec57378c002aaac3cf1dfbaf6cceb
diff --git a/net-proxy/haproxy/files/haproxy-1.8-contrib.patch b/net-proxy/haproxy/files/haproxy-1.8-contrib.patch
new file mode 100644
index 00000000000..a3e336a5773
--- /dev/null
+++ b/net-proxy/haproxy/files/haproxy-1.8-contrib.patch
@@ -0,0 +1,81 @@
+From c702537864f7e062d18f4ccce3e29d14d4ccf05f Mon Sep 17 00:00:00 2001
+From: Christian Ruppert <idl0r@gentoo.org>
+Date: Thu, 30 Nov 2017 10:11:36 +0100
+Subject: [PATCH] Fix LDFLAGS vs. LIBS re linking order
+
+Signed-off-by: Christian Ruppert <idl0r@gentoo.org>
+---
+ contrib/mod_defender/Makefile | 5 ++---
+ contrib/modsecurity/Makefile | 5 ++---
+ contrib/spoa_example/Makefile | 5 ++---
+ 3 files changed, 6 insertions(+), 9 deletions(-)
+
+diff --git a/contrib/mod_defender/Makefile b/contrib/mod_defender/Makefile
+index ac17774d..efc7d7f6 100644
+--- a/contrib/mod_defender/Makefile
++++ b/contrib/mod_defender/Makefile
+@@ -28,9 +28,8 @@ EVENT_INC := /usr/include
+ endif
+
+ CFLAGS += -g -Wall -pthread
+-LDFLAGS += -lpthread $(EVENT_LIB) -levent_pthreads -lapr-1 -laprutil-1 -lstdc++ -lm
+ INCS += -I../../include -I../../ebtree -I$(MOD_DEFENDER_SRC) -I$(APACHE2_INC) -I$(APR_INC) -I$(EVENT_INC)
+-LIBS =
++LIBS += -lpthread $(EVENT_LIB) -levent_pthreads -lapr-1 -laprutil-1 -lstdc++ -lm
+
+ CXXFLAGS = -g -std=gnu++11
+ CXXINCS += -I$(MOD_DEFENDER_SRC) -I$(MOD_DEFENDER_SRC)/deps -I$(APACHE2_INC) -I$(APR_INC)
+@@ -43,7 +42,7 @@ CXXSRCS = $(wildcard $(MOD_DEFENDER_SRC)/*.cpp)
+ CXXOBJS = $(patsubst %.cpp, %.o, $(CXXSRCS))
+
+ defender: $(OBJS) $(CXXOBJS)
+- $(LD) -o $@ $^ $(LDFLAGS) $(LIBS)
++ $(LD) $(LDFLAGS) -o $@ $^ $(LIBS)
+
+ install: defender
+ install defender $(DESTDIR)$(BINDIR)
+diff --git a/contrib/modsecurity/Makefile b/contrib/modsecurity/Makefile
+index bb918c30..aa0d6e38 100644
+--- a/contrib/modsecurity/Makefile
++++ b/contrib/modsecurity/Makefile
+@@ -34,14 +34,13 @@ EVENT_INC := /usr/include
+ endif
+
+ CFLAGS += -g -Wall -pthread
+-LDFLAGS += -lpthread $(EVENT_LIB) -levent_pthreads -lcurl -lapr-1 -laprutil-1 -lxml2 -lpcre -lyajl
+ INCS += -I../../include -I../../ebtree -I$(MODSEC_INC) -I$(APACHE2_INC) -I$(APR_INC) -I$(LIBXML_INC) -I$(EVENT_INC)
+-LIBS =
++LIBS += -lpthread $(EVENT_LIB) -levent_pthreads -lcurl -lapr-1 -laprutil-1 -lxml2 -lpcre -lyajl
+
+ OBJS = spoa.o modsec_wrapper.o
+
+ modsecurity: $(OBJS)
+- $(LD) $(LDFLAGS) $(LIBS) -o $@ $^ $(MODSEC_LIB)/standalone.a
++ $(LD) $(LDFLAGS) -o $@ $^ $(MODSEC_LIB)/standalone.a $(LIBS)
+
+ install: modsecurity
+ install modsecurity $(DESTDIR)$(BINDIR)
+diff --git a/contrib/spoa_example/Makefile b/contrib/spoa_example/Makefile
+index d04a01e1..c44c2b87 100644
+--- a/contrib/spoa_example/Makefile
++++ b/contrib/spoa_example/Makefile
+@@ -6,15 +6,14 @@ CC = gcc
+ LD = $(CC)
+
+ CFLAGS = -g -O2 -Wall -Werror -pthread
+-LDFLAGS = -lpthread -levent -levent_pthreads
+ INCS += -I../../ebtree -I./include
+-LIBS =
++LIBS = -lpthread -levent -levent_pthreads
+
+ OBJS = spoa.o
+
+
+ spoa: $(OBJS)
+- $(LD) $(LDFLAGS) $(LIBS) -o $@ $^
++ $(LD) $(LDFLAGS) -o $@ $^ $(LIBS)
+
+ install: spoa
+ install spoa $(DESTDIR)$(BINDIR)
+--
+2.13.6
diff --git a/net-proxy/haproxy/haproxy-1.8.0.ebuild b/net-proxy/haproxy/haproxy-1.8.0.ebuild
new file mode 100644
index 00000000000..80e41f24b2a
--- /dev/null
+++ b/net-proxy/haproxy/haproxy-1.8.0.ebuild
@@ -0,0 +1,171 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="6"
+
+[[ ${PV} == *9999 ]] && SCM="git-r3"
+inherit user versionator 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://haproxy.1wt.eu"
+if [[ ${PV} != *9999 ]]; then
+ SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
+ KEYWORDS="~amd64 ~arm ~ppc ~x86"
+else
+ EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 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}"
+
+S="${WORKDIR}/${MY_P}"
+
+DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
+version_is_at_least 1.7.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.7-contrib.patch )
+version_is_at_least 1.8.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.8-contrib.patch )
+CONTRIBS=( halog iprange )
+# ip6range is present in 1.6, but broken.
+version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
+# TODO: mod_defender - requires apache / APR, modsecurity - the same
+version_is_at_least 1.8.0 $PV && CONTRIBS+=( hpack )
+
+haproxy_use() {
+ (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
+
+ usex "${1}" "USE_${2}=1" "USE_${2}="
+}
+
+pkg_setup() {
+ enewgroup haproxy
+ enewuser haproxy -1 -1 -1 haproxy
+
+ if use net_ns; then
+ CONFIG_CHECK="~NET_NS"
+ linux-info_pkg_setup
+ fi
+}
+
+src_compile() {
+ local -a args=(
+ 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 /usr/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/metadata.xml b/net-proxy/haproxy/metadata.xml
index 017b2b8ad09..6a09dde73e2 100644
--- a/net-proxy/haproxy/metadata.xml
+++ b/net-proxy/haproxy/metadata.xml
@@ -21,6 +21,8 @@
<use>
<flag name="net_ns">Enable network namespace support (CONFIG_NET_NS)</flag>
<flag name="pcre-jit">Use JIT support for PCRE</flag>
+ <flag name="pcre2">Enable PCRE2 RegEx support</flag>
+ <flag name="pcre2-jit">Use JIT support for PCRE2</flag>
<flag name="slz">Use <pkg>dev-libs/libslz</pkg> compression library</flag>
<flag name="tools">Install additional tools (halog, iprange)</flag>
<flag name="device-atlas">Use <pkg>dev-libs/device-atlas-api-c</pkg> library</flag>
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/, net-proxy/haproxy/files/
@ 2019-11-27 9:51 Christian Ruppert
0 siblings, 0 replies; 11+ messages in thread
From: Christian Ruppert @ 2019-11-27 9:51 UTC (permalink / raw
To: gentoo-commits
commit: 8cda07fe4e5f899b7756a547ede64c4c6da39f13
Author: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
AuthorDate: Wed Nov 27 09:27:05 2019 +0000
Commit: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
CommitDate: Wed Nov 27 09:51:37 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8cda07fe
net-proxy/haproxy: Cleanup old versions
Package-Manager: Portage-2.3.78, Repoman-2.3.17
Signed-off-by: Christian Ruppert <idl0r <AT> gentoo.org>
net-proxy/haproxy/Manifest | 4 -
net-proxy/haproxy/files/haproxy-1.7-contrib.patch | 31 ----
net-proxy/haproxy/haproxy-1.6.11-r2.ebuild | 164 ----------------------
net-proxy/haproxy/haproxy-1.6.15.ebuild | 158 ---------------------
net-proxy/haproxy/haproxy-1.7.10.ebuild | 159 ---------------------
net-proxy/haproxy/haproxy-1.7.12.ebuild | 159 ---------------------
6 files changed, 675 deletions(-)
diff --git a/net-proxy/haproxy/Manifest b/net-proxy/haproxy/Manifest
index 22654dee2d2..ef7e789f4cb 100644
--- a/net-proxy/haproxy/Manifest
+++ b/net-proxy/haproxy/Manifest
@@ -1,7 +1,3 @@
-DIST haproxy-1.6.11.tar.gz 1574029 BLAKE2B 553f74c2c24a1b07cef2acc6fbc4def1bbe81e41a7b01ba44937c6ff2e14c1f1a4f1472dde229ecef1ed3170f4e89d356324cb2ce1e7d7064837f37fbd4c3b46 SHA512 73ff1c7301197b3bd75a3b1355787419676854d132ce2dcdacb2a296e297dcdfc52b0c571a4fb715e369f1126e1a58196fabb21f828c880f15904032da78e434
-DIST haproxy-1.6.15.tar.gz 1589782 BLAKE2B d65684b75c9577644d88a2ca17bf90f5cb845ca8c4c149ddf95a06b0ad2d25bb6a457c4c380c6cae4745bac2c00ec49cdb89df60ba8704965239cb0f2951670a SHA512 fd50c8451a357494a7c767347d1d9d957e07664e2388f3f8f0d492823e6d974d55b9f8699bd98c8d37d9829e4180c395569d0d7a4da2dc3c0f4849607598e9c0
-DIST haproxy-1.7.10.tar.gz 1750937 BLAKE2B 26d970862e415b079d4130fd00564677584a7aad74d6812cabed36de9a629321330434b7d4fdf7c2e8b2945b7f394ca33e444158e7fa9b49937db501ea33e78a SHA512 ca6c50848c559ee2ffb9af2d281c3931473dd90d1686d95d962cf604cd92d2feb2b63e006e217cf9078cf08fdd73dc523318c97e13400bc0ef325de47111394e
-DIST haproxy-1.7.12.tar.gz 1760527 BLAKE2B da46b21140c242eda7df09a91d2f6fd88912e62aa0c316cd3cd6a7726be96cd9b579b3c908ec5aabec6a3e98a77e2b40f930c0e491e806ba2c1c857e5676fabc SHA512 66c099ff3057e5a18e0ac6155382cc208fe583a215ae530541056eb634e5c30062558ce182360772684c403b6574b5f02f900d90c847ffc5f6a823c41bfb7766
DIST haproxy-1.8.13.tar.gz 2063046 BLAKE2B 9ebccf2520719cdf209bc9a87bf28d015b5b673e0d017d5387af4025f930ac401f6a2cfa851583ffe6b6645b7b91ad255bb5db737688a1f310958072a11c8a80 SHA512 54d4cb0721a3868267d7e085b3d3bb050384e4279eb49e88abb925bb3ea8cc39ef9069bdc99b7b18a23fd22e0d29e24dfcb8a0507ddca9243a845e4418be9cc5
DIST haproxy-1.8.23.tar.gz 2101424 BLAKE2B e1be06fd604f8715d52ad66ea77a1eb56d38eae46442eca9d497bd4eb5f34124ba32f5c9f44d0232063af3f3803e37b205eda9bd21266064de6db287b49fabe6 SHA512 bfd65179345285f6f4581a7dce42e638b89e12717d4cb9218afa085759161e04b6c78307d04265a6c97cd484b67949781639da5236edb89137585c625130be4f
DIST haproxy-1.8.9.tar.gz 2057051 BLAKE2B d81d18f68a27ae8a77660c1ecb1dfc28599263ebfd57f25ea574af2b101b35eb7a1a89ba4034b55dfa89673ae6ac4c0dca5428b4b494a02184b1b157850ce96b SHA512 e59c29af3a39d6212f012ae8341b169436e10e42fadaf8f1aa68d2bb7ee181fd1fe3b74640bfcd8c37c17dfc5062b36bd69d90290d7c59cd3e4648ef2ab1c8dd
diff --git a/net-proxy/haproxy/files/haproxy-1.7-contrib.patch b/net-proxy/haproxy/files/haproxy-1.7-contrib.patch
deleted file mode 100644
index 9ecffe7e3c7..00000000000
--- a/net-proxy/haproxy/files/haproxy-1.7-contrib.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-diff -Nuar --exclude '*~' haproxy-1.7.9999.orig/contrib/tcploop/Makefile haproxy-1.7.9999/contrib/tcploop/Makefile
---- haproxy-1.7.9999.orig/contrib/tcploop/Makefile 2016-12-04 16:08:05.497256646 -0800
-+++ haproxy-1.7.9999/contrib/tcploop/Makefile 2016-12-04 16:12:20.558141392 -0800
-@@ -5,7 +5,7 @@
- OBJS = tcploop
-
- tcploop: tcploop.c
-- $(CC) $(OPTIMIZE) $(DEFINE) $(INCLUDE) -o $@ $^
-+ $(CC) $(OPTIMIZE) $(DEFINE) $(INCLUDE) $(LDFLAGS) -o $@ $^ $(LIBS)
-
- clean:
- rm -f $(OBJS) *.[oas] *~
-diff -Nuar --exclude '*~' haproxy-1.7.9999.orig/contrib/spoa_example/Makefile haproxy-1.7.9999/contrib/spoa_example/Makefile
---- haproxy-1.7.9999.orig/contrib/spoa_example/Makefile 2016-12-04 15:56:49.068302156 -0800
-+++ haproxy-1.7.9999/contrib/spoa_example/Makefile 2016-12-04 15:58:51.360644213 -0800
-@@ -6,13 +6,13 @@
- LD = $(CC)
-
- CFLAGS = -g -O2 -Wall -Werror -pthread
--LDFLAGS = -lpthread
-+LIBS = -lpthread
-
- OBJS = spoa.o
-
-
- spoa: $(OBJS)
-- $(LD) $(LDFLAGS) -o $@ $^
-+ $(LD) $(LDFLAGS) -o $@ $^ $(LIBS)
-
- install: spoa
- install spoa $(DESTDIR)$(BINDIR)
diff --git a/net-proxy/haproxy/haproxy-1.6.11-r2.ebuild b/net-proxy/haproxy/haproxy-1.6.11-r2.ebuild
deleted file mode 100644
index 9b9f889a0e0..00000000000
--- a/net-proxy/haproxy/haproxy-1.6.11-r2.ebuild
+++ /dev/null
@@ -1,164 +0,0 @@
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="6"
-
-[[ ${PV} == *9999 ]] && SCM="git-r3"
-inherit user versionator 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://haproxy.1wt.eu"
-if [[ ${PV} != *9999 ]]; then
- SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
- KEYWORDS="amd64 arm ppc x86"
-else
- EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 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 ssl tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
-REQUIRED_USE="pcre-jit? ( pcre )
- ?? ( slz zlib )"
-
-DEPEND="
- pcre? (
- dev-libs/libpcre
- pcre-jit? ( dev-libs/libpcre[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}"
-
-S="${WORKDIR}/${MY_P}"
-
-DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
-version_is_at_least 1.7.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.7-contrib.patch )
-CONTRIBS=( halog iprange )
-# ip6range is present in 1.6, but broken.
-version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
-
-haproxy_use() {
- (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
-
- usex "${1}" "USE_${2}=1" "USE_${2}="
-}
-
-pkg_setup() {
- enewgroup haproxy
- enewuser haproxy -1 -1 -1 haproxy
-
- if use net_ns; then
- CONFIG_CHECK="~NET_NS"
- linux-info_pkg_setup
- fi
-}
-
-src_prepare() {
- default
-
- sed -e 's:@SBINDIR@:'/usr/bin':' contrib/systemd/haproxy.service.in \
- > contrib/systemd/haproxy.service || die
-
- sed -ie 's:/usr/sbin/haproxy:/usr/bin/haproxy:' src/haproxy-systemd-wrapper.c || die
-}
-
-src_compile() {
- local -a args=(
- TARGET=linux2628
- USE_GETADDRINFO=1
- USE_TFO=1
- )
-
- 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) )
-
- # For now, until the strict-aliasing breakage will be fixed
- append-cflags -fno-strict-aliasing
-
- emake CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]}
-
- 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() {
- dobin haproxy
-
- newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r6" $PN
-
- doman doc/haproxy.1
-
- dobin haproxy-systemd-wrapper
- 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
- 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-1.6.15.ebuild b/net-proxy/haproxy/haproxy-1.6.15.ebuild
deleted file mode 100644
index 634b436d835..00000000000
--- a/net-proxy/haproxy/haproxy-1.6.15.ebuild
+++ /dev/null
@@ -1,158 +0,0 @@
-# Copyright 1999-2019 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="6"
-
-[[ ${PV} == *9999 ]] && SCM="git-r3"
-inherit user versionator 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://haproxy.1wt.eu"
-if [[ ${PV} != *9999 ]]; then
- SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
- KEYWORDS="~amd64 ~arm ~ppc ~x86"
-else
- EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 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 ssl tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
-REQUIRED_USE="pcre-jit? ( pcre )
- ?? ( slz zlib )"
-
-DEPEND="
- pcre? (
- dev-libs/libpcre
- pcre-jit? ( dev-libs/libpcre[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}"
-
-S="${WORKDIR}/${MY_P}"
-
-DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
-version_is_at_least 1.7.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.7-contrib.patch )
-CONTRIBS=( halog iprange )
-# ip6range is present in 1.6, but broken.
-version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
-
-haproxy_use() {
- (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
-
- usex "${1}" "USE_${2}=1" "USE_${2}="
-}
-
-pkg_setup() {
- enewgroup haproxy
- enewuser haproxy -1 -1 -1 haproxy
-
- if use net_ns; then
- CONFIG_CHECK="~NET_NS"
- linux-info_pkg_setup
- fi
-}
-
-src_compile() {
- local -a args=(
- TARGET=linux2628
- USE_GETADDRINFO=1
- USE_TFO=1
- )
-
- 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) )
-
- # 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 /usr/sbin/haproxy /usr/bin/haproxy
-
- newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r6" $PN
-
- doman doc/haproxy.1
-
- dosbin haproxy-systemd-wrapper
- dosym /usr/sbin/haproxy-systemd-wrapper /usr/bin/haproxy-systemd-wrapper
- 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
- 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-1.7.10.ebuild b/net-proxy/haproxy/haproxy-1.7.10.ebuild
deleted file mode 100644
index 2848b4df635..00000000000
--- a/net-proxy/haproxy/haproxy-1.7.10.ebuild
+++ /dev/null
@@ -1,159 +0,0 @@
-# Copyright 1999-2018 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="6"
-
-[[ ${PV} == *9999 ]] && SCM="git-r3"
-inherit user versionator 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://haproxy.1wt.eu"
-if [[ ${PV} != *9999 ]]; then
- SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
- KEYWORDS="amd64 arm ppc x86"
-else
- EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 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 ssl tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
-REQUIRED_USE="pcre-jit? ( pcre )
- device-atlas? ( pcre )
- ?? ( slz zlib )"
-
-DEPEND="
- pcre? (
- dev-libs/libpcre
- pcre-jit? ( dev-libs/libpcre[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}"
-
-S="${WORKDIR}/${MY_P}"
-
-DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
-version_is_at_least 1.7.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.7-contrib.patch )
-CONTRIBS=( halog iprange )
-# ip6range is present in 1.6, but broken.
-version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
-
-haproxy_use() {
- (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
-
- usex "${1}" "USE_${2}=1" "USE_${2}="
-}
-
-pkg_setup() {
- enewgroup haproxy
- enewuser haproxy -1 -1 -1 haproxy
-
- if use net_ns; then
- CONFIG_CHECK="~NET_NS"
- linux-info_pkg_setup
- fi
-}
-
-src_compile() {
- local -a args=(
- TARGET=linux2628
- USE_GETADDRINFO=1
- USE_TFO=1
- )
-
- 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) )
-
- # 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 /usr/sbin/haproxy /usr/bin/haproxy
-
- newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r6" $PN
-
- doman doc/haproxy.1
-
- dosbin haproxy-systemd-wrapper
- dosym /usr/sbin/haproxy-systemd-wrapper /usr/bin/haproxy-systemd-wrapper
- 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
- 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-1.7.12.ebuild b/net-proxy/haproxy/haproxy-1.7.12.ebuild
deleted file mode 100644
index 0b2ddea1094..00000000000
--- a/net-proxy/haproxy/haproxy-1.7.12.ebuild
+++ /dev/null
@@ -1,159 +0,0 @@
-# Copyright 1999-2019 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="6"
-
-[[ ${PV} == *9999 ]] && SCM="git-r3"
-inherit user versionator 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://haproxy.1wt.eu"
-if [[ ${PV} != *9999 ]]; then
- SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz"
- KEYWORDS="~amd64 ~arm ~ppc ~x86"
-else
- EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 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 ssl tools vim-syntax +zlib lua device-atlas 51degrees wurfl"
-REQUIRED_USE="pcre-jit? ( pcre )
- device-atlas? ( pcre )
- ?? ( slz zlib )"
-
-DEPEND="
- pcre? (
- dev-libs/libpcre
- pcre-jit? ( dev-libs/libpcre[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}"
-
-S="${WORKDIR}/${MY_P}"
-
-DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
-version_is_at_least 1.7.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.7-contrib.patch )
-CONTRIBS=( halog iprange )
-# ip6range is present in 1.6, but broken.
-version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop )
-
-haproxy_use() {
- (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
-
- usex "${1}" "USE_${2}=1" "USE_${2}="
-}
-
-pkg_setup() {
- enewgroup haproxy
- enewuser haproxy -1 -1 -1 haproxy
-
- if use net_ns; then
- CONFIG_CHECK="~NET_NS"
- linux-info_pkg_setup
- fi
-}
-
-src_compile() {
- local -a args=(
- TARGET=linux2628
- USE_GETADDRINFO=1
- USE_TFO=1
- )
-
- 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) )
-
- # 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 /usr/sbin/haproxy /usr/bin/haproxy
-
- newconfd "${FILESDIR}/${PN}.confd" $PN
- newinitd "${FILESDIR}/${PN}.initd-r6" $PN
-
- doman doc/haproxy.1
-
- dosbin haproxy-systemd-wrapper
- dosym /usr/sbin/haproxy-systemd-wrapper /usr/bin/haproxy-systemd-wrapper
- 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
- 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
-}
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/, net-proxy/haproxy/files/
@ 2020-11-09 8:36 Christian Ruppert
0 siblings, 0 replies; 11+ messages in thread
From: Christian Ruppert @ 2020-11-09 8:36 UTC (permalink / raw
To: gentoo-commits
commit: b9d3fedad9c1bcb74eac279e1b3732cdb73c2236
Author: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
AuthorDate: Mon Nov 9 08:35:45 2020 +0000
Commit: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
CommitDate: Mon Nov 9 08:36:03 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b9d3feda
net-proxy/haproxy: Fix hpack compilation, bug 753509
Package-Manager: Portage-3.0.8, Repoman-3.0.2
Signed-off-by: Christian Ruppert <idl0r <AT> gentoo.org>
.../files/haproxy-2.3.0-hpack-VAR_ARRAY.patch | 37 ++++++++++++++++++++++
net-proxy/haproxy/haproxy-2.3.0.ebuild | 4 +--
2 files changed, 38 insertions(+), 3 deletions(-)
diff --git a/net-proxy/haproxy/files/haproxy-2.3.0-hpack-VAR_ARRAY.patch b/net-proxy/haproxy/files/haproxy-2.3.0-hpack-VAR_ARRAY.patch
new file mode 100644
index 00000000000..4f6bf4cf717
--- /dev/null
+++ b/net-proxy/haproxy/files/haproxy-2.3.0-hpack-VAR_ARRAY.patch
@@ -0,0 +1,37 @@
+From 759146f0de143939b841ba987aabb83aa178a4fc Mon Sep 17 00:00:00 2001
+From: Christian Ruppert <idl0r@qasl.de>
+Date: Mon, 9 Nov 2020 09:15:21 +0100
+Subject: [PATCH] hpack-tbl-t.h uses VAR_ARRAY and requires compiler.h to be
+ included
+
+This fixes building hpack from contrib, which failed because of the
+undeclared VAR_ARRAY:
+
+make -C contrib/hpack
+...
+cc -O2 -Wall -g -I../../include -fwrapv -fno-strict-aliasing -c -o gen-enc.o gen-enc.c
+In file included from gen-enc.c:18:
+../../include/haproxy/hpack-tbl-t.h:105:23: error: 'VAR_ARRAY' undeclared here (not in a function)
+ 105 | struct hpack_dte dte[VAR_ARRAY]; /* dynamic table entries */
+...
+
+Signed-off-by: Christian Ruppert <idl0r@qasl.de>
+---
+ include/haproxy/hpack-tbl-t.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/include/haproxy/hpack-tbl-t.h b/include/haproxy/hpack-tbl-t.h
+index 344f665dd..07f1ca9ea 100644
+--- a/include/haproxy/hpack-tbl-t.h
++++ b/include/haproxy/hpack-tbl-t.h
+@@ -28,6 +28,7 @@
+ #define _HAPROXY_HPACK_TBL_T_H
+
+ #include <inttypes.h>
++#include "compiler.h"
+
+ /* Dynamic Headers Table, usable for tables up to 4GB long and values of 64kB-1.
+ * The model can be improved by using offsets relative to the table entry's end
+--
+2.26.2
+
diff --git a/net-proxy/haproxy/haproxy-2.3.0.ebuild b/net-proxy/haproxy/haproxy-2.3.0.ebuild
index d1c45681b56..e0be5d2ff6e 100644
--- a/net-proxy/haproxy/haproxy-2.3.0.ebuild
+++ b/net-proxy/haproxy/haproxy-2.3.0.ebuild
@@ -51,6 +51,7 @@ RDEPEND="${DEPEND}
S="${WORKDIR}/${MY_P}"
+PATCHES=( "${FILESDIR}/${P}-hpack-VAR_ARRAY.patch" )
DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
CONTRIBS=( halog iprange )
# ip6range is present in 1.6, but broken.
@@ -94,9 +95,6 @@ src_compile() {
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
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/, net-proxy/haproxy/files/
@ 2022-07-26 8:28 Christian Ruppert
0 siblings, 0 replies; 11+ messages in thread
From: Christian Ruppert @ 2022-07-26 8:28 UTC (permalink / raw
To: gentoo-commits
commit: 3233b24b3e882edea9ad2752650baf1506b0ccc0
Author: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
AuthorDate: Tue Jul 26 08:13:20 2022 +0000
Commit: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
CommitDate: Tue Jul 26 08:28:28 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3233b24b
net-proxy/haproxy: Fix reloading and use master-CLI
Package-Manager: Portage-3.0.30, Repoman-3.0.3
Signed-off-by: Christian Ruppert <idl0r <AT> gentoo.org>
net-proxy/haproxy/files/haproxy.confd-r1 | 14 ++++
net-proxy/haproxy/files/haproxy.initd-r8 | 85 ++++++++++++++++++++++
net-proxy/haproxy/haproxy-2.2.9999.ebuild | 4 +-
net-proxy/haproxy/haproxy-2.4.9999.ebuild | 4 +-
net-proxy/haproxy/haproxy-2.5.9999.ebuild | 4 +-
...aproxy-2.6.2.ebuild => haproxy-2.6.2-r1.ebuild} | 4 +-
net-proxy/haproxy/haproxy-2.6.9999.ebuild | 4 +-
net-proxy/haproxy/haproxy-9999.ebuild | 4 +-
8 files changed, 111 insertions(+), 12 deletions(-)
diff --git a/net-proxy/haproxy/files/haproxy.confd-r1 b/net-proxy/haproxy/files/haproxy.confd-r1
new file mode 100644
index 000000000000..b9bb84e3e833
--- /dev/null
+++ b/net-proxy/haproxy/files/haproxy.confd-r1
@@ -0,0 +1,14 @@
+# HAProxy config file(s), space separated
+#CONFIGS="/etc/haproxy/haproxy.cfg"
+
+# Additional HAProxy command line options
+HAPROXY_OPTS="-S /run/haproxy-master.sock"
+
+# If you want to make use ot the new seamless reload you can just write your own
+# reload_seamless function here. It will be called by the init script.
+# For more information on how to use that feature please have a look at the
+# "seamless_reload.txt" documentation file (requires net-proxy/haproxy[examples])
+#reload_seamless() {
+# checkpath -d -m 0700 haproxy:haproxy "/run/haproxy/"
+# socat /run/haproxy/socket - <<< "show servers state" > /run/haproxy/global.state
+#}
diff --git a/net-proxy/haproxy/files/haproxy.initd-r8 b/net-proxy/haproxy/files/haproxy.initd-r8
new file mode 100644
index 000000000000..4994c28b42d5
--- /dev/null
+++ b/net-proxy/haproxy/files/haproxy.initd-r8
@@ -0,0 +1,85 @@
+#!/sbin/openrc-run
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+extra_commands="checkconfig"
+extra_started_commands="reload"
+
+command="/usr/sbin/haproxy"
+
+pidfile="${HAPROXY_PIDFILE:-/run/${SVCNAME}.pid}"
+
+configs=
+
+if [ -z "${CONFIGS}" ]; then
+ if [ -f "/etc/haproxy/${SVCNAME}.cfg" ]; then
+ CONFIGS=/etc/haproxy/${SVCNAME}.cfg
+ elif [ -f "/etc/${SVCNAME}.cfg" ]; then
+ CONFIGS=/etc/${SVCNAME}.cfg # Deprecated
+ fi
+fi
+
+for conf in $CONFIGS; do
+ configs="${configs} -f ${conf}"
+done
+
+command_args="-D -W -p ${pidfile} ${configs} ${HAPROXY_OPTS}"
+
+depend() {
+ need net
+ use dns logger
+}
+
+checkconfig() {
+ if [ -z "${CONFIGS}" ]; then
+ eerror "No config(s) has been specified"
+ return 1
+ fi
+
+ for conf in $CONFIGS; do
+ if [ ! -f "${conf}" ]; then
+ eerror "${conf} does not exist!"
+ return 1
+ fi
+ done
+
+ ebegin "Checking ${CONFIGS}"
+ $command -q -c $configs $HAPROXY_OPTS
+ eend $?
+}
+
+start_pre() {
+ if [ "${RC_CMD}" != "restart" ]; then
+ checkconfig || return 1
+ fi
+}
+
+stop_pre() {
+ if [ "${RC_CMD}" = "restart" ]; then
+ checkconfig || return 1
+ fi
+}
+
+stop() {
+ local _t _pid
+
+ _t="$(mktemp)"
+ for _pid in $(cat ${pidfile}) ; do
+ echo "${_pid}" > "${_t}"
+ start-stop-daemon --stop --pidfile="${_t}"
+ done
+ rm -f "${_t}"
+}
+
+reload() {
+ checkconfig || { eerror "Reloading failed, please fix your config(s) first"; return 1; }
+
+ if [ "$(command -v reload_seamless)" = "reload_seamless" ]; then
+ einfo "Calling user-defined reload_seamless()"
+ reload_seamless || { eerror "reload_seamless() failed!"; return 1; }
+ fi
+
+ ebegin "Reloading ${SVCNAME}"
+ $command $command_args -sf $(cat "${pidfile}")
+ eend $?
+}
diff --git a/net-proxy/haproxy/haproxy-2.2.9999.ebuild b/net-proxy/haproxy/haproxy-2.2.9999.ebuild
index 4ec0188ead43..954368323612 100644
--- a/net-proxy/haproxy/haproxy-2.2.9999.ebuild
+++ b/net-proxy/haproxy/haproxy-2.2.9999.ebuild
@@ -124,8 +124,8 @@ src_install() {
dosbin haproxy
dosym ../sbin/haproxy /usr/bin/haproxy
- newconfd "${FILESDIR}/${PN}.confd" ${PN}
- newinitd "${FILESDIR}/${PN}.initd-r7" ${PN}
+ newconfd "${FILESDIR}/${PN}.confd-r1" ${PN}
+ newinitd "${FILESDIR}/${PN}.initd-r8" ${PN}
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-2.4.9999.ebuild b/net-proxy/haproxy/haproxy-2.4.9999.ebuild
index a8f7f3e7ffd3..56ad7268073b 100644
--- a/net-proxy/haproxy/haproxy-2.4.9999.ebuild
+++ b/net-proxy/haproxy/haproxy-2.4.9999.ebuild
@@ -119,8 +119,8 @@ src_install() {
dosbin haproxy
dosym ../sbin/haproxy /usr/bin/haproxy
- newconfd "${FILESDIR}/${PN}.confd" ${PN}
- newinitd "${FILESDIR}/${PN}.initd-r7" ${PN}
+ newconfd "${FILESDIR}/${PN}.confd-r1" ${PN}
+ newinitd "${FILESDIR}/${PN}.initd-r8" ${PN}
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-2.5.9999.ebuild b/net-proxy/haproxy/haproxy-2.5.9999.ebuild
index 2b772750ef60..853340e4fcb2 100644
--- a/net-proxy/haproxy/haproxy-2.5.9999.ebuild
+++ b/net-proxy/haproxy/haproxy-2.5.9999.ebuild
@@ -119,8 +119,8 @@ src_install() {
dosbin haproxy
dosym ../sbin/haproxy /usr/bin/haproxy
- newconfd "${FILESDIR}/${PN}.confd" ${PN}
- newinitd "${FILESDIR}/${PN}.initd-r7" ${PN}
+ newconfd "${FILESDIR}/${PN}.confd-r1" ${PN}
+ newinitd "${FILESDIR}/${PN}.initd-r8" ${PN}
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-2.6.2.ebuild b/net-proxy/haproxy/haproxy-2.6.2-r1.ebuild
similarity index 98%
rename from net-proxy/haproxy/haproxy-2.6.2.ebuild
rename to net-proxy/haproxy/haproxy-2.6.2-r1.ebuild
index 5fc0953b5485..6e17e38ddf96 100644
--- a/net-proxy/haproxy/haproxy-2.6.2.ebuild
+++ b/net-proxy/haproxy/haproxy-2.6.2-r1.ebuild
@@ -119,8 +119,8 @@ src_install() {
dosbin haproxy
dosym ../sbin/haproxy /usr/bin/haproxy
- newconfd "${FILESDIR}/${PN}.confd" ${PN}
- newinitd "${FILESDIR}/${PN}.initd-r7" ${PN}
+ newconfd "${FILESDIR}/${PN}.confd-r1" ${PN}
+ newinitd "${FILESDIR}/${PN}.initd-r8" ${PN}
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-2.6.9999.ebuild b/net-proxy/haproxy/haproxy-2.6.9999.ebuild
index 5fc0953b5485..6e17e38ddf96 100644
--- a/net-proxy/haproxy/haproxy-2.6.9999.ebuild
+++ b/net-proxy/haproxy/haproxy-2.6.9999.ebuild
@@ -119,8 +119,8 @@ src_install() {
dosbin haproxy
dosym ../sbin/haproxy /usr/bin/haproxy
- newconfd "${FILESDIR}/${PN}.confd" ${PN}
- newinitd "${FILESDIR}/${PN}.initd-r7" ${PN}
+ newconfd "${FILESDIR}/${PN}.confd-r1" ${PN}
+ newinitd "${FILESDIR}/${PN}.initd-r8" ${PN}
doman doc/haproxy.1
diff --git a/net-proxy/haproxy/haproxy-9999.ebuild b/net-proxy/haproxy/haproxy-9999.ebuild
index 5fc0953b5485..6e17e38ddf96 100644
--- a/net-proxy/haproxy/haproxy-9999.ebuild
+++ b/net-proxy/haproxy/haproxy-9999.ebuild
@@ -119,8 +119,8 @@ src_install() {
dosbin haproxy
dosym ../sbin/haproxy /usr/bin/haproxy
- newconfd "${FILESDIR}/${PN}.confd" ${PN}
- newinitd "${FILESDIR}/${PN}.initd-r7" ${PN}
+ newconfd "${FILESDIR}/${PN}.confd-r1" ${PN}
+ newinitd "${FILESDIR}/${PN}.initd-r8" ${PN}
doman doc/haproxy.1
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/, net-proxy/haproxy/files/
@ 2023-01-26 8:48 Christian Ruppert
0 siblings, 0 replies; 11+ messages in thread
From: Christian Ruppert @ 2023-01-26 8:48 UTC (permalink / raw
To: gentoo-commits
commit: de0ae9f5165b5c8cf2d542d9655f546dc802fbe4
Author: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
AuthorDate: Thu Jan 26 08:47:19 2023 +0000
Commit: Christian Ruppert <idl0r <AT> gentoo <DOT> org>
CommitDate: Thu Jan 26 08:47:57 2023 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=de0ae9f5
net-proxy/haproxy: Bump to 2.5.11, 2.6.8 and also fix hpack compiling
Bug: https://bugs.gentoo.org/891859
Signed-off-by: Christian Ruppert <idl0r <AT> gentoo.org>
net-proxy/haproxy/Manifest | 2 +
net-proxy/haproxy/files/haproxy-2.7.2-hpack.patch | 49 ++++++++++++++++++++++
...{haproxy-2.7.2.ebuild => haproxy-2.5.11.ebuild} | 5 ++-
.../{haproxy-2.7.2.ebuild => haproxy-2.6.8.ebuild} | 1 +
net-proxy/haproxy/haproxy-2.7.2.ebuild | 1 +
5 files changed, 56 insertions(+), 2 deletions(-)
diff --git a/net-proxy/haproxy/Manifest b/net-proxy/haproxy/Manifest
index 4fccbe9fd80a..a5ab90ddcfac 100644
--- a/net-proxy/haproxy/Manifest
+++ b/net-proxy/haproxy/Manifest
@@ -4,9 +4,11 @@ DIST haproxy-2.4.18.tar.gz 3626923 BLAKE2B 1ec312a5607634f7906cfcf5d4e22d829bdca
DIST haproxy-2.4.19.tar.gz 67414 BLAKE2B 5fcb3b582e6bfa52849f45a04360da7ccf7888e1a84ae7039a77ecf0f7f76be369941c6b81e9b3610416736c35c40d08f831ea8fd264b05874b376029267e660 SHA512 82b6e4d4f5a2170ac8399a69b5aa9cfe7c4d9df7aa611d087c5654730b593250b2c1af8113bad96e39c1953301f4b5e40311741bff1588f4360a019f06d8929b
DIST haproxy-2.4.20.tar.gz 3640093 BLAKE2B 45c6b9d22628c34177154900a85d303392b4de4c9fc74db64fed7bd31bc64df5ca6c853c393a59afbd762c0f96b27c54717ca7d89bc46e336678574f333bbccc SHA512 dbd3a025627b2115f9e16cf8d2774138049760aa89ad235e7c7f0fa7c706e6bd83cb41be0e597c70948825fa90f968579ca8ab35f7a435a4ea18dbbea72405d7
DIST haproxy-2.5.10.tar.gz 3850472 BLAKE2B c5d7301447ece3733aa78ce2aa4f41b73f03e9b684d609469f68cb109a477e99aa569ee7a7d23cd8f0734dc1c631233b12b9e4367b71b06d139c8aba5faaa2b9 SHA512 0a91bc1c65924fa5c43f9c58eedd59213a431ed3196a0479df74b59885de0e6ead799d3943ede38f42ddd5ffb6e61b95bf0653c758ec442ff5bb3533645788c5
+DIST haproxy-2.5.11.tar.gz 3860869 BLAKE2B 657651c6e9a3fa03cfa932d50e6cc72023973531685bccb3690f9458437bcf5a9da81faf0e7cd35bacb4747f5cf2a0b7250e8355d5b849129ea58b41cf0beed3 SHA512 11f63ddc590823b312819e1baa5a05fac97bdcf20ea36de5ff9cbc0c8b18ef81954492b6ef4ca7a3e93848ea81543edfa9bc3a27e48b517b60f0da589ec9005e
DIST haproxy-2.5.7.tar.gz 3832801 BLAKE2B 6d54135b56f84129dea497ddc935fecf593abccfb21fc647c7d166f9c1aa4abc670c66bf13e0923e353627d83d47345f632ae8212672c3b3da7a757fd5d24d7c SHA512 cf6994508d559401a84e1304c2b6829952a9b3a14365d03436da42ec7e4553c201ffde9e524044dfa48813e8e614d24095a87b0fae7d9145ce5e66b953666ee9
DIST haproxy-2.5.8.tar.gz 3838130 BLAKE2B fd02c285682815fd1837190b80184e110bb6a37b99dfa30e6cece628e62af6a5a145d97f5849e64364a286593d0ea206506c0b474485b22018a816b899744710 SHA512 99a49556864b178c024e73e5bd45051a7a6e512bbb52906ba6f3888e22a83e2b91198ed1c6a3bcbbc44c474a9ba6a6373fae4216fac8ecdb5d724f281b00fd68
DIST haproxy-2.6.6.tar.gz 4015438 BLAKE2B 36e676e011e290cc16ed4d116426639e9c11dcc6383fbcc82da8c9df87f19dde55a420167d926a510f6ca06cedec5588abb1ee1dd78881e3ecafbe428ea247c7 SHA512 0b416d200e9b406a96896d3570483d24e94fdfa3f781bee663476e218a57851aefdf8768f00c8a2e9df1bb028f6398690f07da452f59656327967685787ee5c2
DIST haproxy-2.6.7.tar.gz 4028355 BLAKE2B 3af8123bf534cc6dc2bf6777c080c9ccaf9d910f4b53ae4349d9abf8868f3fd552855c86d0ff9a1e3a948b769232400377786aed1ac6404a671bfadb6f66dc5d SHA512 d6f4399195647cef39a502e4c2170a9a494992880d5a805cf7ceae8b0845f7b5768b25e2f3c025dcfffd6da478058ae0b687904020ca21fee486223ad22e9c35
+DIST haproxy-2.6.8.tar.gz 4041517 BLAKE2B 1f3fe78e04565440f6a578ec15a436df4857ecbf0256333df8c195f2ce7fc4c7d522be8a7bdbaadc882c0f02ee2b4af543b4bf236d63994a8699c829cc9c6b28 SHA512 b5c126c6e0249ebd461bd1a98c63f821392a665f0ae2c6cb1527becb5e1be6326121680f17b6f96785e9a7bd6b5bc6789091eb21cb70000c2fc7b88cd6a87b12
DIST haproxy-2.7.1.tar.gz 4120306 BLAKE2B aa9e6273468e07b91efb8ecedcf06f2bdcb0ba7949ba710bf94d23a59987031be0f94d78a3efa707fbaba711773db76516f76e1cdc2a92b1eaeac0786e1b8663 SHA512 89df867b2f052618480d1e28293e84111160c31fa250c2af1a452f8fce627fd2c69c929bcfd5d68399fd02ebbf77301b0ff34a58a64fe73f034a234491c3e4d2
DIST haproxy-2.7.2.tar.gz 4130348 BLAKE2B 97cd3a28c64b1fe0b14976f29a7b2f07e10dfb6a2abfe0c8baaced58a706f54e0c8bcbd8da1a8f3741e72bc2f59fea37ea16297f996906cac039662d19b062e8 SHA512 0746f715b9f0acce3c5eb6ade6f201f21806ee51cdd3da453cf32c7e36fab772a74b4a476ed80f1176fe29a0c706479017cfeb8850d53fc6ad2ee40da66ba1e1
diff --git a/net-proxy/haproxy/files/haproxy-2.7.2-hpack.patch b/net-proxy/haproxy/files/haproxy-2.7.2-hpack.patch
new file mode 100644
index 000000000000..f744eccfaba9
--- /dev/null
+++ b/net-proxy/haproxy/files/haproxy-2.7.2-hpack.patch
@@ -0,0 +1,49 @@
+From 494ae0c35c883632faf1d22b54083d3e97a7c129 Mon Sep 17 00:00:00 2001
+From: Aurelien DARRAGON <adarragon@haproxy.com>
+Date: Wed, 25 Jan 2023 16:35:00 +0100
+Subject: [PATCH] DEV: hpack: fix `trash` build regression
+
+Since 7d84439 ("BUILD: hpack: include global.h for the trash that is needed
+in debug mode"), hpack decode tool fails to compile on targets that enable
+USE_THREAD. (ie: linux-glibc target as reported by Christian Ruppert)
+
+When building hpack devtool, we are including src/hpack-dec.c as a dependency.
+src/hpack-dec.c relies on the global trash whe debug mode is enabled.
+But as we're building hpack tool with a limited scope of haproxy
+sources, global trash (which is declared in src/chunk.c) is not available.
+Thus, src/hpack-dec.c relies on a local 'trash' variable declared within
+dev/hpack/decode.c
+
+This used to work fine until 7d84439.
+But now that global.h is explicitely included in src/hpack-dec.c,
+trash variable definition from decode.c conflicts with the one from global.h:
+
+ In file included from include/../src/hpack-dec.c:35,
+ from dev/hpack/decode.c:87:
+ include/haproxy/global.h:52:35: error: thread-local declaration of 'trash' follows non-thread-local declaration
+ 52 | extern THREAD_LOCAL struct buffer trash;
+
+Adding THREAD_LOCAL attribute to 'decode.c' local trash variable definition
+makes the compiler happy again.
+
+This should fix GH issue #2009
+---
+ dev/hpack/decode.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/dev/hpack/decode.c b/dev/hpack/decode.c
+index ae825120f..13c95c77a 100644
+--- a/dev/hpack/decode.c
++++ b/dev/hpack/decode.c
+@@ -30,7 +30,7 @@ uint8_t buf[MAX_RQ_SIZE];
+ char trash_buf[MAX_RQ_SIZE];
+ char tmp_buf[MAX_RQ_SIZE];
+
+-struct buffer trash = { .area = trash_buf, .data = 0, .size = sizeof(trash_buf) };
++THREAD_LOCAL struct buffer trash = { .area = trash_buf, .data = 0, .size = sizeof(trash_buf) };
+ struct buffer tmp = { .area = tmp_buf, .data = 0, .size = sizeof(tmp_buf) };
+
+ /* displays a <len> long memory block at <buf>, assuming first byte of <buf>
+--
+2.34.1
+
diff --git a/net-proxy/haproxy/haproxy-2.7.2.ebuild b/net-proxy/haproxy/haproxy-2.5.11.ebuild
similarity index 98%
copy from net-proxy/haproxy/haproxy-2.7.2.ebuild
copy to net-proxy/haproxy/haproxy-2.5.11.ebuild
index 83227697a6a5..e4f9680de05c 100644
--- a/net-proxy/haproxy/haproxy-2.7.2.ebuild
+++ b/net-proxy/haproxy/haproxy-2.5.11.ebuild
@@ -3,7 +3,7 @@
EAPI="7"
-LUA_COMPAT=( lua5-4 lua5-3 )
+LUA_COMPAT=( lua5-3 lua5-3 )
[[ ${PV} == *9999 ]] && SCM="git-r3"
inherit toolchain-funcs lua-single systemd linux-info ${SCM}
@@ -52,6 +52,7 @@ S="${WORKDIR}/${MY_P}"
DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
EXTRAS=( admin/halog admin/iprange dev/tcploop dev/hpack )
+PATCHES=( "${FILESDIR}/${PN}-2.7.2-hpack.patch" )
haproxy_use() {
(( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
@@ -140,7 +141,7 @@ src_install() {
doins examples/errorfiles/*
if use doc; then
- dodoc doc/*.txt
+ dodoc ROADMAP doc/*.txt
#if use lua; then
# TODO: doc/lua-api/
#fi
diff --git a/net-proxy/haproxy/haproxy-2.7.2.ebuild b/net-proxy/haproxy/haproxy-2.6.8.ebuild
similarity index 99%
copy from net-proxy/haproxy/haproxy-2.7.2.ebuild
copy to net-proxy/haproxy/haproxy-2.6.8.ebuild
index 83227697a6a5..484348984cb9 100644
--- a/net-proxy/haproxy/haproxy-2.7.2.ebuild
+++ b/net-proxy/haproxy/haproxy-2.6.8.ebuild
@@ -52,6 +52,7 @@ S="${WORKDIR}/${MY_P}"
DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
EXTRAS=( admin/halog admin/iprange dev/tcploop dev/hpack )
+PATCHES=( "${FILESDIR}/${PN}-2.7.2-hpack.patch" )
haproxy_use() {
(( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
diff --git a/net-proxy/haproxy/haproxy-2.7.2.ebuild b/net-proxy/haproxy/haproxy-2.7.2.ebuild
index 83227697a6a5..62b7196b5198 100644
--- a/net-proxy/haproxy/haproxy-2.7.2.ebuild
+++ b/net-proxy/haproxy/haproxy-2.7.2.ebuild
@@ -52,6 +52,7 @@ S="${WORKDIR}/${MY_P}"
DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README )
EXTRAS=( admin/halog admin/iprange dev/tcploop dev/hpack )
+PATCHES=( "${FILESDIR}/${P}-hpack.patch" )
haproxy_use() {
(( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>"
^ permalink raw reply related [flat|nested] 11+ messages in thread
end of thread, other threads:[~2023-01-26 8:48 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-11-30 10:53 [gentoo-commits] repo/gentoo:master commit in: net-proxy/haproxy/, net-proxy/haproxy/files/ Christian Ruppert
-- strict thread matches above, loose matches on Subject: below --
2023-01-26 8:48 Christian Ruppert
2022-07-26 8:28 Christian Ruppert
2020-11-09 8:36 Christian Ruppert
2019-11-27 9:51 Christian Ruppert
2017-11-30 7:21 Patrick Lauer
2017-07-04 22:22 Robin H. Johnson
2017-06-21 18:22 Patrick Lauer
2016-12-05 15:56 Robin H. Johnson
2016-10-15 14:52 Patrice Clement
2015-10-16 20:11 Christian Ruppert
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox