[js/f16] add patch from bugzilla 537701, fixes PPC failures

Karsten Hopp karsten at fedoraproject.org
Fri Dec 2 17:05:34 UTC 2011


commit 6fc03aa62b9d61882f46472853059078cffc0d38
Author: Karsten Hopp <karsten at redhat.com>
Date:   Fri Dec 2 18:06:28 2011 +0100

    add patch from bugzilla 537701, fixes PPC failures

 js-1.8.5-537701.patch |   39 +++++++++++++++++++++++++++++++++++++++
 js.spec               |    7 ++++++-
 2 files changed, 45 insertions(+), 1 deletions(-)
---
diff --git a/js-1.8.5-537701.patch b/js-1.8.5-537701.patch
new file mode 100644
index 0000000..add3e6d
--- /dev/null
+++ b/js-1.8.5-537701.patch
@@ -0,0 +1,39 @@
+diff -up js-1.8.5/js/src/jsval.h.pad-the-structs-and-asserts js-1.8.5/js/src/jsval.h
+--- js-1.8.5/js/src/jsval.h.pad-the-structs-and-asserts	2011-11-28 12:46:32.811556132 -0600
++++ js-1.8.5/js/src/jsval.h	2011-11-28 12:46:43.493448233 -0600
+@@ -343,11 +343,11 @@ typedef union jsval_layout
+         uint64             payload47 : 47;
+     } debugView;
+     struct {
++        uint32             padding;
+         union {
+             int32          i32;
+             uint32         u32;
+             JSWhyMagic     why;
+-            jsuword        word;
+         } payload;
+     } s;
+     double asDouble;
+diff -up js-1.8.5/js/src/jsvalue.h.pad-the-structs-and-asserts js-1.8.5/js/src/jsvalue.h
+--- js-1.8.5/js/src/jsvalue.h.pad-the-structs-and-asserts	2011-11-28 12:46:37.246509255 -0600
++++ js-1.8.5/js/src/jsvalue.h	2011-11-28 12:46:43.495448203 -0600
+@@ -291,7 +291,6 @@ JSVAL_EXTRACT_NON_DOUBLE_TAG_IMPL(jsval_
+ }
+ 
+ #ifdef __cplusplus
+-JS_STATIC_ASSERT(offsetof(jsval_layout, s.payload) == 0);
+ JS_STATIC_ASSERT((JSVAL_TYPE_NONFUNOBJ & 0xF) == JSVAL_TYPE_OBJECT);
+ JS_STATIC_ASSERT((JSVAL_TYPE_FUNOBJ & 0xF) == JSVAL_TYPE_OBJECT);
+ #endif
+@@ -729,7 +728,11 @@ class Value
+     }
+ 
+     const jsuword *payloadWord() const {
++#if JS_BITS_PER_WORD == 32
+         return &data.s.payload.word;
++#elif JS_BITS_PER_WORD == 64
++	return &data.asBits;
++#endif
+     }
+ 
+   private:
diff --git a/js.spec b/js.spec
index 87f6195..b307a48 100644
--- a/js.spec
+++ b/js.spec
@@ -4,7 +4,7 @@ Summary:		JavaScript interpreter and libraries
 Name:		js
 Epoch:		1
 Version:		1.8.5
-Release:		7%{?hgdate:.hg%{hgdate}}%{?dist}
+Release:		8%{?hgdate:.hg%{hgdate}}%{?dist}
 # The sources are triple licensed, but when we link against readline which is
 # GPL, the result can only be GPL.
 %if 0%{?_without_readline:1}
@@ -18,6 +18,7 @@ Source0:		http://ftp.mozilla.org/pub/mozilla.org/js/js185-1.0.0.tar.gz
 Patch0:			js-1.8.5-64bit-big-endian.patch
 Patch1:			js-1.8.5-secondary-jit.patch
 Patch2:			js185-destdir.patch
+Patch3:			js-1.8.5-537701.patch
 Provides:		libjs = %{version}-%{release}
 BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root
 Buildrequires:	nspr-devel >= 4.7
@@ -55,6 +56,7 @@ you will need to install %{name}-devel.
 %patch0 -p2 -b .64bit-big-endian
 %patch1 -p2 -b .secondary-jit
 %patch2 -p0 -b .destdir
+%patch3 -p1 -b .537701
 cd js
 
 # Rm parts with spurios licenses, binaries
@@ -138,6 +140,9 @@ rm -rf %{buildroot}
 %{_includedir}/js
 
 %changelog
+* Fri Dec 02 2011 Karsten Hopp <karsten at redhat.com> 1.8.5-8
+- add patch from bugzilla 537701, fixes PPC failures
+
 * Wed Jun 22 2011 Colin Walters <walters at verbum.org> - 1:1.8.5-6
 - Include mozjs185.pc, clean up build
 - Based on work from Christopher Aillon <caillon at redhat.com>


More information about the scm-commits mailing list