[Python-checkins] cpython (3.4): - Issue #22176: Fix build failure on ARM with

matthias.klose python-checkins at python.org
Sun Aug 10 00:01:50 CEST 2014


http://hg.python.org/cpython/rev/4d3f960c26f5
changeset:   92054:4d3f960c26f5
branch:      3.4
parent:      92052:269ec4c568bd
user:        doko at ubuntu.com
date:        Sun Aug 10 00:01:04 2014 +0200
summary:
   - Issue #22176: Fix build failure on ARM with -Werror=declaration-after-statement

files:
  Modules/_ctypes/libffi.diff          |  23 ++++++++++++++++
  Modules/_ctypes/libffi/src/arm/ffi.c |   6 ++--
  2 files changed, 26 insertions(+), 3 deletions(-)


diff --git a/Modules/_ctypes/libffi.diff b/Modules/_ctypes/libffi.diff
--- a/Modules/_ctypes/libffi.diff
+++ b/Modules/_ctypes/libffi.diff
@@ -184,3 +184,26 @@
      set_lock(m, locked);
    }
    return (mspace)m;
+diff -urN libffi-3.1/src/arm/ffi.c libffi/src/arm/ffi.c
+--- libffi-3.1/src/arm/ffi.c	Sat Aug 09 23:52:34 2014 +0200
++++ libffi/src/arm/ffi.c	Sat Aug 09 23:58:38 2014 +0200
+@@ -154,9 +154,6 @@
+ 
+ int ffi_prep_args_VFP(char *stack, extended_cif *ecif, float *vfp_space)
+ {
+-  // make sure we are using FFI_VFP
+-  FFI_ASSERT(ecif->cif->abi == FFI_VFP);
+-
+   register unsigned int i, vi = 0;
+   register void **p_argv;
+   register char *argp, *regp, *eo_regp;
+@@ -165,6 +162,9 @@
+   char done_with_regs = 0;
+   char is_vfp_type;
+ 
++  // make sure we are using FFI_VFP
++  FFI_ASSERT(ecif->cif->abi == FFI_VFP);
++
+   /* the first 4 words on the stack are used for values passed in core
+    * registers. */
+   regp = stack;
diff --git a/Modules/_ctypes/libffi/src/arm/ffi.c b/Modules/_ctypes/libffi/src/arm/ffi.c
--- a/Modules/_ctypes/libffi/src/arm/ffi.c
+++ b/Modules/_ctypes/libffi/src/arm/ffi.c
@@ -154,9 +154,6 @@
 
 int ffi_prep_args_VFP(char *stack, extended_cif *ecif, float *vfp_space)
 {
-  // make sure we are using FFI_VFP
-  FFI_ASSERT(ecif->cif->abi == FFI_VFP);
-
   register unsigned int i, vi = 0;
   register void **p_argv;
   register char *argp, *regp, *eo_regp;
@@ -165,6 +162,9 @@
   char done_with_regs = 0;
   char is_vfp_type;
 
+  // make sure we are using FFI_VFP
+  FFI_ASSERT(ecif->cif->abi == FFI_VFP);
+
   /* the first 4 words on the stack are used for values passed in core
    * registers. */
   regp = stack;

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list