The NetBSD Project

CVS log for pkgsrc/devel/py-cffi/distinfo

[BACK] Up to [cvs.NetBSD.org] / pkgsrc / devel / py-cffi

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.49 / (download) - annotate - [select for diffs], Tue Mar 19 10:49:46 2024 UTC (10 days, 2 hours ago) by nia
Branch: MAIN
CVS Tags: HEAD
Changes since 1.48: +2 -1 lines
Diff to previous 1.48 (colored)

py-cffi: Do not attempt to peek past pkg-config on Darwin/FreeBSD

Revision 1.48 / (download) - annotate - [select for diffs], Wed Oct 4 21:51:44 2023 UTC (5 months, 3 weeks ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2023Q4-base, pkgsrc-2023Q4
Changes since 1.47: +4 -4 lines
Diff to previous 1.47 (colored)

py-cffi: updated to 1.16.0

v1.16.0

* Add support for Python 3.12. With the removal of ``distutils`` from Python 3.12, projects
  using CFFI features that depend on ``distutils`` at runtime must add a dependency on
  ``setuptools`` to function under Python 3.12+. CFFI does not declare a runtime ``setuptools``
  requirement to avoid an unnecessary dependency for projects that do not require it.
* Drop support for end-of-life Python versions (2.7, 3.6, 3.7).
* Add support for PEP517 builds; ``setuptools`` is now a required build dependency.
* Declare ``python_requires`` metadata for Python 3.8+. This allows unsupported Pythons
  to continue using previously released sdists and wheels.
* Move project source under ``src/``; a more standard layout that also enables CI to more easily
  catch packaging errors.

Revision 1.47 / (download) - annotate - [select for diffs], Fri Jul 1 17:10:46 2022 UTC (20 months, 4 weeks ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2023Q3-base, pkgsrc-2023Q3, pkgsrc-2023Q2-base, pkgsrc-2023Q2, pkgsrc-2023Q1-base, pkgsrc-2023Q1, pkgsrc-2022Q4-base, pkgsrc-2022Q4, pkgsrc-2022Q3-base, pkgsrc-2022Q3
Changes since 1.46: +4 -4 lines
Diff to previous 1.46 (colored)

py-cffi: updated to 1.15.1

v1.15.1
=======

* If you call `ffi.embedding_api()` but don't write any `extern "Python"`
  function there, then the resulting C code would fail an assert.  Fixed.

* Updated Windows/arm64 embedded libffi static lib to v3.4.2, and scripted
  to ease future updates (thanks Niyas Sait!)

Revision 1.46 / (download) - annotate - [select for diffs], Fri Dec 10 08:59:09 2021 UTC (2 years, 3 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2022Q2-base, pkgsrc-2022Q2, pkgsrc-2022Q1-base, pkgsrc-2022Q1, pkgsrc-2021Q4-base, pkgsrc-2021Q4
Changes since 1.45: +4 -4 lines
Diff to previous 1.45 (colored)

py-cffi: updated to 1.15.0

v1.15.0
=======
* Fixed MANIFEST.in to include missing file for Windows arm64 support
* Fixed Linux wheel build to use gcc default ISA for libffi
* Updated setup.py Python trove specifiers to currently-tested Python versions
* CPython 3.10 support (including wheels)
* MacOS arm64 support (including wheels)
* Initial Windows arm64 support
* Misc. doc and test updates

Revision 1.45 / (download) - annotate - [select for diffs], Tue Oct 26 10:18:17 2021 UTC (2 years, 5 months ago) by nia
Branch: MAIN
Changes since 1.44: +2 -2 lines
Diff to previous 1.44 (colored)

archivers: Replace RMD160 checksums with BLAKE2s checksums

All checksums have been double-checked against existing RMD160 and
SHA512 hashes

Could not be committed due to merge conflict:
devel/py-traitlets/distinfo

The following distfiles were unfetchable (note: some may be only fetched
conditionally):

./devel/pvs/distinfo pvs-3.2-solaris.tgz
./devel/eclipse/distinfo eclipse-sourceBuild-srcIncluded-3.0.1.zip

Revision 1.44 / (download) - annotate - [select for diffs], Thu Oct 7 13:43:01 2021 UTC (2 years, 5 months ago) by nia
Branch: MAIN
Changes since 1.43: +1 -2 lines
Diff to previous 1.43 (colored)

devel: Remove SHA1 hashes for distfiles

Revision 1.43 / (download) - annotate - [select for diffs], Fri Jul 9 20:20:27 2021 UTC (2 years, 8 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2021Q3-base, pkgsrc-2021Q3
Changes since 1.42: +5 -5 lines
Diff to previous 1.42 (colored)

py-cffi: updated to 1.14.6

v1.14.6

Test fixes for CPython 3.10.0b3
Support for sys.unraisablehook() on Python >= 3.8
Fix two minor memory leaks (thanks Sebastian!)
Like many projects that had an IRC channel on freenode, we moved it to irc.libera.chat.

Revision 1.42 / (download) - annotate - [select for diffs], Tue Feb 16 20:41:09 2021 UTC (3 years, 1 month ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2021Q2-base, pkgsrc-2021Q2, pkgsrc-2021Q1-base, pkgsrc-2021Q1
Changes since 1.41: +5 -5 lines
Diff to previous 1.41 (colored)

py-cffi: updated to 1.14.5

v1.14.5

Source fix for old gcc versions
This and future releases should include wheels on more platforms, thanks to our new release managers Matt and Matt!

Revision 1.41 / (download) - annotate - [select for diffs], Wed Nov 25 11:34:39 2020 UTC (3 years, 4 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2020Q4-base, pkgsrc-2020Q4
Changes since 1.40: +5 -5 lines
Diff to previous 1.40 (colored)

py-cffi: updated to 1.14.4

1.14.4:
Unknown changes

Revision 1.40 / (download) - annotate - [select for diffs], Tue Sep 29 12:03:20 2020 UTC (3 years, 5 months ago) by adam
Branch: MAIN
Changes since 1.39: +5 -5 lines
Diff to previous 1.39 (colored)

py-cffi: updated to 1.14.3

1.14.3:
Unknown changes

Revision 1.39 / (download) - annotate - [select for diffs], Mon Aug 24 11:08:14 2020 UTC (3 years, 7 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2020Q3-base, pkgsrc-2020Q3
Changes since 1.38: +5 -5 lines
Diff to previous 1.38 (colored)

py-cffi: updated to 1.14.2

v1.14.2
=======

* CPython 3 on Windows: we again try to compile with ``Py_LIMITED_API``
  by default.  This flag is not added if you run the compilation with
  CPython 3.4, as it only works with CPython >= 3.5, but by now this
  version of Python is quite old (and we no longer distribute cffi
  wheels for it).

  This may require that you upgrade ``virtualenv`` (requires version 16
  or newer) or at least copy manually ``python3.dll`` into your existing
  virtualenvs.  For distributing wheels with your cffi modules, you may
  also need to upgrade ``wheel`` to the just-released version 0.35.

  You can manually disable ``Py_LIMITED_API`` by calling
  ``ffi.set_source(..., py_limited_api=False)``.

Revision 1.38 / (download) - annotate - [select for diffs], Mon Jul 27 17:28:05 2020 UTC (3 years, 8 months ago) by adam
Branch: MAIN
Changes since 1.37: +5 -5 lines
Diff to previous 1.37 (colored)

py-cffi: updated to 1.14.1

v1.14.1
=======

* CFFI source code is now `hosted on Heptapod`_.

* Improved support for ``typedef int my_array_t[...];`` with an explicit
  dot-dot-dot in API mode

* Windows (32 and 64 bits): multiple fixes for ABI-mode call to functions
  that return a structure.

* Experimental support for MacOS 11 on aarch64.

* and a few other minor changes and bug fixes.

Revision 1.37 / (download) - annotate - [select for diffs], Wed Mar 4 18:27:28 2020 UTC (4 years ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2020Q2-base, pkgsrc-2020Q2, pkgsrc-2020Q1-base, pkgsrc-2020Q1
Changes since 1.36: +5 -5 lines
Diff to previous 1.36 (colored)

py-cffi: updated to 1.14.0

v1.14

ffi.dlopen() can now be called with a handle (as a void *) to an already-opened C library.
CPython only: fixed a stack overflow issue for calls like lib.myfunc([large list]). If the function is declared as taking a float * argument, for example, then the array is temporarily converted into a C array of floatsãàÇÉowever, the code used to use alloca() for this temporary storage, no matter how large. This is now fixed.

The fix concerns all modes: in-line/out-of-line API/ABI. Also note that your API-mode C extension modules need to be regenerated with cffi 1.14 in order to get the fix; i.e. for API mode, the fix is in the generated C sources. (The C sources generated from cffi 1.14 should also work when running in a different environment in which we have an older version of cffi. Also, this change makes no difference on PyPy.)

As a workaround that works on all versions of cffi, you can write lib.myfunc(ffi.new("float[]", [large list])), which is equivalent but explicity builds the intermediate array as a regular Python object on the heap.
fixed a memory leak inside ffi.getwinerror() on CPython 3.x.

Revision 1.36 / (download) - annotate - [select for diffs], Wed Nov 6 17:24:50 2019 UTC (4 years, 4 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2019Q4-base, pkgsrc-2019Q4
Changes since 1.35: +5 -5 lines
Diff to previous 1.35 (colored)

py-cffi: updated to 1.13.2

v1.13.2
* re-release because the Linux wheels came with an attached version of libffi
  that was very old and buggy

Revision 1.35 / (download) - annotate - [select for diffs], Fri Oct 25 10:21:35 2019 UTC (4 years, 5 months ago) by adam
Branch: MAIN
Changes since 1.34: +5 -5 lines
Diff to previous 1.34 (colored)

py-cffi: updated to 1.13.1

v1.13.1
* deprecate the way to declare in cdef() a global variable with only void *foo;. You should always use a storage class, like extern void *foo; or maybe static void *foo;. These are all equivalent for the purposes of cdef(), but the reason for deprecating the bare version is that (as far as I know) it would always be mistake in a real C header.
* fix the regression RuntimeError: found a situation in which we try to build a type recursively.
* fixed issue 427 where a multithreading mistake in the embedding logic initialization code would cause deadlocks on CPython 3.7.

Revision 1.34 / (download) - annotate - [select for diffs], Wed Oct 16 08:12:08 2019 UTC (4 years, 5 months ago) by adam
Branch: MAIN
Changes since 1.33: +5 -5 lines
Diff to previous 1.33 (colored)

py-cffi: updated to 1.13.0

v1.13
* ffi.from_buffer("type *", ..) is now supported, in addition to
  "type[]".  You can then write p.field to access the items, instead
  of only p[0].field.  Be careful that no bounds checking is performed, so
  p[n] might access data out of bounds.
* fix for structs containing unnamed bitfields like int : 1;.
* when calling cdata of "function pointer" type, give a RuntimeError instead
  of a crash if the pointer happens to be NULL
* support some more binary operations between constants in enum definitions
* silence a warning incorrectly emitted if you use a quote in a preprocessor
  line
* detect a corner case that would throw the C code into an infinite
  recursion, with ffi.cdef("""struct X { void(*fnptr)(struct X); };""")

Revision 1.33 / (download) - annotate - [select for diffs], Fri Apr 26 15:14:31 2019 UTC (4 years, 11 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2019Q3-base, pkgsrc-2019Q3, pkgsrc-2019Q2-base, pkgsrc-2019Q2
Changes since 1.32: +5 -5 lines
Diff to previous 1.32 (colored)

py-cffi: updated to 1.12.3

v1.12.3
* Fix for nested struct types that end in a var-sized array.
* Add support for using U and L characters at the end of integer
  constants in ffi.cdef().
* More 3.8 fixes.

Revision 1.32 / (download) - annotate - [select for diffs], Thu Feb 28 08:51:00 2019 UTC (5 years, 1 month ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2019Q1-base, pkgsrc-2019Q1
Changes since 1.31: +5 -5 lines
Diff to previous 1.31 (colored)

py-cffi: updated to 1.12.2

v1.12.2
* Added temporary workaround to compile on CPython 3.8.0a2.

Revision 1.31 / (download) - annotate - [select for diffs], Sat Feb 16 23:37:23 2019 UTC (5 years, 1 month ago) by adam
Branch: MAIN
Changes since 1.30: +5 -5 lines
Diff to previous 1.30 (colored)

py-cffi: updated to 1.12.1

v1.12.1
CPython 3 on Windows: we again no longer compile with Py_LIMITED_API by default because such modules still cannot be used with virtualenv. The problem is that it doesnãàÑÕ work in CPython <= 3.4, and for technical reason we canãàÑÕ enable this flag automatically based on the version of Python.

Like before, Issue 350 mentions a workaround if you still want the Py_LIMITED_API flag and either you are not concerned about virtualenv or you are sure your module will not be used on CPython <= 3.4: pass define_macros=[("Py_LIMITED_API", None)] to the ffibuilder.set_source() call.

v1.12
Direct support for pkg-config.
ffi.from_buffer() takes a new optional first argument that gives the array type of the result. It also takes an optional keyword argument require_writable to refuse read-only Python buffers.
ffi.new(), ffi.gc() or ffi.from_buffer() cdata objects can now be released at known times, either by using the with keyword or by calling the new ffi.release().
Windows, CPython 3.x: cffi modules are linked with python3.dll again. This makes them independant on the exact CPython version, like they are on other platforms. It requires virtualenv 16.0.0.
Accept an expression like ffi.new("int[4]", p) if p is itself another cdata int[4].
CPython 2.x: ffi.dlopen() failed with non-ascii file names on Posix
CPython: if a thread is started from C and then runs Python code (with callbacks or with the embedding solution), then previous versions of cffi would contain possible crashes and/or memory leaks. Hopefully, this has been fixed.
Support for ffi.cdef(..., pack=N) where N is a power of two. Means to emulate #pragma pack(N) on MSVC. Also, the default on Windows is now pack=8, like on MSVC. This might make a difference in corner cases, although I canãàÑÕ think of one in the context of CFFI. The old way ffi.cdef(..., packed=True) remains and is equivalent to pack=1 (saying e.g. that fields like int should be aligned to 1 byte instead of 4).

Revision 1.30 / (download) - annotate - [select for diffs], Thu Mar 1 07:59:54 2018 UTC (6 years ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2018Q4-base, pkgsrc-2018Q4, pkgsrc-2018Q3-base, pkgsrc-2018Q3, pkgsrc-2018Q2-base, pkgsrc-2018Q2, pkgsrc-2018Q1-base, pkgsrc-2018Q1
Changes since 1.29: +7 -7 lines
Diff to previous 1.29 (colored)

py-cffi: updated to 1.11.5

v1.11.5

* Issue 357_: fix ffi.emit_python_code() which generated a buggy
  Python file if you are using a struct with an anonymous union
  field or vice-versa.

* Windows: ffi.dlopen() should now handle unicode filenames.

* ABI mode: implemented ffi.dlclose() for the in-line case (it used
  to be present only in the out-of-line case).

* Fixed a corner case for setup.py install --record=xx --root=yy
  with an out-of-line ABI module.  Also fixed Issue 345_.

* More hacks on Windows for running CFFI's own setup.py.

* Issue 358_: in embedding, to protect against (the rare case of)
  Python initialization from several threads in parallel, we have to use
  a spin-lock.  On CPython 3 it is worse because it might spin-lock for
  a long time (execution of Py_InitializeEx()).  Sadly, recent
  changes to CPython make that solution needed on CPython 2 too.

* CPython 3 on Windows: we no longer compile with Py_LIMITED_API
  by default because such modules cannot be used with virtualenv.
  Issue 350_ mentions a workaround if you still want that and are not
  concerned about virtualenv: pass a define_macros=[("Py_LIMITED_API",
  None)] to the ffibuilder.set_source() call.

Revision 1.29 / (download) - annotate - [select for diffs], Sun Jan 14 11:09:17 2018 UTC (6 years, 2 months ago) by adam
Branch: MAIN
Changes since 1.28: +5 -5 lines
Diff to previous 1.28 (colored)

py-cffi: updated to 1.11.4

v1.11.4:
* Windows: reverted linking with python3.dll, because virtualenv does not make this DLL available to virtual environments for now. On Windows only, the C extension modules created by cffi follow for now the standard naming scheme foo.cp36-win32.pyd, to make it clear that they are regular CPython modules depending on python36.dll.

Revision 1.28 / (download) - annotate - [select for diffs], Fri Jan 12 12:26:00 2018 UTC (6 years, 2 months ago) by adam
Branch: MAIN
Changes since 1.27: +5 -5 lines
Diff to previous 1.27 (colored)

py-cffi: updated to 1.11.3

v1.11.3
Fix on CPython 3.x: reading the attributes __loader__ or __spec__ from the cffi-generated lib modules gave a buggy SystemError. (These attributes are always None, and provided only to help compatibility with tools that expect them in all modules.)
More Windows fixes: workaround for MSVC not supporting large literal strings in C code (from ffi.embedding_init_code(large_string)); and an issue with Py_LIMITED_API linking with python35.dll/python36.dll instead of python3.dll.
Small documentation improvements.

Revision 1.27 / (download) - annotate - [select for diffs], Tue Oct 10 07:44:12 2017 UTC (6 years, 5 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2017Q4-base, pkgsrc-2017Q4
Changes since 1.26: +5 -5 lines
Diff to previous 1.26 (colored)

py-cffi: update to 1.11.2

v1.11.2
Fix Windows issue with managing the thread-state on CPython 3.0 to 3.5

Revision 1.26 / (download) - annotate - [select for diffs], Thu Oct 5 12:18:21 2017 UTC (6 years, 5 months ago) by adam
Branch: MAIN
Changes since 1.25: +5 -5 lines
Diff to previous 1.25 (colored)

py-cffi: update to 1.11.1

v1.11.1
Fix tests, remove deprecated C API usage
Fix (hack) for 3.6.0/3.6.1/3.6.2 giving incompatible binary extensions
Fix for 3.7.0a1+

Revision 1.25 / (download) - annotate - [select for diffs], Sat Sep 30 13:09:47 2017 UTC (6 years, 5 months ago) by adam
Branch: MAIN
Changes since 1.24: +5 -6 lines
Diff to previous 1.24 (colored)

py-cffi: update to 1.11.0

v1.11
Support the modern standard types char16_t and char32_t. These work like wchar_t: they represent one unicode character, or when used as charN_t * or charN_t[] they represent a unicode string. The difference with wchar_t is that they have a known, fixed size. They should work at all places that used to work with wchar_t (please report an issue if I missed something). Note that with set_source(), you need to make sure that these types are actually defined by the C source you provide (if used in cdef()).

Support the C99 types float _Complex and double _Complex. Note that libffi doesnãàÑÕ support them, which means that in the ABI mode you still cannot call C functions that take complex numbers directly as arguments or return type.

Fixed a rare race condition when creating multiple FFI instances from multiple threads. (Note that you arenãàÑÕ meant to create many FFI instances: in inline mode, you should write ffi = cffi.FFI() at module level just after import cffi; and in out-of-line mode you donãàÑÕ instantiate FFI explicitly at all.)

Windows: using callbacks can be messy because the CFFI internal error messages show up to stderrãàÇÃut stderr goes nowhere in many applications. This makes it particularly hard to get started with the embedding mode. (Once you get started, you can at least use @ffi.def_extern(onerror=...) and send the error logs where it makes sense for your application, or record them in log files, and so on.) So what is new in CFFI is that now, on Windows CFFI will try to open a non-modal MessageBox (in addition to sending raw messages to stderr). The MessageBox is only visible if the process stays alive: typically, console applications that crash close immediately, but that is also the situation where stderr should be visible anyway.

Progress on support for callbacks in NetBSD.

Functions returning booleans would in some case still return 0 or 1 instead of False or True. Fixed.

ffi.gc() now takes an optional third parameter, which gives an estimate of the size (in bytes) of the object. So far, this is only used by PyPy, to make the next GC occur more quickly (issue 320). In the future, this might have an effect on CPython too (provided the CPython issue 31105 is addressed).

Add a note to the documentation: the ABI mode gives function objects that are slower to call than the API mode does. For some reason it is often thought to be faster. It is not!

Revision 1.24 / (download) - annotate - [select for diffs], Mon Jul 3 18:17:45 2017 UTC (6 years, 8 months ago) by joerg
Branch: MAIN
CVS Tags: pkgsrc-2017Q3-base, pkgsrc-2017Q3
Changes since 1.23: +4 -2 lines
Diff to previous 1.23 (colored)

Use libffi's closure handling based on code from the upstream branch.
Adjust test cases to not use alloca.h on NetBSD. Use a temporary
directory under WRKDIR and allow C++ when test builds are requested.

Revision 1.23 / (download) - annotate - [select for diffs], Wed Apr 5 15:54:26 2017 UTC (6 years, 11 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2017Q2-base, pkgsrc-2017Q2
Changes since 1.22: +5 -5 lines
Diff to previous 1.22 (colored)

Updated py-cffi to 1.10.0.

v1.10

    Issue #295: use calloc() directly instead of PyObject_Malloc()+memset()
    to handle ffi.new() with a default allocator. Speeds up
    ffi.new(large-array) where most of the time you never touch
    most of the array.
    Some OS/X build fixes (ãà×Ðnly with Xcode but without CLTãà.
    Improve a couple of error messages: when getting mismatched
    versions of cffi and its backend; and when calling functions
    which cannot be called with libffi because an argument is a
    struct that is ãà×Õoo complicatedãà(and not a struct pointer,
    which always works).
    Add support for some unusual compilers (non-msvc, non-gcc,
    non-icc, non-clang)
    Implemented the remaining cases for ffi.from_buffer. Now all
    buffer/memoryview objects can be passed. The one remaining check
    is against passing unicode strings in Python 2. (They support
    the buffer interface, but that gives the raw bytes behind the
    UTF16/UCS4 storage, which is most of the times not what you
    expect. In Python 3 this has been fixed and the unicode strings
    donãàÑÕ support the memoryview interface any more.)
    The C type _Bool or bool now converts to a Python boolean when
    reading, instead of the content of the byte as an integer. The
    potential incompatibility here is what occurs if the byte
    contains a value different from 0 and 1. Previously, it would
    just return it; with this change, CFFI raises an exception in
    this case. But this case means ãà×Öndefined behaviorãàin C; if
    you really have to interface with a library relying on this,
    donãàÑÕ use bool in the CFFI side. Also, it is still valid to use
    a byte string as initializer for a bool[], but now it must only
    contain \x00 or \x01. As an aside, ffi.string() no longer works
    on bool[] (but it never made much sense, as this function stops
    at the first zero).
    ffi.buffer is now the name of cffiãàÑÔ buffer type, and ffi.buffer()
    works like before but is the constructor of that type.
    ffi.addressof(lib, "name") now works also in in-line mode, not
    only in out-of-line mode. This is useful for taking the address
    of global variables.
    Issue #255: cdata objects of a primitive type (integers, floats,
    char) are now compared and ordered by value. For example, <cdata
    'int' 42> compares equal to 42 and <cdata 'char' b'A'> compares
    equal to b'A'. Unlike C, <cdata 'int' -1> does not compare equal
    to ffi.cast("unsigned int", -1): it compares smaller, because
    -1 < 4294967295.
    PyPy: ffi.new() and ffi.new_allocator()() did not record ãà×Îemory
    pressureãà causing the GC to run too infrequently if you call
    ffi.new() very often and/or with large arrays. Fixed in PyPy
    5.7.
    Support in ffi.cdef() for numeric expressions with + or -.
    Assumes that there is no overflow; it should be fixed first
    before we add more general support for arbitrary arithmetic on
    constants.

Revision 1.22 / (download) - annotate - [select for diffs], Mon Nov 14 14:31:18 2016 UTC (7 years, 4 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2017Q1-base, pkgsrc-2017Q1, pkgsrc-2016Q4-base, pkgsrc-2016Q4
Changes since 1.21: +6 -6 lines
Diff to previous 1.21 (colored)

Updated py-cffi to 1.9.1.

v1.9

    Structs with variable-sized arrays as their last field: now we
    track the length of the array after ffi.new() is called, just
    like we always tracked the length of ffi.new("int[]", 42). This
    lets us detect out-of-range accesses to array items. This also
    lets us display a better repr(), and have the total size returned
    by ffi.sizeof() and ffi.buffer(). Previously both functions
    would return a result based on the size of the declared structure
    type, with an assumed empty array. (Thanks andrew for starting
    this refactoring.)
    Add support in cdef()/set_source() for unspecified-length arrays
    in typedefs: typedef int foo_t[...];. It was already supported
    for global variables or structure fields.
    I turned in v1.8 a warning from cffi/model.py into an error:
    'enum xxx' has no values explicitly defined: refusing to guess
    which integer type it is meant to be (unsigned/signed, int/long).
    Now IãÎ turning it back to a warning again; it seems that
    guessing that the enum has size int is a 99%-safe bet. (But
    not 100%, so it stays as a warning.)
    Fix leaks in the code handling FILE * arguments. In CPython 3
    there is a remaining issue that is hard to fix: if you pass a
    Python file object to a FILE * argument, then os.dup() is used
    and the new file descriptor is only closed when the GC reclaims
    the Python file objectãÂnd not at the earlier time when you
    call close(), which only closes the original file descriptor.
    If this is an issue, you should avoid this automatic convertion
    of Python file objects: instead, explicitly manipulate file
    descriptors and call fdopen() from C (...via cffi).

Revision 1.21 / (download) - annotate - [select for diffs], Thu Sep 22 06:44:09 2016 UTC (7 years, 6 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2016Q3-base, pkgsrc-2016Q3
Changes since 1.20: +2 -1 lines
Diff to previous 1.20 (colored)

Add patch to distinfo and bump PKGREVISION for it.

('make test' still fails with mprotect enabled.)

Revision 1.20 / (download) - annotate - [select for diffs], Sun Sep 18 22:05:57 2016 UTC (7 years, 6 months ago) by wiz
Branch: MAIN
Changes since 1.19: +5 -5 lines
Diff to previous 1.19 (colored)

Updated py-cffi to 1.8.3.

v1.8.3
======

* When passing a ``void *`` argument to a function with a different
  pointer type, or vice-versa, the cast occurs automatically, like in C.
  The same occurs for initialization with ``ffi.new()`` and a few other
  places.  However, I thought that ``char *`` had the same
  property---but I was mistaken.  In C you get the usual warning if you
  try to give a ``char *`` to a ``char **`` argument, for example.
  Sorry about the confusion.  This has been fixed in CFFI by giving for
  now a warning, too.  It will turn into an error in a future version.

Revision 1.19 / (download) - annotate - [select for diffs], Mon Sep 12 07:57:41 2016 UTC (7 years, 6 months ago) by wiz
Branch: MAIN
Changes since 1.18: +5 -5 lines
Diff to previous 1.18 (colored)

Updated py-cffi to 1.8.2.

Tests don't run on MPROTECT enabled systems, and I haven't found
the magic to fix that.

CFFI 1.8.2 has been released.  (Versions 1.8 and 1.8.1 are only inside
PyPy 5.4.0 and 5.4.1, which have been released recently.)

Two main changes:

* On CPython 3.x, the C extension modules generated by cffi (not cffi
itself!) are now using CPython's official "limited C API".  This means
that the same compiled .so/.dll should work without recompilation on
any version >= 3.2.  The name produced by distutils is still
version-specific.  To get the version-independent name, you can rename
it manually to ``NAME.abi3.so``, or use the very recent setuptools 26.

* ffi.from_buffer() can now be used on byte strings, getting the
``char *`` address of the C string directly.  This was not allowed
because PyPy couldn't support it---we can make the string non-movable,
but the blocker was that the strings in PyPy are not zero-terminated!
So from PyPy 5.4 all strings are allocated with space for one extra
character---an extremely minor overhead---and we write a zero at the
end when ffi.from_buffer() is called.  Similarly, when we call
``lib.func("abc")``, PyPy would always make a copy of the string
because the original wasn't zero-terminated; now neither PyPy nor
CPython need to duplicate the string.

1.7.0

cffi 1.7 has been released.  (It corresponds to the version that was
released with PyPy 5.3.)

In the main news, the following are now supported:

* ffi.gc(p, None)
* bool(ffi.cast("primitive type", x))
* ffi.from_buffer(bytearray-object)
* C++: "_Bool undefined" fixed
* help(lib), help(lib.myfunc)

Revision 1.18 / (download) - annotate - [select for diffs], Sun Apr 24 09:37:29 2016 UTC (7 years, 11 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2016Q2-base, pkgsrc-2016Q2
Changes since 1.17: +5 -5 lines
Diff to previous 1.17 (colored)

Updated py35-cffi to 1.6.0.

v1.6
====

* `ffi.list_types()`_

* `ffi.unpack()`_

* `extern "Python+C"`_

* in API mode, ``lib.foo.__doc__`` contains the C signature now.  On
  CPython you can say ``help(lib.foo)``, but for some reason
  ``help(lib)`` (or ``help(lib.foo)`` on PyPy) is still useless; I
  haven't yet figured out the hacks needed to convince ``pydoc`` to
  show more.  (You can use ``dir(lib)`` but it is not most helpful.)

* Yet another attempt at robustness of ``ffi.def_extern()`` against
  CPython's interpreter shutdown logic.

.. _`ffi.list_types()`: ref.html#ffi-list-types
.. _`ffi.unpack()`: ref.html#ffi-unpack
.. _`extern "Python+C"`: using.html#extern-python-c

XXX: standard download URL doesn't work?!
copied to ftp.netbsd.org manually

Revision 1.17 / (download) - annotate - [select for diffs], Sun Feb 14 10:50:12 2016 UTC (8 years, 1 month ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2016Q1-base, pkgsrc-2016Q1
Changes since 1.16: +5 -5 lines
Diff to previous 1.16 (colored)

Update py-cffi to 1.5.2.

v1.5.2
======

* Fix 1.5.1 for Python 2.6.


v1.5.1
======

* A few installation-time tweaks (thanks Stefano!)

* Issue #245: Win32: ``__stdcall`` was never generated for
  ``extern "Python"`` functions

* Issue #246: trying to be more robust against CPython's fragile
  interpreter shutdown logic

Revision 1.16 / (download) - annotate - [select for diffs], Mon Jan 18 22:55:13 2016 UTC (8 years, 2 months ago) by wiz
Branch: MAIN
Changes since 1.15: +5 -5 lines
Diff to previous 1.15 (colored)

Update py-cffi to 1.5.0:

v1.5.0
======

* Support for `using CFFI for embedding`__.

Revision 1.15 / (download) - annotate - [select for diffs], Sun Dec 27 22:36:51 2015 UTC (8 years, 3 months ago) by wiz
Branch: MAIN
Changes since 1.14: +5 -5 lines
Diff to previous 1.14 (colored)

Update py-cffi to 1.4.2:

v1.4.2
======

Nothing changed from v1.4.1.


v1.4.1
======

* Fix the compilation failure of cffi on CPython 3.5.0.  (3.5.1 works;
  some detail changed that makes some underscore-starting macros
  disappear from view of extension modules, and I worked around it,
  thinking it changed in all 3.5 versions---but no: it was only in
  3.5.1.)


v1.4.0
======

* A `better way to do callbacks`__ has been added (faster and more
  portable, and usually cleaner).  It is a mechanism for the
  out-of-line API mode that replaces the dynamic creation of callback
  objects (i.e. C functions that invoke Python) with the static
  declaration in ``cdef()`` of which callbacks are needed.  This is
  more C-like, in that you have to structure your code around the idea
  that you get a fixed number of function pointers, instead of
  creating them on-the-fly.

* ``ffi.compile()`` now takes an optional ``verbose`` argument.  When
  ``True``, distutils prints the calls to the compiler.

* ``ffi.compile()`` used to fail if given ``sources`` with a path that
  includes ``".."``.  Fixed.

* ``ffi.init_once()`` added.  See docs__.

* ``dir(lib)`` now works on libs returned by ``ffi.dlopen()`` too.

* Cleaned up and modernized the content of the ``demo`` subdirectory
  in the sources (thanks matti!).

* ``ffi.new_handle()`` is now guaranteed to return unique ``void *``
  values, even if called twice on the same object.  Previously, in
  that case, CPython would return two ``cdata`` objects with the same
  ``void *`` value.  This change is useful to add and remove handles
  from a global dict (or set) without worrying about duplicates.
  It already used to work like that on PyPy.
  *This change can break code that used to work on CPython by relying
  on the object to be kept alive by other means than keeping the
  result of ffi.new_handle() alive.*  (The corresponding `warning in
  the docs`__ of ``ffi.new_handle()`` has been here since v0.8!)

.. __: using.html#extern-python
.. __: using.html#initonce
.. __: using.html#ffi-new-handle

Revision 1.14 / (download) - annotate - [select for diffs], Mon Nov 23 00:07:13 2015 UTC (8 years, 4 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2015Q4-base, pkgsrc-2015Q4
Changes since 1.13: +5 -5 lines
Diff to previous 1.13 (colored)

Update py-cffi to 1.3.1.

Changes not found.

Revision 1.13 / (download) - annotate - [select for diffs], Wed Nov 4 17:41:17 2015 UTC (8 years, 4 months ago) by agc
Branch: MAIN
Changes since 1.12: +1 -2 lines
Diff to previous 1.12 (colored)

Remove duplicate SHA512 digests that crept in.

Revision 1.12 / (download) - annotate - [select for diffs], Tue Nov 3 03:29:05 2015 UTC (8 years, 4 months ago) by agc
Branch: MAIN
Changes since 1.11: +2 -1 lines
Diff to previous 1.11 (colored)

Add SHA512 digests for distfiles for devel category

Issues found with existing distfiles:
	distfiles/eclipse-sourceBuild-srcIncluded-3.0.1.zip
	distfiles/fortran-utils-1.1.tar.gz
	distfiles/ivykis-0.39.tar.gz
	distfiles/enum-1.11.tar.gz
	distfiles/pvs-3.2-libraries.tgz
	distfiles/pvs-3.2-linux.tgz
	distfiles/pvs-3.2-solaris.tgz
	distfiles/pvs-3.2-system.tgz
No changes made to these distinfo files.

Otherwise, existing SHA1 digests verified and found to be the same on
the machine holding the existing distfiles (morden).  All existing
SHA1 digests retained for now as an audit trail.

Revision 1.11 / (download) - annotate - [select for diffs], Sun Oct 25 09:50:36 2015 UTC (8 years, 5 months ago) by wiz
Branch: MAIN
Changes since 1.10: +5 -4 lines
Diff to previous 1.10 (colored)

Update py-cffi to 1.3.0:

v1.3.0
======

* Added `ffi.memmove()`_.

* Pull request #64: out-of-line API mode: we can now declare
  floating-point types with ``typedef float... foo_t;``.  This only
  works if ``foo_t`` is a float or a double, not ``long double``.

* Issue #217: fix possible unaligned pointer manipulation, which crashes
  on some architectures (64-bit, non-x86).

* Issues #64 and #126: when using ``set_source()`` or ``verify()``,
  the ``const`` and ``restrict`` keywords are copied from the cdef
  to the generated C code; this fixes warnings by the C compiler.
  It also fixes corner cases like ``typedef const int T; T a;``
  which would previously not consider ``a`` as a constant.  (The
  cdata objects themselves are never ``const``.)

* Win32: support for ``__stdcall``.  For callbacks and function
  pointers; regular C functions still don't need to have their `calling
  convention`_ declared.

* Windows: CPython 2.7 distutils doesn't work with Microsoft's official
  Visual Studio for Python, and I'm told this is `not a bug`__.  For
  ffi.compile(), we `removed a workaround`__ that was inside cffi but
  which had unwanted side-effects.  Try saying ``import setuptools``
  first, which patches distutils...

.. _`ffi.memmove()`: using.html#memmove
.. __: https://bugs.python.org/issue23246
.. __: https://bitbucket.org/cffi/cffi/pull-requests/65/remove-_hack_at_distutils-which-imports/diff
.. _`calling convention`: using.html#windows-calling-conventions

Revision 1.10 / (download) - annotate - [select for diffs], Sun Aug 30 14:42:03 2015 UTC (8 years, 7 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2015Q3-base, pkgsrc-2015Q3
Changes since 1.9: +4 -4 lines
Diff to previous 1.9 (colored)

Update to 1.2.1:

v1.2.1

Nothing changed from v1.2.0.

v1.2.0

    Out-of-line mode: int a[][...]; can be used to declare a
    structure field or global variable which is, simultaneously,
    of total length unknown to the C compiler (the a[] part) and
    each element is itself an array of N integers, where the value
    of N is known to the C compiler (the int and [...] parts around
    it). Similarly, int a[5][...]; is supported (but probably less
    useful: remember that in C it means int (a[5])[...];).
    PyPy: the lib.some_function objects were missing the attributes
    __name__, __module__ and __doc__ that are expected e.g. by some
    decorators-management functions from functools.
    Out-of-line API mode: you can now do from _example.lib import
    x to import the name x from _example.lib, even though the lib
    object is not a standard module object. (Also works in from
    _example.lib import *, but this is even more of a hack and will
    fail if lib happens to declare a name called __all__. Note that
    * excludes the global variables; only the functions and constants
    make sense to import like this.)
    lib.__dict__ works again and gives you a copy of the dictãÂssuming
    that lib has got no symbol called precisely __dict__. (In
    general, it is safer to use dir(lib).)
    Out-of-line API mode: global variables are now fetched on demand
    at every access. It fixes issue #212 (Windows DLL variables),
    and also allows variables that are defined as dynamic macros
    (like errno) or __thread -local variables. (This change might
    also tighten the C compilerãÔ check on the variablestype.)
    Issue #209: dereferencing NULL pointers now raises RuntimeError
    instead of segfaulting. Meant as a debugging aid. The check is
    only for NULL: if you dereference random or dead pointers you
    might still get segfaults.
    Issue #152: callbacks: added an argument ffi.callback(...,
    onerror=...). If the main callback function raises an exception
    and onerror is provided, then onerror(exception, exc_value,
    traceback) is called. This is similar to writing a try: except:
    in the main callback function, but in some cases (e.g. a signal)
    an exception can occur at the very start of the callback
    functionãÃefore it had time to enter the try: except: block.
    Issue #115: added ffi.new_allocator(), which officializes
    support for alternative allocators.

Revision 1.9 / (download) - annotate - [select for diffs], Sun Jun 14 16:24:45 2015 UTC (8 years, 9 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2015Q2-base, pkgsrc-2015Q2
Changes since 1.8: +4 -4 lines
Diff to previous 1.8 (colored)

Update to 1.1.2:

1.1.2
=====

* ``ffi.gc()``: fixed a race condition in multithreaded programs
  introduced in 1.1.1


1.1.1
=====

* Out-of-line mode: ``ffi.string()``, ``ffi.buffer()`` and
  ``ffi.getwinerror()`` didn't accept their arguments as keyword
  arguments, unlike their in-line mode equivalent.  (It worked in PyPy.)

* Out-of-line ABI mode: documented a restriction__ of ``ffi.dlopen()``
  when compared to the in-line mode.

* ``ffi.gc()``: when called several times with equal pointers, it was
  accidentally registering only the last destructor, or even none at
  all depending on details.  (It was correctly registering all of them
  only in PyPy, and only with the out-of-line FFIs.)

.. __: cdef.html#dlopen-note

Revision 1.8 / (download) - annotate - [select for diffs], Sun May 31 13:09:51 2015 UTC (8 years, 10 months ago) by wiz
Branch: MAIN
Changes since 1.7: +4 -4 lines
Diff to previous 1.7 (colored)

Update to 1.1.0:

1.1.0
=====

* Out-of-line API mode: we can now declare integer types with
  ``typedef int... foo_t;``.  The exact size and signness of ``foo_t``
  is figured out by the compiler.

* Out-of-line API mode: we can now declare multidimensional arrays
  (as fields or as globals) with ``int n[...][...]``.  Before, only the
  outermost dimension would support the ``...`` syntax.

* Out-of-line ABI mode: we now support any constant declaration,
  instead of only integers whose value is given in the cdef.  Such "new"
  constants, i.e. either non-integers or without a value given in the
  cdef, must correspond to actual symbols in the lib.  At runtime they
  are looked up the first time we access them.  This is useful if the
  library defines ``extern const sometype somename;``.

* ``ffi.addressof(lib, "func_name")`` now returns a regular cdata object
  of type "pointer to function".  You can use it on any function from a
  library in API mode (in ABI mode, all functions are already regular
  cdata objects).  To support this, you need to recompile your cffi
  modules.

* Issue #198: in API mode, if you declare constants of a ``struct``
  type, what you saw from lib.CONSTANT was corrupted.

* Issue #196: ``ffi.set_source("package._ffi", None)`` would
  incorrectly generate the Python source to ``package._ffi.py`` instead
  of ``package/_ffi.py``.  Also fixed: in some cases, if the C file was
  in ``build/foo.c``, the .o file would be put in ``build/build/foo.o``.

Revision 1.7 / (download) - annotate - [select for diffs], Thu May 28 07:06:32 2015 UTC (8 years, 10 months ago) by wiz
Branch: MAIN
Changes since 1.6: +4 -4 lines
Diff to previous 1.6 (colored)

Update to 1.0.3:

1.0.3

    Same as 1.0.2, apart from doc and test fixes on some platforms.

1.0.2

    Variadic C functions (ending in a ... argument) were not
    supported in the out-of-line ABI mode. This was a bug-there
    was even a (non-working) example doing exactly that!

1.0.1

    ffi.set_source() crashed if passed a sources=[..] argument.
    Fixed by chrippa on pull request #60.
    Issue #193: if we use a struct between the first cdef() where
    it is declared and another cdef() where its fields are defined,
    then this definition was ignored.
    Enums were buggy if you used too many ... in their definition.

1.0.0

    The main news item is out-of-line module generation:
        for ABI level, with ffi.dlopen()
	for API level, which used to be with ffi.verify(), now
	deprecated

Revision 1.6 / (download) - annotate - [select for diffs], Sun Mar 15 21:08:00 2015 UTC (9 years ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2015Q1-base, pkgsrc-2015Q1
Changes since 1.5: +4 -4 lines
Diff to previous 1.5 (colored)

Update to 0.9.2:

I pushed release 0.9.2 out of the door with mostly just this fix:

https://bitbucket.org/cffi/cffi/issue/187/inconsistencies-in-ffifrom_buffer

ffi.from_buffer() was incorrectly accepting objects of type
'memoryview' containing strings, which was not intended --- it works
only on CPython, not PyPy, and it is documented that it should not
work.  Additionally, still on CPython, ffi.from_buffer() was
incorrectly rejecting objects of type 'buffer' pointing to read-only
objects, say read-only numpy arrays.  (Insert here the usual rant
against the internal mess of buffer and memoryview objects.)

Revision 1.5 / (download) - annotate - [select for diffs], Mon Mar 9 08:11:54 2015 UTC (9 years ago) by wiz
Branch: MAIN
Changes since 1.4: +4 -4 lines
Diff to previous 1.4 (colored)

Update to 0.9.1:

0.9.1

CFFI 0.9.1 was released today.  This is a bugfix release that only
concerns versions of CPython 3.4 older than last August, on
non-Windows platforms.

0.9

CFFI 0.9.0 was released today.  The readthedocs.org page is still
missing a "release 0.9" tag, which I'll add as soon as its admin pages
are back online.  I hope everything else is in order.

The documentation can be seen at
http://cffi.readthedocs.org/en/latest/ .  There are a number of small
new features in this release; for more details, search for "version
0.9" on that page.

Note that PyPy 2.5.0 includes a version of CFFI that is mislabelled as
"0.8.6"; it is actually close to 0.9.  I'll try to make sure that the
next PyPy release matches exactly a CFFI release.

Revision 1.4 / (download) - annotate - [select for diffs], Tue Jul 22 09:50:41 2014 UTC (9 years, 8 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2014Q4-base, pkgsrc-2014Q4, pkgsrc-2014Q3-base, pkgsrc-2014Q3
Changes since 1.3: +4 -4 lines
Diff to previous 1.3 (colored)

Update to 0.8.6: changes not found.

Revision 1.3 / (download) - annotate - [select for diffs], Mon Mar 31 08:30:31 2014 UTC (10 years ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2014Q2-base, pkgsrc-2014Q2
Changes since 1.2: +4 -4 lines
Diff to previous 1.2 (colored)

Update to 0.8.2:
Changes not found.

Revision 1.2 / (download) - annotate - [select for diffs], Tue Nov 26 14:04:49 2013 UTC (10 years, 4 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2014Q1-base, pkgsrc-2014Q1, pkgsrc-2013Q4-base, pkgsrc-2013Q4
Changes since 1.1: +4 -4 lines
Diff to previous 1.1 (colored)

Update to 0.8.1, changes not found.

Revision 1.1 / (download) - annotate - [select for diffs], Mon Sep 30 17:19:59 2013 UTC (10 years, 6 months ago) by wiz
Branch: MAIN

Import py27-cffi-0.7.2 as devel/py-cffi.

Foreign Function Interface for Python calling C code. The aim of
this project is to provide a convenient and reliable way of calling
C code from Python. The interface is based on LuaJIT's FFI and
follows a few principles:

o The goal is to call C code from Python. You should be able to do
  so without learning a 3rd language: every alternative requires
  you to learn their own language (Cython, SWIG) or API (ctypes).
  So we tried to assume that you know Python and C and minimize
  the extra bits of API that you need to learn.
o Keep all the Python-related logic in Python so that you don't
  need to write much C code.
o Work either at the level of the ABI (Application Binary Interface)
  or the API (Application Programming Interface). Usually, C
  libraries have a specified C API but often not an ABI.
o We try to be complete. For now some C99 constructs are not
  supported, but all C89 should be, including macros.
o We attempt to support both PyPy and CPython, with a reasonable
  path for other Python implementations like IronPython and Jython.
o Note that this project is not about embedding executable C code
  in Python, unlike Weave. This is about calling existing C libraries
  from Python.

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.




CVSweb <webmaster@jp.NetBSD.org>