From 0b8c8ac03e24df873a0324fca0221e6ba68e6ee7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dan=20Hor=C3=A1k?= Date: Tue, 12 Jul 2011 14:56:00 +0200 Subject: [PATCH] fix build on big endian arches --- msgpack-python-0.1.9-endian.patch | 12 ++++++++++++ python-msgpack.spec | 7 ++++++- 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 msgpack-python-0.1.9-endian.patch diff --git a/msgpack-python-0.1.9-endian.patch b/msgpack-python-0.1.9-endian.patch new file mode 100644 index 0000000..bdd6c40 --- /dev/null +++ b/msgpack-python-0.1.9-endian.patch @@ -0,0 +1,12 @@ +diff -up msgpack-python-0.1.9/msgpack/pack_template.h.endian msgpack-python-0.1.9/msgpack/pack_template.h +--- msgpack-python-0.1.9/msgpack/pack_template.h.endian 2011-07-12 14:37:47.000000000 +0200 ++++ msgpack-python-0.1.9/msgpack/pack_template.h 2011-07-12 14:38:10.000000000 +0200 +@@ -21,7 +21,7 @@ + #define TAKE8_16(d) ((uint8_t*)&d)[0] + #define TAKE8_32(d) ((uint8_t*)&d)[0] + #define TAKE8_64(d) ((uint8_t*)&d)[0] +-#elif __BIG_ENDIAN__ ++#else /* __BIG_ENDIAN__ */ + #define TAKE8_8(d) ((uint8_t*)&d)[0] + #define TAKE8_16(d) ((uint8_t*)&d)[1] + #define TAKE8_32(d) ((uint8_t*)&d)[3] diff --git a/python-msgpack.spec b/python-msgpack.spec index f961e27..0caa788 100644 --- a/python-msgpack.spec +++ b/python-msgpack.spec @@ -6,13 +6,14 @@ Name: python-%{srcname} Version: 0.1.9 -Release: 2%{?dist} +Release: 3%{?dist} Summary: A Python MessagePack (de)serializer Group: Development/Languages License: ASL 2.0 URL: http://pypi.python.org/pypi/msgpack-python/ Source0: http://pypi.python.org/packages/source/m/%{srcname}-python/%{srcname}-python-%{version}.tar.gz +Patch0: msgpack-python-0.1.9-endian.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -35,6 +36,7 @@ This is a Python (de)serializer for MessagePack. %prep %setup -q -n %{srcname}-python-%{version} +%patch0 -p1 -b .endian %build @@ -62,6 +64,9 @@ rm -rf %{buildroot} %changelog +* Tue Jul 12 2011 Dan HorĂ¡k - 0.1.9-3 +- fix build on big endian arches + * Fri Jun 24 2011 Fabian Affolter - 0.1.9-2 - Tests are failing, they are not active at the moment - Filtering added