components/python/librabbitmq/patches/studio.patch
author david.comay@oracle.com
Thu, 25 Aug 2016 22:11:53 -0700
changeset 6701 8f6824af31fa
permissions -rw-r--r--
24414799 Apache core dumps with Kilo Keystone in B104
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
6701
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
     1
Adjust definition of _PYRMQ_INLINE and _AMQP_INLINE to prevent
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
     2
E_REF_STATIC_EXTERN_INLINE warnings.
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
     3
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
     4
Remove the testing and use of GCC-specific flags.
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
     5
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
     6
Correct use of pointer arithmetic to prevent
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
     7
E_PTR_TO_VOID_IN_ARITHMETIC warnings.
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
     8
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
     9
Don't regenerate amqp_framing.[ch] if the source hasn't changed.
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    10
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    11
Finally, we inherit CFLAGS and LDFLAGS from the environment rather than
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    12
using what Python was compiled with. In particular, Python 2.7 in
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    13
Userland currently has some undesired settings such as including
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    14
/usr/gnu/lib in the RUNPATH.
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    15
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    16
--- librabbitmq-1.6.1/Modules/_librabbitmq/connection.h.~2~	2016-08-25 14:50:58.820215166 -0700
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    17
+++ librabbitmq-1.6.1/Modules/_librabbitmq/connection.h	2016-08-25 14:50:58.885646596 -0700
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    18
@@ -44,6 +44,8 @@
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    19
 #  define _PYRMQ_INLINE
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    20
 # elif defined(__GNUC__) && !defined(__GNUC_STDC_INLINE__)
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    21
 #  define _PYRMQ_INLINE extern __inline
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    22
+# elif defined(__SUNPRO_C)
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    23
+#  define _PYRMQ_INLINE static __inline
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    24
 # else
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    25
 #  define _PYRMQ_INLINE __inline
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    26
 # endif
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    27
@@ -146,7 +148,7 @@ typedef struct {
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    28
     PyObject *weakreflist;
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    29
 } PyRabbitMQ_Connection;
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    30
 
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    31
-int
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    32
+_PYRMQ_INLINE int
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    33
 PyDict_to_basic_properties(PyObject *, amqp_basic_properties_t *,
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    34
                            amqp_connection_state_t, amqp_pool_t *);
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    35
 
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    36
--- librabbitmq-1.6.1/clib/configure.~1~	2014-10-24 04:36:46.000000000 -0700
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    37
+++ librabbitmq-1.6.1/clib/configure	2016-08-25 14:50:58.890629993 -0700
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    38
@@ -12432,79 +12432,6 @@ fi
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    39
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    40
 
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    41
 
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    42
-_ax_cflags=$CFLAGS
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    43
-CFLAGS="-fno-common $CFLAGS"
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    44
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts '-fno-common'" >&5
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    45
-$as_echo_n "checking if compiler accepts '-fno-common'... " >&6; }
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    46
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    47
-/* end confdefs.h.  */
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    48
-
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    49
-int
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    50
-main ()
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    51
-{
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    52
-
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    53
-  ;
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    54
-  return 0;
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    55
-}
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    56
-_ACEOF
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    57
-if ac_fn_c_try_compile "$LINENO"; then :
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    58
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    59
-$as_echo "yes" >&6; }
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    60
-		CFLAGS=$_ax_cflags
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    61
-		case " $CFLAGS " in #(
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    62
-  *[\ \	]-fno-common[\ \	]*) :
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    63
-     ;; #(
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    64
-  *) :
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    65
-    CFLAGS="$CFLAGS -fno-common" ;; #(
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    66
-  *) :
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    67
-     ;;
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    68
-esac
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    69
-
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    70
-else
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    71
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    72
-$as_echo "no" >&6; }
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    73
-		CFLAGS=$_ax_cflags
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    74
-
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    75
-fi
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    76
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    77
-
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    78
-
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    79
-_ax_cflags=$CFLAGS
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    80
-CFLAGS="-fvisibility=hidden $CFLAGS"
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    81
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts '-fvisibility=hidden'" >&5
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    82
-$as_echo_n "checking if compiler accepts '-fvisibility=hidden'... " >&6; }
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    83
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    84
-/* end confdefs.h.  */
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    85
-
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    86
-int
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    87
-main ()
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    88
-{
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    89
-
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    90
-  ;
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    91
-  return 0;
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    92
-}
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    93
-_ACEOF
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    94
-if ac_fn_c_try_compile "$LINENO"; then :
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    95
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    96
-$as_echo "yes" >&6; }
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    97
-		CFLAGS=$_ax_cflags
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    98
-		case " $CFLAGS " in #(
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
    99
-  *[\ \	]-fvisibility=hidden[\ \	]*) :
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   100
-     ;; #(
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   101
-  *) :
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   102
-    CFLAGS="$CFLAGS -fvisibility=hidden" ;; #(
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   103
-  *) :
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   104
-     ;;
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   105
-esac
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   106
-
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   107
-else
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   108
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   109
-$as_echo "no" >&6; }
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   110
-		CFLAGS=$_ax_cflags
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   111
-
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   112
-fi
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   113
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   114
-
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   115
 _ax_ldflags=$LDFLAGS
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   116
 LDFLAGS="-no-undefined $LDFLAGS"
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   117
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker accepts '-no-undefined'" >&5
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   118
--- librabbitmq-1.6.1/clib/librabbitmq/amqp_private.h.~1~	2014-10-24 04:36:40.000000000 -0700
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   119
+++ librabbitmq-1.6.1/clib/librabbitmq/amqp_private.h	2016-08-25 14:52:09.507960376 -0700
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   120
@@ -57,6 +57,8 @@
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   121
 #  define _AMQP_INLINE static
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   122
 # elif defined(__GNUC__) && !defined(__GNUC_STDC_INLINE__)
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   123
 #  define _AMQP_INLINE extern __inline
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   124
+# elif defined(__SUNPRO_C)
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   125
+#  define _AMQP_INLINE static __inline
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   126
 # else
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   127
 #  define _AMQP_INLINE __inline
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   128
 # endif
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   129
--- librabbitmq-1.6.1/clib/librabbitmq/amqp_tcp_socket.c.~1~	2014-10-24 04:36:40.000000000 -0700
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   130
+++ librabbitmq-1.6.1/clib/librabbitmq/amqp_tcp_socket.c	2016-08-25 14:50:58.892307461 -0700
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   131
@@ -186,7 +186,7 @@ start:
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   132
   bufferp = self->buffer;
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   133
   for (i = 0; i < iovcnt; ++i) {
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   134
     memcpy(bufferp, iov[i].iov_base, iov[i].iov_len);
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   135
-    bufferp += iov[i].iov_len;
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   136
+    bufferp = (void *)((uintptr_t)bufferp + iov[i].iov_len);
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   137
   }
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   138
 
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   139
   ret = amqp_tcp_socket_send_inner(self, self->buffer, bytes, 0);
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   140
--- librabbitmq-1.6.1/setup.py.~1~	2014-11-17 06:43:15.000000000 -0800
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   141
+++ librabbitmq-1.6.1/setup.py	2016-08-25 14:50:58.893190143 -0700
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   142
@@ -2,6 +2,7 @@ import os
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   143
 import platform
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   144
 import sys
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   145
 from setuptools import setup, find_packages
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   146
+from distutils.dep_util import newer
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   147
 
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   148
 # --with-librabbitmq=<dir>: path to librabbitmq package if needed
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   149
 
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   150
@@ -24,9 +25,16 @@ def codegen():
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   151
     codegen = LRMQSRC('codegen.py')
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   152
     spec = SPECPATH('amqp-rabbitmq-0.9.1.json')
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   153
     sys.path.insert(0, SPECPATH())
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   154
+    hfile = LRMQSRC('amqp_framing.h')
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   155
+    cfile = LRMQSRC('amqp_framing.c')
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   156
+    # Don't regenerate the files if the spec file hasn't changed.  This
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   157
+    # prevents a separate install phase from unnecessarily rebuilding the
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   158
+    # extension.
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   159
+    if not (newer(spec, hfile) or newer(spec, cfile)):
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   160
+            return
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   161
     commands = [
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   162
-        (sys.executable, codegen, 'header', spec, LRMQSRC('amqp_framing.h')),
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   163
-        (sys.executable, codegen, 'body', spec, LRMQSRC('amqp_framing.c')),
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   164
+        (sys.executable, codegen, 'header', spec, hfile),
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   165
+        (sys.executable, codegen, 'body', spec, cfile),
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   166
     ]
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   167
     restore = senv(('PYTHONPATH', SPECPATH()), sep=':')
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   168
     try:
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   169
@@ -133,10 +141,7 @@ def create_builder():
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   170
                     vars[key] = vars[key].replace(
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   171
                         '-isysroot /Developer/SDKs/MacOSX10.6.sdk', '')
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   172
                     vars[key] = vars[key].replace('-Wall', '')
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   173
-                restore = senv(
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   174
-                    ('CFLAGS', vars['c']),
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   175
-                    ('LDFLAGS', vars['ld']),
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   176
-                )
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   177
+                restore = senv()
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   178
                 try:
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   179
                     os.chdir(LRMQDIST())
8f6824af31fa 24414799 Apache core dumps with Kilo Keystone in B104
david.comay@oracle.com
parents:
diff changeset
   180
                     if not os.path.isfile('config.h'):