Date: Fri, 26 Feb 2010 21:39:05 GMT From: Ross West <freebsd@linepoint.com> To: freebsd-gnats-submit@FreeBSD.org Subject: ports/144331: [Patch][Maintainer Update] net/haproxy: v1.2.18 -> v1.4.0 Message-ID: <201002262139.o1QLd5PF008084@www.freebsd.org> Resent-Message-ID: <201002262140.o1QLe2Km050760@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 144331 >Category: ports >Synopsis: [Patch][Maintainer Update] net/haproxy: v1.2.18 -> v1.4.0 >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: update >Submitter-Id: current-users >Arrival-Date: Fri Feb 26 21:40:02 UTC 2010 >Closed-Date: >Last-Modified: >Originator: Ross West >Release: FreeBSD 8.0-RELEASE amd64 >Organization: >Environment: >Description: Large update for net/haproxy port! - Patch to update net/haproxy software from legacy v1.2.18 stable branch to new stable branch v1.4.0. This leapfrogs port net/haproxy-devel, which is currently tracking v1.3.x branch (maintained by different person). - Updates Maintainer from generic ports@freebsd.org to myself (freebsd@linepoint.com) - Changed rc.d file provided (also haproxy.sh -> haproxy) >How-To-Repeat: >Fix: See attached patchfile Patch attached with submission follows: diff -ruN --exclude=CVS /usr/ports/net/haproxy.1.2.18/Makefile /usr/ports/net/haproxy/Makefile --- /usr/ports/net/haproxy.1.2.18/Makefile 2010-02-26 16:08:04.000000000 -0500 +++ /usr/ports/net/haproxy/Makefile 2010-02-26 15:39:23.000000000 -0500 @@ -6,57 +6,47 @@ # PORTNAME= haproxy -PORTVERSION= 1.2.18 +PORTVERSION= 1.4.0 CATEGORIES= net www -MASTER_SITES= http://haproxy.1wt.eu/download/1.2/src/ +MASTER_SITES= http://haproxy.1wt.eu/download/1.4/src/ -MAINTAINER= ports@FreeBSD.org -COMMENT= High-performance and highly-robust TCP/HTTP load balancer +MAINTAINER= freebsd@linepoint.com +COMMENT= The Reliable, High Performance TCP/HTTP Load Balancer -USE_RC_SUBR= haproxy.sh +USE_RC_SUBR= haproxy +USE_GMAKE= YES +MAN1= haproxy.1 -STATS_INTERVAL?= 0 -CFLAGS+= -DSTATTIME=${STATS_INTERVAL} +OPTIONS= PCRE "Use PCRE regex library" On\ + STATIC_PCRE "Use static PCRE regex library" Off -.if defined(WITH_TPROXY) -CFLAGS+= -DTPROXY -.endif +.include <bsd.port.options.mk> + +MAKE_ARGS= "TARGET=freebsd" .if defined(WITH_PCRE) -PKGNAMESUFFIX= -pcre LIB_DEPENDS+= pcre.0:${PORTSDIR}/devel/pcre -MAKE_ENV+= "REGEX=pcre" -CFLAGS+= -DUSE_PCRE -I${LOCALBASE}/include -LDFLAGS+= -L${LOCALBASE}/lib -lpcreposix -lpcre +MAKE_ARGS+= "USE_PCRE=1" .endif -.if defined(WITH_SMALLOPTS) -CFLAGS+= -DBUFSIZE=8030 -DMAXREWRITE=1030 -DSYSTEM_MAXCONN=1024 +.if defined(WITH_STATIC_PCRE) +LIB_DEPENDS+= pcre.0:${PORTSDIR}/devel/pcre +MAKE_ARGS+= "USE_STATIC_PCRE=1" .endif -MAKEFILE= Makefile.bsd - -pre-everything:: - @${ECHO_MSG} "" - @${ECHO_MSG} "Available options:" - @${ECHO_MSG} "WITH_PCRE: Use pcre regex engine" - @${ECHO_MSG} "WITH_TPROXY: Enable Transparent proxy support" - @${ECHO_MSG} "WITH_SMALLOPTS: Enable low memory footprint support" - @${ECHO_MSG} "STATS_INTERVAL=###: Statistics interval in milliseconds," - @${ECHO_MSG} " (default to 0, disabled)" - @${ECHO_MSG} "" - do-install: - @${INSTALL_PROGRAM} ${WRKSRC}/haproxy ${PREFIX}/sbin + @${INSTALL_PROGRAM} ${WRKSRC}/haproxy ${PREFIX}/sbin/ + @${INSTALL_DATA} ${WRKSRC}/examples/haproxy.cfg ${PREFIX}/etc/haproxy.cfg-dist + @${INSTALL_MAN} ${WRKSRC}/doc/haproxy.1 ${MAN1PREFIX}/man/man1 .if !defined(NOPORTDOCS) @${MKDIR} ${DOCSDIR} + (cd ${WRKSRC}/doc/ && ${COPYTREE_SHARE} \* ${DOCSDIR}) @${MKDIR} ${EXAMPLESDIR} - @${INSTALL_DATA} ${WRKSRC}/doc/* ${DOCSDIR} - @${INSTALL_DATA} ${WRKSRC}/examples/haproxy.cfg \ - ${EXAMPLESDIR}/haproxy.cfg + (cd ${WRKSRC}/examples/ && ${COPYTREE_SHARE} \* ${EXAMPLESDIR}) .endif post-install: @${CAT} ${PKGMESSAGE} + .include <bsd.port.mk> diff -ruN --exclude=CVS /usr/ports/net/haproxy.1.2.18/distinfo /usr/ports/net/haproxy/distinfo --- /usr/ports/net/haproxy.1.2.18/distinfo 2008-08-31 16:09:58.000000000 -0400 +++ /usr/ports/net/haproxy/distinfo 2010-02-26 12:39:32.000000000 -0500 @@ -1,3 +1,3 @@ -MD5 (haproxy-1.2.18.tar.gz) = aa1884cbbb22fab2e8ff0beb37db1f8b -SHA256 (haproxy-1.2.18.tar.gz) = e0ef06180fae5e3a96712b86486788a0f961459640fd94d99389548df50aa9c0 -SIZE (haproxy-1.2.18.tar.gz) = 206287 +MD5 (haproxy-1.4.0.tar.gz) = 0d6019b79631048765a7dfd55f1875cd +SHA256 (haproxy-1.4.0.tar.gz) = 971d352f34cb9480ac5fcd5c6af7cbaefce064832d98e7846beb3e504def5907 +SIZE (haproxy-1.4.0.tar.gz) = 756062 diff -ruN --exclude=CVS /usr/ports/net/haproxy.1.2.18/files/haproxy.in /usr/ports/net/haproxy/files/haproxy.in --- /usr/ports/net/haproxy.1.2.18/files/haproxy.in 1969-12-31 19:00:00.000000000 -0500 +++ /usr/ports/net/haproxy/files/haproxy.in 2010-02-26 15:57:52.000000000 -0500 @@ -0,0 +1,65 @@ +#!/bin/sh + +# PROVIDE: haproxy +# REQUIRE: DAEMON +# KEYWORD: shutdown + +# +# Add the following lines to /etc/rc.conf to enable haproxy: +# +# haproxy_enable (bool): default: "NO" +# Set to "YES" to enable haproxy +# haproxy_pidfile (str): default: /var/run/${name}.pid +# Set to the full path of the pid file +# haproxy_flags (str): default: Autogenerated using other options below +# Set to override with your own options +# haproxy_config (str): default: %%PREFIX%%/etc/${name}.conf +# Set to the full path of the config file + +. %%RC_SUBR%% + +name="haproxy" +rcvar=`set_rcvar` +command="%%PREFIX%%/sbin/haproxy" + +# Load Configs/Set Defaults +load_rc_config $name +: ${haproxy_enable:="NO"} +: ${haproxy_config:="%%PREFIX%%/etc/${name}.conf"} +: ${haproxy_pidfile="/var/run/${name}.pid"} +: ${haproxy_flags:="-D -q -f ${haproxy_config} -p ${haproxy_pidfile}"} + +# Update the globals +pidfile=${haproxy_pidfile} +required_files=${haproxy_config} + +# Commands: start, stop, restart, kill, checkconfig +extra_commands="checkconfig" + +checkconfig_cmd="haproxy_checkconfig" +reload_cmd="haproxy_reload" +stop_cmd="haproxy_stop" + +haproxy_stop() +{ + ${command} -st ${rc_pid} +} + +haproxy_reload() +{ + ${command} -sf ${rc_pid} +} + +haproxy_checkconfig() +{ + ${command} -c -f ${haproxy_config} +} + +haproxy_prestart() +{ + # Check configuration file quietly first + ${command} -q -c -f ${haproxy_config} + rc_flags=${haproxy_flags} +} + +run_rc_command "$1" diff -ruN --exclude=CVS /usr/ports/net/haproxy.1.2.18/files/haproxy.sh.in /usr/ports/net/haproxy/files/haproxy.sh.in --- /usr/ports/net/haproxy.1.2.18/files/haproxy.sh.in 2006-11-01 09:42:14.000000000 -0500 +++ /usr/ports/net/haproxy/files/haproxy.sh.in 1969-12-31 19:00:00.000000000 -0500 @@ -1,50 +0,0 @@ -#!/bin/sh -# -# $FreeBSD: ports/net/haproxy/files/haproxy.sh.in,v 1.1 2006/11/01 14:42:14 clement Exp $ -# - -# PROVIDE: haproxy -# REQUIRE: NETWORKING SERVERS -# BEFORE: DAEMON -# KEYWORD: shutdown - -# -# Add the following lines to /etc/rc.conf to enable haproxy: -# haproxy_enable (bool): Set to "NO" by default. -# Set it to "YES" to enable haproxy -# haproxylimits_enable (bool):Set to "NO" by default. -# Set it to yes to run `limits $limits_args` -# just before haproxy starts. -# haproxy_flags (str): Set to "" by default. -# Extra flags passed to start command -# haproxylimits_args (str): Default to "-e -C daemon" -# Arguments of pre-start limits run. -# -. %%RC_SUBR%% - -name="haproxy" -rcvar=`set_rcvar` - -command="%%PREFIX%%/sbin/haproxy" -pidfile="/var/run/haproxy.pid" -required_files=%%PREFIX%%/etc/haproxy.conf - -[ -z "$haproxy_enable" ] && haproxy_enable="NO" -[ -z "$haproxy_flags" ] && haproxy_flags="-p ${pidfile} -f /usr/local/etc/haproxy.conf" -[ -z "$haproxylimits_enable" ] && haproxylimits_enable="NO" -[ -z "$haproxylimits_args" ] && haproxylimits_args="-e -C daemon" - -load_rc_config $name - -checkyesno haproxylimits_enable && \ - start_precmd="eval `/usr/bin/limits ${haproxylimits_args}` 2>/dev/null" - -sig_gracefulstop=SIGUSR1 - -haproxy_gracefulstop() { - echo "Gracefully shutdown haproxy ($rc_pid)" - kill -${sig_gracefulstop} ${rc_pid} - } - -extra_commands="gracefulstop" -run_rc_command "$1" diff -ruN --exclude=CVS /usr/ports/net/haproxy.1.2.18/files/patch-Makefile.bsd /usr/ports/net/haproxy/files/patch-Makefile.bsd --- /usr/ports/net/haproxy.1.2.18/files/patch-Makefile.bsd 2007-08-12 11:45:08.000000000 -0400 +++ /usr/ports/net/haproxy/files/patch-Makefile.bsd 1969-12-31 19:00:00.000000000 -0500 @@ -1,85 +0,0 @@ ---- ./Makefile.bsd.orig 2007-03-18 05:04:39.000000000 +0800 -+++ ./Makefile.bsd 2007-07-24 20:38:01.803049803 +0800 -@@ -5,22 +5,22 @@ - TARGET = openbsd - - # pass CPU=<cpu_name> to make to optimize for a particular CPU --CPU = generic -+#CPU = generic - #CPU = i586 - #CPU = i686 - #CPU = ultrasparc - - # By default, we use libc's regex. WARNING! On Solaris 8/Sparc, group - # references seem broken using libc ! Use pcre instead. --REGEX=libc -+REGEX?=libc - #REGEX=pcre - #REGEX=static-pcre - - # tools options --CC = gcc --LD = gcc -+CC?= gcc -+LD?= gcc - --PCREDIR=/usr/local -+PCREDIR=${LOCALBASE} - - # This is for OpenBSD 3.0 - COPTS.openbsd = -DENABLE_POLL -@@ -46,7 +46,7 @@ - - # you can enable debug arguments with "DEBUG=-g" or disable them with "DEBUG=" - #DEBUG = -g -DDEBUG_MEMORY -DDEBUG_FULL --DEBUG = -g -+#DEBUG = -g - - # if small memory footprint is required, you can reduce the buffer size. There - # are 2 buffers per concurrent session, so 16 kB buffers will eat 32 MB memory -@@ -54,7 +54,7 @@ - # will avoid the additionnal paramters to overflow a page. 8030 bytes is - # exactly 5.5 TCP segments of 1460 bytes. - #SMALL_OPTS = --SMALL_OPTS = -DBUFSIZE=8030 -DMAXREWRITE=1030 -DSYSTEM_MAXCONN=1024 -+#SMALL_OPTS = -DBUFSIZE=8030 -DMAXREWRITE=1030 -DSYSTEM_MAXCONN=1024 - - # redefine this if you want to add some special PATH to include/libs - ADDINC = -@@ -65,7 +65,7 @@ - # - use -DSTATTIME=0 to disable statistics, else specify an interval in - # milliseconds. - # - use -DTPROXY to compile with transparent proxy support. --DEFINE = -DSTATTIME=0 -DTPROXY -+#DEFINE = -DSTATTIME=0 -DTPROXY - - # global options - TARGET_OPTS=$(COPTS.$(TARGET)) -@@ -75,14 +75,14 @@ - COPTS=-I. $(ADDINC) $(CPU_OPTS) $(TARGET_OPTS) $(REGEX_OPTS) $(SMALL_OPTS) $(DEFINE) - LIBS=$(LIBS.$(TARGET)) $(LIBS.$(REGEX)) $(ADDLIB) - --CFLAGS = -Wall $(COPTS) $(DEBUG) --LDFLAGS = -g -+CFLAGS+= -Wall $(COPTS) -+LDFLAGS+= #-g /lib/crt0.o -lc - - all: haproxy - - haproxy: src/list.o src/chtbl.o src/hashpjw.o haproxy.o src/base64.o \ - src/uri_auth.o src/rbtree.o -- $(LD) $(LDFLAGS) -o $@ $> $(LIBS) -+ $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $> $(LIBS) - - src/base64.o: src/base64.c - $(CC) $(CFLAGS) -c -o $@ $< -@@ -99,6 +99,9 @@ - src/hashpjw.o: src/hashpjw.c - $(CC) $(CFLAGS) -c -o $@ $< - -+src/rbtree.o: src/rbtree.c -+ $(CC) $(CFLAGS) -c -o $@ $< -+ - haproxy.o: haproxy.c - $(CC) $(CFLAGS) -c -o $@ $< - diff -ruN --exclude=CVS /usr/ports/net/haproxy.1.2.18/pkg-message /usr/ports/net/haproxy/pkg-message --- /usr/ports/net/haproxy.1.2.18/pkg-message 2004-06-08 06:31:00.000000000 -0400 +++ /usr/ports/net/haproxy/pkg-message 2010-02-26 15:59:39.000000000 -0500 @@ -1,3 +1,10 @@ -===> BE CAREFULL HOW TO BOOT on 1.1.28 or after: - To run haproxy from startup, add haproxy_enable="YES" in your - /etc/rc.conf. + +************************************************* +* Congratulations! Haproxy is now installed. * +************************************************* + +The following directories probably got installed too: + '${PREFIX}/share/doc/haproxy' - documentation + '${PREFIX}/share/examples/haproxy' - examples + + diff -ruN --exclude=CVS /usr/ports/net/haproxy.1.2.18/pkg-plist /usr/ports/net/haproxy/pkg-plist --- /usr/ports/net/haproxy.1.2.18/pkg-plist 2006-11-03 03:27:13.000000000 -0500 +++ /usr/ports/net/haproxy/pkg-plist 2010-02-26 13:51:19.000000000 -0500 @@ -1,7 +1,71 @@ sbin/haproxy +etc/haproxy.cfg-dist +%%PORTDOCS%%%%DOCSDIR%%/acl.fig %%PORTDOCS%%%%DOCSDIR%%/architecture.txt +%%PORTDOCS%%%%DOCSDIR%%/configuration.txt +%%PORTDOCS%%%%DOCSDIR%%/design-thoughts/backends-v0.txt +%%PORTDOCS%%%%DOCSDIR%%/design-thoughts/backends.txt +%%PORTDOCS%%%%DOCSDIR%%/design-thoughts/be-fe-changes.txt +%%PORTDOCS%%%%DOCSDIR%%/design-thoughts/buffers.fig +%%PORTDOCS%%%%DOCSDIR%%/design-thoughts/config-language.txt +%%PORTDOCS%%%%DOCSDIR%%/design-thoughts/cttproxy-changes.txt +%%PORTDOCS%%%%DOCSDIR%%/design-thoughts/how-it-works.txt +%%PORTDOCS%%%%DOCSDIR%%/design-thoughts/http_load_time.url +%%PORTDOCS%%%%DOCSDIR%%/design-thoughts/sess_par_sec.txt +%%PORTDOCS%%%%DOCSDIR%%/gpl.txt %%PORTDOCS%%%%DOCSDIR%%/haproxy-en.txt %%PORTDOCS%%%%DOCSDIR%%/haproxy-fr.txt -%%PORTDOCS%%%%EXAMPLESDIR%%/haproxy.cfg +%%PORTDOCS%%%%DOCSDIR%%/haproxy.1 +%%PORTDOCS%%%%DOCSDIR%%/internals/connect-status.txt +%%PORTDOCS%%%%DOCSDIR%%/internals/connection-header.txt +%%PORTDOCS%%%%DOCSDIR%%/internals/connection-scale.txt +%%PORTDOCS%%%%DOCSDIR%%/internals/header-parser-speed.txt +%%PORTDOCS%%%%DOCSDIR%%/internals/header-tree.txt +%%PORTDOCS%%%%DOCSDIR%%/internals/http-docs.txt +%%PORTDOCS%%%%DOCSDIR%%/internals/http-parsing.txt +%%PORTDOCS%%%%DOCSDIR%%/internals/naming.txt +%%PORTDOCS%%%%DOCSDIR%%/internals/repartition-be-fe-fi.txt +%%PORTDOCS%%%%DOCSDIR%%/internals/stats-v2.txt +%%PORTDOCS%%%%DOCSDIR%%/internals/stream-sock-states.fig +%%PORTDOCS%%%%DOCSDIR%%/internals/todo.cttproxy +%%PORTDOCS%%%%DOCSDIR%%/lgpl.txt +%%PORTDOCS%%%%DOCSDIR%%/queuing.fig +%%PORTDOCS%%@dirrm %%DOCSDIR%%/internals +%%PORTDOCS%%@dirrm %%DOCSDIR%%/design-thoughts %%PORTDOCS%%@dirrm %%DOCSDIR%% +%%PORTDOCS%%%%EXAMPLESDIR%%/acl-content-sw.cfg +%%PORTDOCS%%%%EXAMPLESDIR%%/auth.cfg +%%PORTDOCS%%%%EXAMPLESDIR%%/build.cfg +%%PORTDOCS%%%%EXAMPLESDIR%%/check +%%PORTDOCS%%%%EXAMPLESDIR%%/check.conf +%%PORTDOCS%%%%EXAMPLESDIR%%/config.rc.haproxy +%%PORTDOCS%%%%EXAMPLESDIR%%/content-sw-sample.cfg +%%PORTDOCS%%%%EXAMPLESDIR%%/cttproxy-src.cfg +%%PORTDOCS%%%%EXAMPLESDIR%%/debug2ansi +%%PORTDOCS%%%%EXAMPLESDIR%%/debug2html +%%PORTDOCS%%%%EXAMPLESDIR%%/debugfind +%%PORTDOCS%%%%EXAMPLESDIR%%/errorfiles/400.http +%%PORTDOCS%%%%EXAMPLESDIR%%/errorfiles/403.http +%%PORTDOCS%%%%EXAMPLESDIR%%/errorfiles/408.http +%%PORTDOCS%%%%EXAMPLESDIR%%/errorfiles/500.http +%%PORTDOCS%%%%EXAMPLESDIR%%/errorfiles/502.http +%%PORTDOCS%%%%EXAMPLESDIR%%/errorfiles/503.http +%%PORTDOCS%%%%EXAMPLESDIR%%/errorfiles/504.http +%%PORTDOCS%%%%EXAMPLESDIR%%/errorfiles/README +%%PORTDOCS%%%%EXAMPLESDIR%%/examples.cfg +%%PORTDOCS%%%%EXAMPLESDIR%%/haproxy-1.1.21-flx.1.pkg +%%PORTDOCS%%%%EXAMPLESDIR%%/haproxy.cfg +%%PORTDOCS%%%%EXAMPLESDIR%%/haproxy.init +%%PORTDOCS%%%%EXAMPLESDIR%%/haproxy.spec +%%PORTDOCS%%%%EXAMPLESDIR%%/haproxy.vim +%%PORTDOCS%%%%EXAMPLESDIR%%/init.haproxy +%%PORTDOCS%%%%EXAMPLESDIR%%/init.haproxy.flx0 +%%PORTDOCS%%%%EXAMPLESDIR%%/linux-2.4.21-40.EL-custom.diff +%%PORTDOCS%%%%EXAMPLESDIR%%/option-http_proxy.cfg +%%PORTDOCS%%%%EXAMPLESDIR%%/rc.highsock +%%PORTDOCS%%%%EXAMPLESDIR%%/stats_haproxy.sh +%%PORTDOCS%%%%EXAMPLESDIR%%/tarpit.cfg +%%PORTDOCS%%%%EXAMPLESDIR%%/test-section-kw.cfg +%%PORTDOCS%%%%EXAMPLESDIR%%/url-switching.cfg +%%PORTDOCS%%@dirrm %%EXAMPLESDIR%%/errorfiles %%PORTDOCS%%@dirrm %%EXAMPLESDIR%% >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201002262139.o1QLd5PF008084>