[133338] trunk/dports/php/php-amqp

ryandesign at macports.org ryandesign at macports.org
Thu Feb 26 09:47:14 PST 2015


Revision: 133338
          https://trac.macports.org/changeset/133338
Author:   ryandesign at macports.org
Date:     2015-02-26 09:47:14 -0800 (Thu, 26 Feb 2015)
Log Message:
-----------
php-amqp: update to 1.6.0beta2 and add patches to fix build failure on OS X and with rabbitmq-c 0.6.0 (#46972)

Modified Paths:
--------------
    trunk/dports/php/php-amqp/Portfile

Added Paths:
-----------
    trunk/dports/php/php-amqp/files/
    trunk/dports/php/php-amqp/files/patch-amqp_exchange.c.diff
    trunk/dports/php/php-amqp/files/patch-duplicate-symbols.diff

Modified: trunk/dports/php/php-amqp/Portfile
===================================================================
--- trunk/dports/php/php-amqp/Portfile	2015-02-26 17:09:46 UTC (rev 133337)
+++ trunk/dports/php/php-amqp/Portfile	2015-02-26 17:47:14 UTC (rev 133338)
@@ -5,7 +5,7 @@
 PortGroup           php 1.1
 
 name                php-amqp
-version             1.4.0
+version             1.6.0beta2
 categories          php net
 platforms           darwin
 maintainers         ryandesign openmaintainer
@@ -13,6 +13,7 @@
 
 php.branches        5.3 5.4 5.5 5.6
 php.pecl            yes
+php.pecl.prerelease yes
 
 description         AMQP interface for PHP
 
@@ -22,9 +23,12 @@
                     and queues, as well as publish to any exchange and \
                     consume from any queue.
 
-checksums           rmd160  8d55af5bc24b45d09aa2c4476b8ee02701f52830 \
-                    sha256  e6553154acbffeaacfad83edf94a7b94e2e50a850ec953d15537016267720f25
+checksums           rmd160  229dba4e5fa0bd6c5e6ea776964812a35b500558 \
+                    sha256  ae897db025f2f493293f08fc09ecd61cef3f4d1d781cf32113bef7a91ab6128c
 
 depends_lib-append  port:rabbitmq-c
 
+patchfiles-append   patch-amqp_exchange.c.diff
+patchfiles-append   patch-duplicate-symbols.diff
+
 configure.args-append --with-amqp --with-librabbitmq-dir=${prefix}

Added: trunk/dports/php/php-amqp/files/patch-amqp_exchange.c.diff
===================================================================
--- trunk/dports/php/php-amqp/files/patch-amqp_exchange.c.diff	                        (rev 0)
+++ trunk/dports/php/php-amqp/files/patch-amqp_exchange.c.diff	2015-02-26 17:47:14 UTC (rev 133338)
@@ -0,0 +1,14 @@
+Fix rabbitmq-c version number interpretation
+https://github.com/pdezwart/php-amqp/pull/153
+https://github.com/pinepain/php-amqp/commit/b954faa9162b91b3a44fd8aa7ae66b862ef9bcd9
+--- amqp_exchange.c.orig
++++ amqp_exchange.c
+@@ -469,7 +469,7 @@ PHP_METHOD(amqp_exchange_class, declareExchange)
+ 
+ 	arguments = convert_zval_to_amqp_table(exchange->arguments TSRMLS_CC);
+ 	
+-#if AMQP_VERSION_MAJOR == 0 && AMQP_VERSION_MINOR >= 5 && AMQP_VERSION_PATCH > 2
++#if AMQP_VERSION_MAJOR * 100 + AMQP_VERSION_MINOR * 10 + AMQP_VERSION_PATCH > 52
+ 	amqp_exchange_declare(
+ 		connection->connection_resource->connection_state,
+ 		channel->channel_id,

Added: trunk/dports/php/php-amqp/files/patch-duplicate-symbols.diff
===================================================================
--- trunk/dports/php/php-amqp/files/patch-duplicate-symbols.diff	                        (rev 0)
+++ trunk/dports/php/php-amqp/files/patch-duplicate-symbols.diff	2015-02-26 17:47:14 UTC (rev 133338)
@@ -0,0 +1,59 @@
+Fix duplicate symbols
+https://github.com/pdezwart/php-amqp/issues/141
+https://github.com/pdezwart/php-amqp/pull/142
+--- amqp_connection.c.orig
++++ amqp_connection.c
+@@ -50,6 +50,7 @@
+ #endif
+ 
+ #include "php_amqp.h"
++#include "amqp_channel.h"
+ #include "amqp_connection_resource.h"
+ 
+ #ifndef E_DEPRECATED
+--- amqp_connection_resource.c.orig
++++ amqp_connection_resource.c
+@@ -57,6 +57,9 @@
+ #define E_DEPRECATED E_WARNING
+ #endif
+ 
++int le_amqp_connection_resource;
++int le_amqp_connection_resource_persistent;
++
+ static void connection_resource_destructor(amqp_connection_resource *resource, int persistent TSRMLS_DC);
+ 
+ 
+--- amqp_connection_resource.h.orig
++++ amqp_connection_resource.h
+@@ -28,8 +28,8 @@
+ #define PHP_AMQP_RESOURCE_RESPONSE_ERROR_CHANNEL_CLOSED    -2
+ #define PHP_AMQP_RESOURCE_RESPONSE_ERROR_CONNECTION_CLOSED -3
+ 
+-int le_amqp_connection_resource;
+-int le_amqp_connection_resource_persistent;
++extern int le_amqp_connection_resource;
++extern int le_amqp_connection_resource_persistent;
+ 
+ /* Figure out what's going on connection and handle protocol exceptions, if any */
+ int php_amqp_connection_resource_error(amqp_rpc_reply_t reply, char **message, amqp_connection_resource *resource, amqp_channel_t channel_id TSRMLS_DC);
+--- php_amqp.h.orig
++++ php_amqp.h
+@@ -311,9 +311,6 @@ extern zend_class_entry *amqp_exception_class_entry,
+ 		} while (0);
+ #endif
+ 
+-extern int le_amqp_connection_resource;
+-extern int le_amqp_connection_resource_persistent;
+-
+ typedef struct _amqp_channel_object {
+ 	zend_object zo;
+ 	zval *connection;
+@@ -432,7 +429,7 @@ typedef struct _amqp_envelope_object {
+ #endif
+ 
+ void php_amqp_error(amqp_rpc_reply_t reply, char **message, amqp_connection_object *connection, amqp_channel_object *channel TSRMLS_DC);
+-void amqp_exception(amqp_rpc_reply_t reply, zend_class_entry *exception_ce, const char *message, long code TSRMLS_DC);
++void php_amqp_zend_throw_exception(amqp_rpc_reply_t reply, zend_class_entry *exception_ce, const char *message, long code TSRMLS_DC);
+ 
+ void php_amqp_maybe_release_buffers_on_channel(amqp_connection_object *connection, amqp_channel_object *channel);
+ 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20150226/b78d142d/attachment.html>


More information about the macports-changes mailing list