[arch-commits] Commit in python-cffi/trunk (PKGBUILD gcc-5.1.patch rebuild.list)
Felix Yan
fyan at archlinux.org
Tue May 26 09:36:38 UTC 2015
Date: Tuesday, May 26, 2015 @ 11:36:38
Author: fyan
Revision: 239760
upgpkg: python-cffi 1.0.3-1
Added:
python-cffi/trunk/gcc-5.1.patch
python-cffi/trunk/rebuild.list
Modified:
python-cffi/trunk/PKGBUILD
---------------+
PKGBUILD | 11 ++++++++---
gcc-5.1.patch | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
rebuild.list | 1 +
3 files changed, 64 insertions(+), 3 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2015-05-26 06:33:03 UTC (rev 239759)
+++ PKGBUILD 2015-05-26 09:36:38 UTC (rev 239760)
@@ -5,7 +5,7 @@
_name=cffi
pkgbase=python-$_name
pkgname=(python-$_name python2-$_name)
-pkgver=1.0.1
+pkgver=1.0.3
pkgrel=1
pkgdesc="Foreign Function Interface for Python calling C code"
arch=('i686' 'x86_64')
@@ -13,10 +13,15 @@
license=('MIT')
makedepends=('python-setuptools' 'python2-setuptools' 'python-pycparser' 'python2-pycparser')
checkdepends=('python-pytest' 'python2-pytest')
-source=("https://pypi.python.org/packages/source/c/${_name}/${_name}-${pkgver}.tar.gz")
-sha512sums=('7ab5fc6753e36bd04efb5dd99a852ff670a25a7b3cb57cb2bd153948a24ac2d98092e8eb35218867b96a559e6a3ef0f6669e616db4c883a0c297bcda3b3692b8')
+source=("https://pypi.python.org/packages/source/c/${_name}/${_name}-$pkgver.tar.gz"
+ gcc-5.1.patch)
+sha512sums=('a5f2b0ab356fe51b1d9f3f2e4bfadbc11bb10ec7f9458c019f3707b738dded1953723f797a8b37ed768cd14fe86f674d07d2cd5ce166406abaa1a68b443293b1'
+ '5dec42879a0ec443d6546594f4f78803b2aa83a5c02916864dca1c8c7c86bb69ee04269d5bce07ccfce750c7500acdc2fc037019e181321dfb7bf539bf74b91e')
prepare() {
+ # https://bitbucket.org/cffi/cffi/issue/195/test-failures-with-cffi-102
+ (cd $_name-$pkgver; patch -p1 -i ../gcc-5.1.patch)
+
cp -a $_name-$pkgver{,-py2}
}
Added: gcc-5.1.patch
===================================================================
--- gcc-5.1.patch (rev 0)
+++ gcc-5.1.patch 2015-05-26 09:36:38 UTC (rev 239760)
@@ -0,0 +1,55 @@
+# HG changeset patch
+# User Armin Rigo <arigo at tunes.org>
+# Date 1432628446 -7200
+# Node ID 588e46d0032954479cb62db1784d554c0b4d6107
+# Parent 4e69fd3efc25128d62eef5eea8a52fbfea166ebf
+Silence some warnings with gcc 5.1: if T is a type smaller than 'int',
+then the C expression "condition ? (T)x : (T)y" is typed not as a T, but
+as a larger 'int' --- which means there was an implicit cast from the
+final 'int' to the T-typed target of the assignment whenever this macro
+was used.
+
+diff --git a/cffi/_cffi_include.h b/cffi/_cffi_include.h
+--- a/cffi/_cffi_include.h
++++ b/cffi/_cffi_include.h
+@@ -82,7 +82,8 @@
+ PyLong_FromLongLong((long long)x)))
+
+ #define _cffi_to_c_int(o, type) \
+- (sizeof(type) == 1 ? (((type)-1) > 0 ? (type)_cffi_to_c_u8(o) \
++ ((type)( \
++ sizeof(type) == 1 ? (((type)-1) > 0 ? (type)_cffi_to_c_u8(o) \
+ : (type)_cffi_to_c_i8(o)) : \
+ sizeof(type) == 2 ? (((type)-1) > 0 ? (type)_cffi_to_c_u16(o) \
+ : (type)_cffi_to_c_i16(o)) : \
+@@ -90,7 +91,7 @@
+ : (type)_cffi_to_c_i32(o)) : \
+ sizeof(type) == 8 ? (((type)-1) > 0 ? (type)_cffi_to_c_u64(o) \
+ : (type)_cffi_to_c_i64(o)) : \
+- (Py_FatalError("unsupported size for type " #type), (type)0))
++ (Py_FatalError("unsupported size for type " #type), (type)0)))
+
+ #define _cffi_to_c_i8 \
+ ((int(*)(PyObject *))_cffi_exports[1])
+diff --git a/cffi/vengine_cpy.py b/cffi/vengine_cpy.py
+--- a/cffi/vengine_cpy.py
++++ b/cffi/vengine_cpy.py
+@@ -886,7 +886,8 @@
+ PyLong_FromLongLong((long long)x)))
+
+ #define _cffi_to_c_int(o, type) \
+- (sizeof(type) == 1 ? (((type)-1) > 0 ? (type)_cffi_to_c_u8(o) \
++ ((type)( \
++ sizeof(type) == 1 ? (((type)-1) > 0 ? (type)_cffi_to_c_u8(o) \
+ : (type)_cffi_to_c_i8(o)) : \
+ sizeof(type) == 2 ? (((type)-1) > 0 ? (type)_cffi_to_c_u16(o) \
+ : (type)_cffi_to_c_i16(o)) : \
+@@ -894,7 +895,7 @@
+ : (type)_cffi_to_c_i32(o)) : \
+ sizeof(type) == 8 ? (((type)-1) > 0 ? (type)_cffi_to_c_u64(o) \
+ : (type)_cffi_to_c_i64(o)) : \
+- (Py_FatalError("unsupported size for type " #type), (type)0))
++ (Py_FatalError("unsupported size for type " #type), (type)0)))
+
+ #define _cffi_to_c_i8 \
+ ((int(*)(PyObject *))_cffi_exports[1])
Added: rebuild.list
===================================================================
--- rebuild.list (rev 0)
+++ rebuild.list 2015-05-26 09:36:38 UTC (rev 239760)
@@ -0,0 +1 @@
+python-pygit2
More information about the arch-commits
mailing list