Hello community, here is the log from the commit of package python-datrie for openSUSE:Factory checked in at 2018-03-24 16:04:36 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-datrie (Old) and /work/SRC/openSUSE:Factory/.python-datrie.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-datrie" Sat Mar 24 16:04:36 2018 rev:3 rq:587594 version:0.7.1 Changes: -------- --- /work/SRC/openSUSE:Factory/python-datrie/python-datrie.changes 2017-04-28 10:52:52.378603521 +0200 +++ /work/SRC/openSUSE:Factory/.python-datrie.new/python-datrie.changes 2018-03-24 16:04:38.542722327 +0100 @@ -1,0 +2,6 @@ +Thu Mar 15 18:10:19 CET 2018 - [email protected] + +- add datrie-bigendian.patch (bsc#1085526) + to use utf_32_be instead of utf_32_le on bigendian machines + +------------------------------------------------------------------- New: ---- datrie-bigendian.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-datrie.spec ++++++ --- /var/tmp/diff_new_pack.sLgcSU/_old 2018-03-24 16:04:39.150700410 +0100 +++ /var/tmp/diff_new_pack.sLgcSU/_new 2018-03-24 16:04:39.150700410 +0100 @@ -1,7 +1,7 @@ # # spec file for package python-datrie # -# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -25,6 +25,8 @@ Group: Development/Languages/Python Url: https://github.com/kmike/datrie Source: https://files.pythonhosted.org/packages/source/d/datrie/datrie-%{version}.tar.gz +Patch0: datrie-bigendian.patch +BuildRequires: %{python_module Cython >= 0.26.1} BuildRequires: %{python_module devel} BuildRequires: %{python_module hypothesis} BuildRequires: %{python_module pytest-runner} @@ -40,6 +42,10 @@ %prep %setup -q -n datrie-%{version} +%patch0 -p1 +pushd src +cython datrie.pyx +popd %build %python_build ++++++ datrie-bigendian.patch ++++++ --- datrie-0.7.1/src/datrie.pyx 2018/03/15 17:07:17 1.1 +++ datrie-0.7.1/src/datrie.pyx 2018/03/15 17:09:19 @@ -1108,8 +1108,10 @@ if length == 0: length = cdatrie.alpha_char_strlen(key)*sizeof(cdatrie.AlphaChar) cdef char* c_str = <char*> key - return c_str[:length].decode('utf_32_le') - + if sys.byteorder == "big": + return c_str[:length].decode('utf_32_be') + else: + return c_str[:length].decode('utf_32_le') def to_ranges(lst): """
