Hi, On 09/11/17 09:42, Thomas Goirand wrote: > On 11/08/2017 10:52 AM, James Cowgill wrote: >> Hi, >> >> On 07/11/17 22:29, Thomas Goirand wrote: >>> Hi James, >>> >>> I tried to build on zelenka.debian.org, which is a s390 porter box (big >>> endian), and it failed even more. >> >> I only tested on mips (where my patch works). Maybe the other failures >> are specific to 64-bit big endian? Eg: s390x, ppc64 and sparc64 all >> failed the same way which is different from the way mips and powerpc fail. >> >> Thanks, >> James > > Hi, > > I tried again, and with or without your patch, there's always 12 unit > test failures on s390x, so I guess you must be right. > > Any chance you could attempt to help again?
I had a small look :) This patch works on s390x. One of the variables passed to PyArg_ParseTupleAndKeywords was declared with the wrong time. Unfortunately there's no type checking here. James
--- python-lz4-0.10.1+dfsg1.orig/lz4/frame/_frame.c
+++ python-lz4-0.10.1+dfsg1/lz4/frame/_frame.c
@@ -400,7 +400,7 @@ compress_update (PyObject * Py_UNUSED (s
{
PyObject *py_context = NULL;
const char *source = NULL;
- unsigned long source_size = 0;
+ int source_size = 0;
struct compression_context *context;
size_t compressed_bound;
char *destination_buffer;
@@ -630,7 +630,7 @@ get_frame_info (PyObject * Py_UNUSED (se
return NULL;
}
- return Py_BuildValue ("{s:i,s:i,s:i,s:i,s:i}",
+ return Py_BuildValue ("{s:i,s:i,s:i,s:i,s:K}",
"blockSizeID", frame_info.blockSizeID,
"blockMode", frame_info.blockMode,
"contentChecksumFlag", frame_info.contentChecksumFlag,
signature.asc
Description: OpenPGP digital signature

