From 407525b571b48cfd65e1ad7a02d250a927c967c9 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Fri, 1 Dec 2017 03:04:39 +0000 Subject: gentoo resync : 01.12.2017 --- net-proxy/haproxy/files/haproxy-1.8-contrib.patch | 81 +++++++++++++++++++++ net-proxy/haproxy/files/haproxy.initd-r4 | 85 ----------------------- net-proxy/haproxy/files/haproxy.initd-r5 | 85 ----------------------- net-proxy/haproxy/files/haproxy.initd-r6 | 85 +++++++++++++++++++++++ 4 files changed, 166 insertions(+), 170 deletions(-) create mode 100644 net-proxy/haproxy/files/haproxy-1.8-contrib.patch delete mode 100644 net-proxy/haproxy/files/haproxy.initd-r4 delete mode 100644 net-proxy/haproxy/files/haproxy.initd-r5 create mode 100644 net-proxy/haproxy/files/haproxy.initd-r6 (limited to 'net-proxy/haproxy/files') 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 000000000000..a3e336a57734 --- /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 +Date: Thu, 30 Nov 2017 10:11:36 +0100 +Subject: [PATCH] Fix LDFLAGS vs. LIBS re linking order + +Signed-off-by: Christian Ruppert +--- + 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/files/haproxy.initd-r4 b/net-proxy/haproxy/files/haproxy.initd-r4 deleted file mode 100644 index c37719b16752..000000000000 --- 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-r5 deleted file mode 100644 index 0f2435f74339..000000000000 --- a/net-proxy/haproxy/files/haproxy.initd-r5 +++ /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/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/files/haproxy.initd-r6 b/net-proxy/haproxy/files/haproxy.initd-r6 new file mode 100644 index 000000000000..9b7c5fe973ba --- /dev/null +++ b/net-proxy/haproxy/files/haproxy.initd-r6 @@ -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}" + 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 -D -p "${pidfile}" $configs $HAPROXY_OPTS -sf $(cat "${pidfile}") + eend $? +} -- cgit v1.2.3