From ef6a686a3c4669940e61b78df433d76f137a58fb7e3148d3cda52ccea1e5553c Mon Sep 17 00:00:00 2001 From: Marcus Meissner Date: Thu, 1 Mar 2012 17:45:57 +0000 Subject: [PATCH] Accepting request 107691 from home:msmeissn:branches:devel:libraries:c_c++ fixed 64bit bigendian issue OBS-URL: https://build.opensuse.org/request/show/107691 OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/libxml2?expand=0&rev=58 --- bigendian64.patch | 18 ++++++++++++++++++ libxml2.changes | 5 +++++ libxml2.spec | 2 ++ 3 files changed, 25 insertions(+) create mode 100644 bigendian64.patch diff --git a/bigendian64.patch b/bigendian64.patch new file mode 100644 index 0000000..7fb8ebf --- /dev/null +++ b/bigendian64.patch @@ -0,0 +1,18 @@ +--- xzlib.c.xx 2012-03-01 17:23:54.000000000 +0000 ++++ xzlib.c 2012-03-01 17:24:48.000000000 +0000 +@@ -228,9 +228,14 @@ + if (state->err != LZMA_OK) + return -1; + if (state->eof == 0) { ++ /* avail_in is size_t, which is not necessary sizeof(unsigned) */ ++ unsigned tmp = strm->avail_in; + if (xz_load(state, state->in, state->size, +- (unsigned *) &(strm->avail_in)) == -1) ++ &tmp) == -1) { ++ strm->avail_in = tmp; + return -1; ++ } ++ strm->avail_in = tmp; + strm->next_in = state->in; + } + return 0; diff --git a/libxml2.changes b/libxml2.changes index b130392..264a2de 100644 --- a/libxml2.changes +++ b/libxml2.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Mar 1 18:36:33 CET 2012 - meissner@suse.de + +- fixed a 64bit big endian bug in the file reader. + ------------------------------------------------------------------- Sat Feb 25 13:50:54 UTC 2012 - coolo@suse.com diff --git a/libxml2.spec b/libxml2.spec index b990cfe..e2dbc35 100644 --- a/libxml2.spec +++ b/libxml2.spec @@ -28,6 +28,7 @@ Url: http://xmlsoft.org # Source ftp://xmlsoft.org/libxml2/libxml2-git-snapshot.tar.gz changes every day Source: libxml2-git-snapshot.tar.gz Source2: baselibs.conf +Patch0: bigendian64.patch BuildRequires: pkg-config BuildRequires: readline-devel BuildRequires: xz-devel @@ -127,6 +128,7 @@ progress. %prep %setup -q -n %{name}-2.7.8 +%patch0 -p0 %build %configure --disable-static \