[87959] trunk/dports/net/haproxy

ryandesign at macports.org ryandesign at macports.org
Tue Dec 13 22:20:34 PST 2011


Revision: 87959
          http://trac.macports.org/changeset/87959
Author:   ryandesign at macports.org
Date:     2011-12-13 22:20:34 -0800 (Tue, 13 Dec 2011)
Log Message:
-----------
haproxy:

 * Make the universal variant work right and respect build_arch
 * Ensure we're UsingTheRightCompiler
 * Add dependency on and enable use of PCRE, which the Makefile says is recommended
 * Enable the use of libcrypt, which the Makefile says is recommended
 * Enable regparm optimization on Intel processors, which the Makefile says it is recommended
 * Fix the livecheck
 * Indicate GPL-2+ license
 * Simplify how the documentation and other files are installed
 * Introduce the branch variable in master_sites

See #32438 (maintainer timeout)

Modified Paths:
--------------
    trunk/dports/net/haproxy/Portfile

Added Paths:
-----------
    trunk/dports/net/haproxy/files/
    trunk/dports/net/haproxy/files/patch-Makefile.diff

Modified: trunk/dports/net/haproxy/Portfile
===================================================================
--- trunk/dports/net/haproxy/Portfile	2011-12-14 05:19:33 UTC (rev 87958)
+++ trunk/dports/net/haproxy/Portfile	2011-12-14 06:20:34 UTC (rev 87959)
@@ -4,9 +4,13 @@
 
 name              haproxy
 version           1.4.18
+set branch          [join [lrange [split ${version} .] 0 1] .]
+revision            1
 categories        net
 platforms         darwin
 maintainers       samgranieri.com:sam
+license             GPL-2+
+
 description       The Reliable, High Performance TCP/HTTP Load Balancer
 
 long_description  HAproxy is a high-performance and highly-robust TCP/HTTP \
@@ -18,20 +22,32 @@
                   per second on modern hardware, even with thousands simultaneous connections.
 
 homepage          http://haproxy.1wt.eu/
-master_sites      http://haproxy.1wt.eu/download/1.4/src/
+master_sites        ${homepage}download/${branch}/src/
 
 checksums         md5     4ac88bb1a76c4b84ed4f6131183bedbe \
                   sha1    191dbcb5880c711580693bd081ca5fdd8dde3012 \
                   rmd160  16729f0519a47123d88e849ae95d600c590c8583
 
-configure  {
-  reinplace "s#/usr/local#${prefix}#g" ${worksrcpath}/Makefile
-}
+depends_lib         port:pcre
 
+patchfiles          patch-Makefile.diff
+
+use_configure       no
+
+variant universal {}
+
 build.target TARGET=osx
 
-post-destroot  {
-  set docdir ${destroot}${prefix}/share/doc
-  # xinstall -d ${docdir}
-  file rename ${destroot}${prefix}/doc ${docdir}
+build.args          CC="${configure.cc} [get_canonical_archflags]" \
+                    USE_LIBCRYPT=1 \
+                    USE_PCRE=1
+
+destroot.args       DOCDIR=${prefix}/share/doc/${name} \
+                    PREFIX=${prefix}
+
+platform i386 {
+    build.args-append USE_REGPARM=1
 }
+
+livecheck.type      regex
+livecheck.regex     {>Stable ([0-9.]+)<}

Added: trunk/dports/net/haproxy/files/patch-Makefile.diff
===================================================================
--- trunk/dports/net/haproxy/files/patch-Makefile.diff	                        (rev 0)
+++ trunk/dports/net/haproxy/files/patch-Makefile.diff	2011-12-14 06:20:34 UTC (rev 87959)
@@ -0,0 +1,12 @@
+--- Makefile.orig	2011-09-16 08:02:05.000000000 -0500
++++ Makefile	2011-12-06 19:01:17.000000000 -0600
+@@ -345,7 +345,9 @@
+ ifneq ($(USE_LIBCRYPT),)
+ OPTIONS_CFLAGS  += -DCONFIG_HAP_CRYPT
+ BUILD_OPTIONS   += $(call ignore_implicit,USE_LIBCRYPT)
++ifneq ($(shell uname -s),Darwin)
+ OPTIONS_LDFLAGS += -lcrypt
++endif
+ endif
+ 
+ ifneq ($(USE_CRYPT_H),)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20111213/3cae09ee/attachment-0001.html>


More information about the macports-changes mailing list