debian/0000775000000000000000000000000012316332564007175 5ustar debian/source/0000775000000000000000000000000012262511221010462 5ustar debian/source/format0000664000000000000000000000001411455275705011711 0ustar 3.0 (quilt) debian/copyright0000664000000000000000000001232712262510015011122 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: pyzmq Upstream-Contact: Min Ragan-Kelley Source: https://github.com/zeromq/pyzmq/downloads Files: * Copyright: 2010-2012, Brian Granger 2010-2013, Min Ragan-Kelley 2013 Felipe Cruz License: BSD-3-clause Files: examples/mongodb/* Copyright: 2010, Justin Riley License: BSD-3-clause Files: examples/chat/* Copyright: 2010, Andrew Gwozdziewycz License: LGPL-3 Files: examples/device/client.py examples/device/server.py Copyright: 2010, Brian E. Granger 2010, Eugene Chernyshov License: LGPL-3 Files: zmq/backends/cython Copyright: 2010-2011, Brian E. Granger 2010, Andrew Gwozdziewycz 2010, Fernando Perez 2011, 2013, Min Ragan-Kelley License: LGPL-3 Files: zmq/devices/monitoredqueue.pxd Copyright: 2010, Brian E. Granger 2010, Min Ragan-Kelley License: LGPL-3 Files: perf/* Copyright: 2007-2010, iMatix Corporation / 2013 Brian Granger, Min Ragan-Kelley License: LGPL-3 Files: docs/sphinxext/sphinx_cython.py Copyright: 2010, Nikolaus Rath License: LGPL-3 Files: zmq/ssh/forward.py Copyright: 2003-2007, Robey Pointer , 2010-2011, IPython Development Team License: LGPL-2.1 Files: zmq/eventloop/zmqstream.py zmq/eventloop/ioloop.py Copyright: 2009, Facebook. License: Apache-2.0 Files: debian/* Copyright: 2010-2011, Miguel Landaeta 2011-2014, Julian Taylor License: LGPL-3 License: BSD-3-clause All rights reserved. . Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: . Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. . Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. . Neither the name of PyZMQ nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. . . THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. License: LGPL-3 This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version. . This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details. . You should have received a copy of the GNU Library General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. . The full text of the GNU Lesser General Public License version 3 is distributed in /usr/share/common-licenses/LGPL-3 on Debian systems. License: LGPL-2.1 This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. . This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. . You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA . The full text of the GNU Lesser General Public License version 2.1 is distributed in /usr/share/common-licenses/LGPL-2.1 on Debian systems. License: Apache-2.0 Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at . http://www.apache.org/licenses/LICENSE-2.0 /usr/share/common-licenses/Apache-2.0 (on Debian systems) . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. debian/changelog0000664000000000000000000001271012316332564011050 0ustar pyzmq (14.0.1-1build2) trusty; urgency=medium * No change rebuild to drop python3.3 compiled extension. -- Dimitri John Ledkov Mon, 31 Mar 2014 19:35:32 +0100 pyzmq (14.0.1-1build1) trusty; urgency=medium * rebuild against zeromq 4 to enable new features -- Julian Taylor Wed, 19 Feb 2014 21:17:23 +0100 pyzmq (14.0.1-1) unstable; urgency=low * New upstream release drop upstream applied workaround-gevent.patch * cython-error.patch: fix use-after-free due to wrong cython use * provide pypy-zmq package * build package with pybuild * bump cython build depend version to required >= 0.16 (Closes: #721711) * run nose with zmq.tests to avoid autopkgtest issues if optional dependencies are missing * bump X-Python-Version to >= 2.6 as required by 0.13.x * bump debhelper to >= 8.1~ for build-arch support * remove Miguel Landaeta from Uploaders. (Closes: #728413) Thank you for your work. * bump standard to 3.9.5, no changes required -- Julian Taylor Sat, 04 Jan 2014 22:24:19 +0100 pyzmq (13.1.0-1) unstable; urgency=low * New upstream release built with zeromq3 (Closes: #698830) - drop all patches * workaround-gevent.patch: workaround issue with gevent < 1.0 * noncopysend-test.patch: avoid uninitialized values in tests * update copyright -- Julian Taylor Sun, 12 May 2013 13:59:20 +0200 pyzmq (2.2.0.1-2) unstable; urgency=low [ Julian Taylor ] * upload to unstable * python-gevent-dbg is fixed, enable python2 dbg autopkgtests * cython0.19-compat.patch: fix build with cython 0.19 [ Jakub Wilk ] * Use canonical URIs for Vcs-* fields. -- Julian Taylor Thu, 09 May 2013 15:07:29 +0200 pyzmq (2.2.0.1-1) experimental; urgency=low * New upstream release * relicense debian packaging to LGPL-3 * update watch file to use github directly thanks to Bart Martens for the file * add autopkgtests * drop obsolete DM-Upload-Allowed * bump standard to 3.9.4, no changes required -- Julian Taylor Sun, 24 Feb 2013 19:23:15 +0100 pyzmq (2.2.0-1) unstable; urgency=low [ Julian Taylor ] * New upstream release * update debian/copyright for relicensing of non core files to BSD-3-clause * bump standard to 3.9.3, no changes required * build with hardening flags [ Bernd Zeimetz ] * Set DM-Upload-Allowed: yes -- Julian Taylor Sun, 20 May 2012 17:41:34 +0200 pyzmq (2.1.11-1) unstable; urgency=low [ Julian Taylor ] * New upstream release (Closes: #655793) * added myself to Uploaders * properly clean to allow building twice in a row * ignore testsuite result due to random failures on armel and mips probably caused by libzmq or toolchain * add Python3 to short description of py3 packages * wrap-and-sort debian/ * add python-nose to build depends to get better test result output * add python-numpy to build depends to get more tests * use githubredir.debian.net in debian/watch -- Julian Taylor Sun, 19 Feb 2012 14:53:20 +0100 pyzmq (2.1.10-2) unstable; urgency=low [ Julian Taylor ] * remove python:Provides, python:Breaks and XB-Python-Version not needed with dh_python2 * bump python dependency to >= 2.6.6-3~ for dh_python2 * do not delete *_d.so files from lib/debug in python-zmq-dbg - needed for gdb when using debug interpreter * fix dep5 copyright syntax error * add python3 packages (Closes: #636484) * add a directory existance check to clean target to allow build with git-buildpackage --git-overlay -- Debian Python Modules Team Mon, 05 Dec 2011 21:42:24 +0100 pyzmq (2.1.10-1) unstable; urgency=low * New upstream version * Build-depend on zeromq 2.1.10 -- Debian Python Modules Team Tue, 22 Nov 2011 14:54:20 +0100 pyzmq (2.1.9-1) unstable; urgency=low * New upstream version - should build on kFreeBSD without patches (Closes: #637777). * Build-depend on zeromq 2.1.9 -- Debian Python Modules Team Fri, 23 Sep 2011 00:16:39 +0200 pyzmq (2.1.7-1) unstable; urgency=low [ Bernd Zeimetz ] * New upstream version. * Build-depend on zeromq 2.1.7. * Bump Standards-Version to 3.9.2, no changes needed. * Remove all .pyc and .so files during clean. [ Miguel Landaeta ] * Update copyright dates and make it DEP-5 compliant. * Refresh patches. * Enable build-time tests. -- Miguel Landaeta Mon, 23 May 2011 08:57:59 +0200 pyzmq (2.0.10.1-2) unstable; urgency=low * Team upload. * Upload to unstable * Add Breaks: ${python:Breaks} -- Piotr Ożarowski Tue, 15 Feb 2011 09:08:36 +0100 pyzmq (2.0.10.1-1) experimental; urgency=low * New upstream release. * Migrate to dh_python2 and drop Build-Depends on python-support. * Fix typo in package descriptions. -- Miguel Landaeta Thu, 03 Feb 2011 13:50:00 -0430 pyzmq (2.0.10-1) experimental; urgency=low * New upstream release. - cpython minimum build version bumped to 0.13 * Add watch file. -- Miguel Landaeta Wed, 17 Nov 2010 16:14:17 -0430 pyzmq (0.1.20100703+git18f5d06155-1) unstable; urgency=low * Initial release. (Closes: #590633) -- Miguel Landaeta Wed, 08 Sep 2010 13:50:41 -0430 debian/control0000664000000000000000000001214212316332564010600 0ustar Source: pyzmq Section: python Priority: optional Maintainer: Ubuntu Developers XSBC-Original-Maintainer: Debian Python Modules Team Uploaders: Julian Taylor Build-Depends: cython (>= 0.16), cython-dbg (>= 0.16), debhelper (>= 8.1~), dh-python (>= 1.20131021-1~), dpkg-dev (>= 1.16.1~), libzmq3-dev, pypy (>= 2.0.0), python-all-dbg (>= 2.6.6-3~), python-all-dev (>= 2.6.6-3~), python-nose, python-numpy, python-setuptools, python3 (>= 3.3.0-2), python3-all-dbg (>= 3.2), python3-all-dev (>= 3.2) Standards-Version: 3.9.5 X-Python-Version: >= 2.6 X-Python3-Version: >= 3.2 Homepage: http://www.zeromq.org/bindings:python Vcs-Svn: svn://anonscm.debian.org/python-modules/packages/pyzmq/trunk/ Vcs-Browser: http://anonscm.debian.org/viewvc/python-modules/packages/pyzmq/trunk/ XS-Testsuite: autopkgtest Package: python-zmq Architecture: any Depends: ${misc:Depends}, ${python:Depends}, ${shlibs:Depends} Description: Python bindings for 0MQ library Python bindings for 0MQ. 0MQ is a small, fast, and free software library that gives you message-passing concurrency for applications in most common languages. . The 0MQ lightweight messaging kernel is a library which extends the standard socket interfaces with features traditionally provided by specialised messaging middleware products. 0MQ sockets provide an abstraction of asynchronous message queues, multiple messaging patterns, message filtering (subscriptions), seamless access to multiple transport protocols and more. Package: python-zmq-dbg Section: debug Priority: extra Architecture: any Depends: python-zmq (= ${binary:Version}), ${misc:Depends}, ${python:Depends}, ${shlibs:Depends} Recommends: python-dbg Description: Python bindings for 0MQ library - debugging files Python bindings for 0MQ. 0MQ is a small, fast, and free software library that gives you message-passing concurrency for applications in most common languages. . The 0MQ lightweight messaging kernel is a library which extends the standard socket interfaces with features traditionally provided by specialised messaging middleware products. 0MQ sockets provide an abstraction of asynchronous message queues, multiple messaging patterns, message filtering (subscriptions), seamless access to multiple transport protocols and more. . This package contains the extension built for the Python debug interpreter. Package: python3-zmq Architecture: any Depends: ${misc:Depends}, ${python3:Depends}, ${shlibs:Depends} Description: Python3 bindings for 0MQ library Python bindings for 0MQ. 0MQ is a small, fast, and free software library that gives you message-passing concurrency for applications in most common languages. . The 0MQ lightweight messaging kernel is a library which extends the standard socket interfaces with features traditionally provided by specialised messaging middleware products. 0MQ sockets provide an abstraction of asynchronous message queues, multiple messaging patterns, message filtering (subscriptions), seamless access to multiple transport protocols and more. . This package contains the extension built for the Python3 interpreter. Package: python3-zmq-dbg Section: debug Priority: extra Architecture: any Depends: python3-zmq (= ${binary:Version}), ${misc:Depends}, ${python3:Depends}, ${shlibs:Depends} Recommends: python-dbg Description: Python3 bindings for 0MQ library - debugging files Python bindings for 0MQ. 0MQ is a small, fast, and free software library that gives you message-passing concurrency for applications in most common languages. . The 0MQ lightweight messaging kernel is a library which extends the standard socket interfaces with features traditionally provided by specialised messaging middleware products. 0MQ sockets provide an abstraction of asynchronous message queues, multiple messaging patterns, message filtering (subscriptions), seamless access to multiple transport protocols and more. . This package contains the extension built for the Python3 debug interpreter. Package: pypy-zmq Architecture: any Depends: gcc, libzmq3-dev, pypy (>= 2.2), ${misc:Depends}, ${pypy:Depends}, ${shlibs:Depends} Description: PyPy bindings for 0MQ library Python bindings for 0MQ. 0MQ is a small, fast, and free software library that gives you message-passing concurrency for applications in most common languages. . The 0MQ lightweight messaging kernel is a library which extends the standard socket interfaces with features traditionally provided by specialised messaging middleware products. 0MQ sockets provide an abstraction of asynchronous message queues, multiple messaging patterns, message filtering (subscriptions), seamless access to multiple transport protocols and more. . This package contains the extension built for the PyPy interpreter. debian/rules0000775000000000000000000000326512262510015010250 0ustar #!/usr/bin/make -f DPKG_EXPORT_BUILDFLAGS = 1 include /usr/share/dpkg/buildflags.mk export PYBUILD_DESTDIR_python2=debian/python-zmq/ export PYBUILD_DESTDIR_python2-dbg=debian/python-zmq-dbg/ export PYBUILD_DESTDIR_python3=debian/python3-zmq/ export PYBUILD_DESTDIR_python3-dbg=debian/python3-zmq-dbg/ export PYBUILD_DESTDIR_pypy=debian/pypy-zmq/ export PYBUILD_DEBUG=1 export DH_VERBOSE=1 %: dh $@ --with python2,python3,pypy --buildsystem=pybuild override_dh_install: dh_install # remove a couple of header files already in python3-zmq find debian/python3-zmq-dbg/usr/lib/ ! -type d ! -name '*.so' -delete find debian/python-zmq-dbg/usr/lib/ ! -type d ! -name '*.so' -delete # cffi is only used for pypy rm -rf debian/python-zmq/usr/lib/python*/dist-packages/zmq/backend/cffi/ rm -rf debian/python-dbg-zmq/usr/lib/python*/dist-packages/zmq/backend/cffi/ rm -rf debian/python3-zmq/usr/lib/python*/dist-packages/zmq/backend/cffi/ rm -rf debian/python3-dbg-zmq/usr/lib/python*/dist-packages/zmq/backend/cffi/ # cython core is only used for cpython rm -rf debian/pypy-zmq/usr/lib/pypy/dist-packages/zmq/backend/cython # build shared libraries for pypy and install them pypy -c 'import zmq' mv -v zmq/backend/cffi/__pycache__/*so \ $(CURDIR)/debian/pypy-zmq/usr/lib/pypy/dist-packages/zmq/backend/cffi # put there by install, not needed rm -f $(CURDIR)/debian/pypy-zmq/usr/lib/pypy/dist-packages/_cffi*.so find debian/python-zmq -depth -empty -exec rmdir {} \; find debian/python-zmq-dbg -depth -empty -exec rmdir {} \; find debian/python3-zmq -depth -empty -exec rmdir {} \; find debian/python3-zmq-dbg -depth -empty -exec rmdir {} \; find debian/pypy-zmq -depth -empty -exec rmdir {} \; debian/watch0000664000000000000000000000013012205761053010214 0ustar version=3 https://github.com/zeromq/pyzmq/tags .*/.*v(\d.*)\.(?:tgz|tar\.(?:gz|bz2|xz)) debian/patches/0000775000000000000000000000000012262511221010611 5ustar debian/patches/cython-error.patch0000664000000000000000000000267112262510015014273 0ustar Description: fix possible use of deallocated object __dealloc__ method might be called when the object is partially deleted, so e.g. its methods must not be called. Fix this by copying the code of the methods which require no object internals. Author: Julian Taylor Bug: https://github.com/zeromq/pyzmq/issues/458 --- a/zmq/backend/cython/context.pyx +++ b/zmq/backend/cython/context.pyx @@ -94,7 +94,14 @@ cdef class Context: free(self._sockets) self._sockets = NULL self._n_sockets = 0 - self.term() + + if self.handle != NULL and not self.closed and getpid() == self._pid: + with nogil: + rc = zmq_ctx_destroy(self.handle) + _check_rc(rc) + self.handle = NULL + self.closed = True + cdef inline void _add_socket(self, void* handle): """Add a socket handle to be closed when Context terminates. diff --git a/zmq/backend/cython/utils.pyx b/zmq/backend/cython/utils.pyx index 0b318ee..43ed3d4 100644 --- a/zmq/backend/cython/utils.pyx +++ b/zmq/backend/cython/utils.pyx @@ -64,10 +64,9 @@ cdef class Stopwatch: self.watch = NULL def __dealloc__(self): - try: - self.stop() - except ZMQError: - pass + if self.watch: + zmq_stopwatch_stop(self.watch) + self.watch = NULL def start(self): """s.start() debian/patches/noncopysend-test.patch0000664000000000000000000000151712262510015015152 0ustar Description: don't use uninitialized memory for test the memory could contain signalling NaN which crashes sparc python Author: Julian Taylor Forwarded: not-needed --- a/zmq/tests/test_message.py +++ b/zmq/tests/test_message.py @@ -340,10 +340,8 @@ class TestFrame(BaseZMQTestCase): for i in range(1,len(shapes)+1): shape = shapes[:i] for dt in dtypes: - A = numpy.ndarray(shape, dtype=dt) - while numpy.isnan(A).any(): - # don't let nan sneak in - A = numpy.ndarray(shape, dtype=dt) + A = numpy.random.uniform(-10000000, + 1000000, size=shape).astype(dt) a.send(A, copy=False) msg = b.recv(copy=False) debian/patches/cffi-fix.patch0000664000000000000000000000431212262510015013325 0ustar Description: check package root for cffi binaries cffi checks __pycache__ for binaries which is cleaned by pypy installation so packages can't ship in there. Instead ship in package root and patch module finding to look in there. Also use fixed path in a place passed to cffi to get the same checksum in build and install. After it is installed no build is needed so it doesn't matter if its wrong. Bug: https://bitbucket.org/cffi/cffi/issue/109/enable-sane-packaging-for-cffi --- a/zmq/backend/cffi/__init__.py +++ b/zmq/backend/cffi/__init__.py @@ -9,6 +9,40 @@ # the file COPYING.BSD, distributed as part of this software. #----------------------------------------------------------------------------- +import imp +import os.path +import sys + +import cffi.vengine_cpy +import cffi.vengine_gen +_ma_triplet = None + +def vengine_gen_find_module(self, module_name, path, so_suffixes): + global _ma_triplet + if _ma_triplet is None: + try: + import subprocess as sp + p = sp.Popen(["gcc", "-print-multiarch"], stdout=sp.PIPE) + _ma_triplet = str(p.communicate()[0].decode().strip()) + except: + import warnings + warnings.warn('failed to detect multiarch paths, please install gcc') + + for so_suffix in so_suffixes + ['.%s-%s.so' % (imp.get_tag(), _ma_triplet)]: + basename = module_name + so_suffix + if path is None: + path = sys.path + # import from non root package would try __pycache__ which is + # cleaned by pypy installation + path.insert(0, "/usr/lib/pypy/dist-packages/zmq/backend/cffi") + for dirname in path: + filename = os.path.join(dirname, basename) + if os.path.isfile(filename): + return filename + + +cffi.vengine_gen.VGenericEngine.find_module = vengine_gen_find_module + from zmq.backend.cffi import (constants, error, message, context, socket, _poll, devices, utils) --- a/zmq/backend/cffi/_cffi.py +++ b/zmq/backend/cffi/_cffi.py @@ -196,7 +196,7 @@ else: ffi.cdef(functions) -zmq_utils = os.path.dirname(zmq.utils.__file__) +zmq_utils = "zmq/utils" C = ffi.verify(''' #include debian/patches/series0000664000000000000000000000007012262510015012023 0ustar noncopysend-test.patch cffi-fix.patch cython-error.patchdebian/compat0000664000000000000000000000000211455275705010401 0ustar 7 debian/tests/0000775000000000000000000000000012262511221010324 5ustar debian/tests/pypy0000775000000000000000000000023412262510015011252 0ustar #!/bin/sh set -efu cd "$ADTTMP" echo "=== pypy ===" pypy -m unittest discover -v -s $(pypy -c "import zmq, os; print os.path.dirname(zmq.__file__)") 2>&1 debian/tests/control0000664000000000000000000000055012262510015011727 0ustar Tests: python2 Depends: python-all, python-all-dbg, python-zmq, python-zmq-dbg, python-nose, python-numpy-dbg, python-numpy, python-tornado, python-gevent, python-gevent-dbg Tests: python3 Depends: python3-all, python3-all-dbg, python3-zmq, python3-zmq-dbg, python3-nose, python3-numpy, python3-numpy-dbg, python3-tornado Tests: pypy Depends: pypy, pypy-zmq debian/tests/python20000775000000000000000000000035612262510015011661 0ustar #!/bin/sh set -efu pys="$(pyversions -r 2>/dev/null)" cd "$ADTTMP" for py in $pys; do echo "=== $py ===" $py /usr/bin/nosetests -v zmq.tests 2>&1 echo "=== $py-dbg ===" $py-dbg /usr/bin/nosetests -v zmq.tests 2>&1 done debian/tests/python30000775000000000000000000000036112262510015011656 0ustar #!/bin/sh set -efu pys="$(py3versions -r 2>/dev/null)" cd "$ADTTMP" for py in $pys; do echo "=== $py ===" $py /usr/bin/nosetests3 -v zmq.tests 2>&1 echo "=== $py-dbg ===" $py-dbg /usr/bin/nosetests3 -v zmq.tests 2>&1 done