summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuli Suominen <ssuominen@gentoo.org>2012-05-19 08:18:40 +0000
committerSamuli Suominen <ssuominen@gentoo.org>2012-05-19 08:18:40 +0000
commitdb36dedb97107622b5460e99076ed28949e72a7c (patch)
tree95e7ddc117630bd9309e4f4f3fab41d5ca72d1cc /app-pda/libimobiledevice
parentRemove old wrt bug #311481. (diff)
downloadgentoo-2-db36dedb97107622b5460e99076ed28949e72a7c.tar.gz
gentoo-2-db36dedb97107622b5460e99076ed28949e72a7c.tar.bz2
gentoo-2-db36dedb97107622b5460e99076ed28949e72a7c.zip
Fix compability with dev-python/cython >= 0.16 wrt #414063
(Portage version: 2.2.0_alpha107/cvs/Linux x86_64)
Diffstat (limited to 'app-pda/libimobiledevice')
-rw-r--r--app-pda/libimobiledevice/ChangeLog10
-rw-r--r--app-pda/libimobiledevice/files/libimobiledevice-1.1.4-cython.patch131
-rw-r--r--app-pda/libimobiledevice/libimobiledevice-1.1.4-r1.ebuild62
3 files changed, 202 insertions, 1 deletions
diff --git a/app-pda/libimobiledevice/ChangeLog b/app-pda/libimobiledevice/ChangeLog
index efb148b007fd..a85abc5d793a 100644
--- a/app-pda/libimobiledevice/ChangeLog
+++ b/app-pda/libimobiledevice/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for app-pda/libimobiledevice
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-pda/libimobiledevice/ChangeLog,v 1.29 2012/05/16 00:48:36 ssuominen Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-pda/libimobiledevice/ChangeLog,v 1.30 2012/05/19 08:18:40 ssuominen Exp $
+
+*libimobiledevice-1.1.4-r1 (19 May 2012)
+
+ 19 May 2012; Samuli Suominen <ssuominen@gentoo.org>
+ +libimobiledevice-1.1.4-r1.ebuild,
+ +files/libimobiledevice-1.1.4-cython.patch:
+ Fix compability with dev-python/cython >= 0.16 wrt #414063 by Frédéric
+ Romagné, Mattia Rossi and Steve Arnold
16 May 2012; Samuli Suominen <ssuominen@gentoo.org>
libimobiledevice-1.1.4.ebuild, +files/libimobiledevice-1.1.4-openssl.patch:
diff --git a/app-pda/libimobiledevice/files/libimobiledevice-1.1.4-cython.patch b/app-pda/libimobiledevice/files/libimobiledevice-1.1.4-cython.patch
new file mode 100644
index 000000000000..d1f351d5928b
--- /dev/null
+++ b/app-pda/libimobiledevice/files/libimobiledevice-1.1.4-cython.patch
@@ -0,0 +1,131 @@
+http://bugs.gentoo.org/414063
+
+http://cgit.sukimashita.com/libimobiledevice.git/commit/?id=70dfe8ad1766990386f1db04bbe5a4826bcde4e5
+http://cgit.sukimashita.com/libimobiledevice.git/commit/?id=84235e0834e57551028329723f4510e1dbe7bc11
+http://cgit.sukimashita.com/libimobiledevice.git/commit/?id=849ea066426b8f5f6e6d1aea9804e095edca3b49
+
+--- configure.ac
++++ configure.ac
+@@ -83,10 +83,20 @@
+ CYTHON=false
+ fi
+ if [test "x$CYTHON" != "xfalse"]; then
+- CYTHON_SUB=cython
++ AC_MSG_CHECKING([for libplist Cython bindings])
+ CYTHON_PLIST_INCLUDE_DIR=$($PKG_CONFIG --variable=includedir libplist)/plist/cython
+- AC_SUBST([CYTHON_PLIST_INCLUDE_DIR])
+- cython_python_bindings=yes
++ if [test ! -d "$CYTHON_PLIST_INCLUDE_DIR"]; then
++ CYTHON=false
++ CYTHON_SUB=
++ cython_python_bindings=no
++ AC_MSG_RESULT([no])
++ AC_MSG_WARN([cannot find libplist Cython bindings. You should install your distribution specific libplist Cython bindings package.])
++ else
++ AC_SUBST([CYTHON_PLIST_INCLUDE_DIR])
++ AC_MSG_RESULT([$CYTHON_PLIST_INCLUDE_DIR])
++ CYTHON_SUB=cython
++ cython_python_bindings=yes
++ fi
+ else
+ CYTHON_SUB=
+ cython_python_bindings=no
+--- cython/afc.pxi
++++ cython/afc.pxi
+@@ -162,7 +162,7 @@
+ err = afc_client_free(self._c_client)
+ self.handle_error(err)
+
+- cdef inline BaseError _error(self, int16_t ret):
++ cdef BaseError _error(self, int16_t ret):
+ return AfcError(ret)
+
+ cpdef list get_device_info(self):
+--- cython/imobiledevice.pxd
++++ cython/imobiledevice.pxd
+@@ -51,8 +51,8 @@
+ cdef class PropertyListService(BaseService):
+ cpdef send(self, plist.Node node)
+ cpdef object receive(self)
+- cdef inline int16_t _send(self, plist.plist_t node)
+- cdef inline int16_t _receive(self, plist.plist_t* c_node)
++ cdef int16_t _send(self, plist.plist_t node)
++ cdef int16_t _receive(self, plist.plist_t* c_node)
+
+ cdef extern from "libimobiledevice/lockdown.h":
+ cdef struct lockdownd_client_private:
+--- cython/imobiledevice.pyx
++++ cython/imobiledevice.pyx
+@@ -25,9 +25,8 @@
+ return 0
+ cdef BaseError err = self._error(ret)
+ raise err
+- return -1
+
+- cdef inline BaseError _error(self, int16_t ret): pass
++ cdef BaseError _error(self, int16_t ret): pass
+
+ cdef extern from "libimobiledevice/libimobiledevice.h":
+ ctypedef enum idevice_error_t:
+@@ -211,10 +210,10 @@
+ plist.plist_free(c_node)
+ raise
+
+- cdef inline int16_t _send(self, plist.plist_t node):
++ cdef int16_t _send(self, plist.plist_t node):
+ raise NotImplementedError("send is not implemented")
+
+- cdef inline int16_t _receive(self, plist.plist_t* c_node):
++ cdef int16_t _receive(self, plist.plist_t* c_node):
+ raise NotImplementedError("receive is not implemented")
+
+ cdef class DeviceLinkService(PropertyListService):
+--- cython/mobilesync.pxi
++++ cython/mobilesync.pxi
+@@ -149,10 +149,10 @@
+ plist.plist_free(remapping)
+ raise
+
+- cdef inline int16_t _send(self, plist.plist_t node):
++ cdef int16_t _send(self, plist.plist_t node):
+ return mobilesync_send(self._c_client, node)
+
+- cdef inline int16_t _receive(self, plist.plist_t* node):
++ cdef int16_t _receive(self, plist.plist_t* node):
+ return mobilesync_receive(self._c_client, node)
+
+ cdef inline BaseError _error(self, int16_t ret):
+--- m4/ac_pkg_cython.m4
++++ m4/ac_pkg_cython.m4
+@@ -6,8 +6,11 @@
+ CYTHON=false
+ elif test -n "$1" ; then
+ AC_MSG_CHECKING([for Cython version])
+- [cython_version=`$CYTHON --version 2>&1 | grep 'Cython version' | sed 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/g'`]
++ [cython_version=`$CYTHON --version 2>&1 | sed 's/Cython version \(.*\)$/\1/g'`]
+ AC_MSG_RESULT([$cython_version])
++
++ # Setup extra version string for parsing
++ [cython_version_stripped=`echo $cython_version | sed 's/\([0-9]\+\)\.\([0-9]\+\)[^\.]*\(\.\([0-9]\+\)\)\?.*/0\1.0\2.0\4/g'`]
+ if test -n "$cython_version" ; then
+ # Calculate the required version number components
+ [required=$1]
+@@ -25,8 +28,9 @@
+ if test -z "$required_patch" ; then
+ [required_patch=0]
+ fi
++
+ # Calculate the available version number components
+- [available=$cython_version]
++ [available=$cython_version_stripped]
+ [available_major=`echo $available | sed 's/[^0-9].*//'`]
+ if test -z "$available_major" ; then
+ [available_major=0]
+@@ -41,6 +45,7 @@
+ if test -z "$available_patch" ; then
+ [available_patch=0]
+ fi
++
+ if test $available_major -gt $required_major || \
+ ( test $available_major -eq $required_major && \
+ test $available_minor -gt $required_minor ) || \
diff --git a/app-pda/libimobiledevice/libimobiledevice-1.1.4-r1.ebuild b/app-pda/libimobiledevice/libimobiledevice-1.1.4-r1.ebuild
new file mode 100644
index 000000000000..b8d83dccd5b2
--- /dev/null
+++ b/app-pda/libimobiledevice/libimobiledevice-1.1.4-r1.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-pda/libimobiledevice/libimobiledevice-1.1.4-r1.ebuild,v 1.1 2012/05/19 08:18:40 ssuominen Exp $
+
+EAPI=4
+PYTHON_DEPEND="python? 2:2.7"
+inherit autotools eutils python
+
+DESCRIPTION="Support library to communicate with Apple iPhone/iPod Touch devices"
+HOMEPAGE="http://www.libimobiledevice.org/"
+SRC_URI="http://www.libimobiledevice.org/downloads/${P}.tar.bz2"
+
+LICENSE="GPL-2 LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc64 ~x86"
+IUSE="gnutls python"
+
+RDEPEND=">=app-pda/libplist-1.8-r1[python?]
+ >=app-pda/usbmuxd-1.0.8
+ gnutls? (
+ dev-libs/libgcrypt
+ >=dev-libs/libtasn1-1.1
+ >=net-libs/gnutls-2.2.0
+ )
+ !gnutls? ( dev-libs/openssl:0 )"
+DEPEND="${RDEPEND}
+ virtual/pkgconfig
+ python? ( >=dev-python/cython-0.14.1-r1 )"
+
+DOCS="AUTHORS NEWS README"
+
+pkg_setup() {
+ if use python; then
+ python_set_active_version 2
+ python_pkg_setup
+ fi
+}
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/${P}-cython.patch \
+ "${FILESDIR}"/${P}-openssl.patch
+
+ eautoreconf
+
+ >py-compile
+}
+
+src_configure() {
+ local myconf='--disable-static'
+ use python || myconf+=' --without-cython'
+ use gnutls && myconf+=' --disable-openssl'
+
+ econf ${myconf}
+}
+
+src_install() {
+ default
+ dohtml docs/html/*
+
+ find "${ED}" -name '*.la' -exec rm -f {} +
+}