From 7fe96c109332ecdb411ceef911efd11085a88346 Mon Sep 17 00:00:00 2001 From: Alex Dupre Date: Mon, 24 Jun 2013 14:32:11 +0000 Subject: Welcome PHP 5.5! Future steps: - rename current php5 ports to php54 - make php55 the default one after an exp-run --- databases/php55-pgsql/Makefile | 10 ++++++++++ databases/php55-pgsql/files/patch-pgsql.c | 30 ++++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 databases/php55-pgsql/Makefile create mode 100644 databases/php55-pgsql/files/patch-pgsql.c (limited to 'databases/php55-pgsql') diff --git a/databases/php55-pgsql/Makefile b/databases/php55-pgsql/Makefile new file mode 100644 index 000000000000..b6223ec6191f --- /dev/null +++ b/databases/php55-pgsql/Makefile @@ -0,0 +1,10 @@ +# Created by: Alex Dupre +# $FreeBSD$ + +CATEGORIES= databases + +MASTERDIR= ${.CURDIR}/../../lang/php55 + +PKGNAMESUFFIX= -pgsql + +.include "${MASTERDIR}/Makefile" diff --git a/databases/php55-pgsql/files/patch-pgsql.c b/databases/php55-pgsql/files/patch-pgsql.c new file mode 100644 index 000000000000..a4abfc39dff3 --- /dev/null +++ b/databases/php55-pgsql/files/patch-pgsql.c @@ -0,0 +1,30 @@ +--- pgsql.c.orig 2010-01-03 10:23:27.000000000 +0100 ++++ pgsql.c 2010-03-08 11:00:26.000000000 +0100 +@@ -63,6 +63,7 @@ + #define PGSQL_MAX_LENGTH_OF_LONG 30 + #define PGSQL_MAX_LENGTH_OF_DOUBLE 60 + ++#if UINT_MAX > LONG_MAX + #define PGSQL_RETURN_OID(oid) do { \ + if (oid > LONG_MAX) { \ + smart_str s = {0}; \ +@@ -72,7 +73,9 @@ + } \ + RETURN_LONG((long)oid); \ + } while(0) +- ++#else ++#define PGSQL_RETURN_OID(oid) RETURN_LONG((long)oid) ++#endif + + #if HAVE_PQSETNONBLOCKING + #define PQ_SETNONBLOCKING(pg_link, flag) PQsetnonblocking(pg_link, flag) +@@ -728,7 +731,7 @@ + static int le_link, le_plink, le_result, le_lofp, le_string; + + /* {{{ _php_pgsql_trim_message */ +-static char * _php_pgsql_trim_message(const char *message, int *len) ++static char * _php_pgsql_trim_message(const char *message, size_t *len) + { + register int i = strlen(message)-1; + -- cgit v1.2.3