Wed Sep 9 17:01:07 2009 UTC ()
sync patches from www/firefox


(tnn)
diff -r1.13 -r1.14 pkgsrc/devel/xulrunner/Makefile
diff -r1.3 -r1.4 pkgsrc/devel/xulrunner/distinfo
diff -r0 -r1.1 pkgsrc/devel/xulrunner/patches/patch-na
diff -r0 -r1.1 pkgsrc/devel/xulrunner/patches/patch-nb
diff -r0 -r1.1 pkgsrc/devel/xulrunner/patches/patch-nc
diff -r0 -r1.1 pkgsrc/devel/xulrunner/patches/patch-nd

cvs diff -r1.13 -r1.14 pkgsrc/devel/xulrunner/Attic/Makefile (expand / switch to unified diff)

--- pkgsrc/devel/xulrunner/Attic/Makefile 2009/08/26 19:56:54 1.13
+++ pkgsrc/devel/xulrunner/Attic/Makefile 2009/09/09 17:01:07 1.14
@@ -1,20 +1,20 @@ @@ -1,20 +1,20 @@
1# $NetBSD: Makefile,v 1.13 2009/08/26 19:56:54 sno Exp $ 1# $NetBSD: Makefile,v 1.14 2009/09/09 17:01:07 tnn Exp $
2# 2#
3 3
4DISTNAME= xulrunner-${XULRUNNER_VER}-source 4DISTNAME= xulrunner-${XULRUNNER_VER}-source
5PKGNAME= ${DISTNAME:S/-source//} 5PKGNAME= ${DISTNAME:S/-source//}
6XULRUNNER_VER= 1.9.1.2 6XULRUNNER_VER= 1.9.1.2
7PKGREVISION= 3 7PKGREVISION= 4
8CATEGORIES= devel www 8CATEGORIES= devel www
9MASTER_SITES= ${MASTER_SITE_MOZILLA:=xulrunner/releases/${XULRUNNER_VER}/source/} 9MASTER_SITES= ${MASTER_SITE_MOZILLA:=xulrunner/releases/${XULRUNNER_VER}/source/}
10EXTRACT_SUFX= .tar.bz2 10EXTRACT_SUFX= .tar.bz2
11 11
12MAINTAINER= pkgsrc-users@NetBSD.org 12MAINTAINER= pkgsrc-users@NetBSD.org
13HOMEPAGE= http://developer.mozilla.org/en/docs/XULRunner 13HOMEPAGE= http://developer.mozilla.org/en/docs/XULRunner
14COMMENT= XML User Interface Language runtime environment 14COMMENT= XML User Interface Language runtime environment
15 15
16WRKSRC= ${WRKDIR}/mozilla-1.9.1 16WRKSRC= ${WRKDIR}/mozilla-1.9.1
17GNU_CONFIGURE= yes 17GNU_CONFIGURE= yes
18USE_TOOLS+= pkg-config perl gmake autoconf213 18USE_TOOLS+= pkg-config perl gmake autoconf213
19USE_LANGUAGES= c c++ 19USE_LANGUAGES= c c++
20 20

cvs diff -r1.3 -r1.4 pkgsrc/devel/xulrunner/Attic/distinfo (expand / switch to unified diff)

--- pkgsrc/devel/xulrunner/Attic/distinfo 2009/08/06 10:42:50 1.3
+++ pkgsrc/devel/xulrunner/Attic/distinfo 2009/09/09 17:01:07 1.4
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1$NetBSD: distinfo,v 1.3 2009/08/06 10:42:50 tnn Exp $ 1$NetBSD: distinfo,v 1.4 2009/09/09 17:01:07 tnn Exp $
2 2
3SHA1 (xulrunner-1.9.1.2-source.tar.bz2) = 6439923ff9d316297926ebe193bac3ac1a41b494 3SHA1 (xulrunner-1.9.1.2-source.tar.bz2) = 6439923ff9d316297926ebe193bac3ac1a41b494
4RMD160 (xulrunner-1.9.1.2-source.tar.bz2) = d5e0b5f0e8b19b216394584ccabf37d776b89a39 4RMD160 (xulrunner-1.9.1.2-source.tar.bz2) = d5e0b5f0e8b19b216394584ccabf37d776b89a39
5Size (xulrunner-1.9.1.2-source.tar.bz2) = 46787928 bytes 5Size (xulrunner-1.9.1.2-source.tar.bz2) = 46787928 bytes
6SHA1 (patch-aa) = 3bcbced4642b8814f5255973d45a0ac1eaded64d 6SHA1 (patch-aa) = 3bcbced4642b8814f5255973d45a0ac1eaded64d
7SHA1 (patch-ab) = 5331bae45501013d3ca13d161226e311bc10aafe 7SHA1 (patch-ab) = 5331bae45501013d3ca13d161226e311bc10aafe
8SHA1 (patch-ac) = e50356963fd235ea11fa45baae356fcf21c6669d 8SHA1 (patch-ac) = e50356963fd235ea11fa45baae356fcf21c6669d
9SHA1 (patch-ad) = 7afb960af4e4a311481e7a7b25008ca9b9f7fba1 9SHA1 (patch-ad) = 7afb960af4e4a311481e7a7b25008ca9b9f7fba1
10SHA1 (patch-ae) = 6679dd9c28f8029cc0ed2a32ae60da696099f351 10SHA1 (patch-ae) = 6679dd9c28f8029cc0ed2a32ae60da696099f351
11SHA1 (patch-af) = 13a9617cd2894cf342487d2a9cfe8cf3066ba0df 11SHA1 (patch-af) = 13a9617cd2894cf342487d2a9cfe8cf3066ba0df
12SHA1 (patch-ag) = 62e55040130d5e6cfb10b839fce6abd40a902f08 12SHA1 (patch-ag) = 62e55040130d5e6cfb10b839fce6abd40a902f08
13SHA1 (patch-ah) = 5f8bf19d5ac5ea7e263366a56d10d2eeeee61bac 13SHA1 (patch-ah) = 5f8bf19d5ac5ea7e263366a56d10d2eeeee61bac
14SHA1 (patch-ai) = 3444882b0f7f4b63273d8888af88be35ae60933a 14SHA1 (patch-ai) = 3444882b0f7f4b63273d8888af88be35ae60933a
@@ -28,26 +28,30 @@ SHA1 (patch-av) = e22c544894123a6ab8fc42 @@ -28,26 +28,30 @@ SHA1 (patch-av) = e22c544894123a6ab8fc42
28SHA1 (patch-ma) = a20b263ff14c841fd0ae1634962b90a41173b524 28SHA1 (patch-ma) = a20b263ff14c841fd0ae1634962b90a41173b524
29SHA1 (patch-mb) = 05298c1ec02363ff0bada87337cf0ccb5b42c55b 29SHA1 (patch-mb) = 05298c1ec02363ff0bada87337cf0ccb5b42c55b
30SHA1 (patch-md) = 6bf5242245b17fbd868a6a978eb5849726f81393 30SHA1 (patch-md) = 6bf5242245b17fbd868a6a978eb5849726f81393
31SHA1 (patch-me) = f5a8e29fc004ef7696b67d260384ab23fd1658c2 31SHA1 (patch-me) = f5a8e29fc004ef7696b67d260384ab23fd1658c2
32SHA1 (patch-mf) = 10e0d9d665324a1a4aa713e6c2447ddda1d7c605 32SHA1 (patch-mf) = 10e0d9d665324a1a4aa713e6c2447ddda1d7c605
33SHA1 (patch-mg) = 75ddcceaffae0bdb6ecb4efd1b5ffca68a8ae8a8 33SHA1 (patch-mg) = 75ddcceaffae0bdb6ecb4efd1b5ffca68a8ae8a8
34SHA1 (patch-mi) = 787cb043bb7e687936afaf8f0c67b6b3a7b03e5b 34SHA1 (patch-mi) = 787cb043bb7e687936afaf8f0c67b6b3a7b03e5b
35SHA1 (patch-mj) = 197fab0e00256dedc8a5f181ee0d0d6e42d8177f 35SHA1 (patch-mj) = 197fab0e00256dedc8a5f181ee0d0d6e42d8177f
36SHA1 (patch-mk) = 793dfa16e19e213d78995c893a28bc0d514135d9 36SHA1 (patch-mk) = 793dfa16e19e213d78995c893a28bc0d514135d9
37SHA1 (patch-ml) = 9003af056e5b671b2345d0a75e99836746369c00 37SHA1 (patch-ml) = 9003af056e5b671b2345d0a75e99836746369c00
38SHA1 (patch-mm) = faabab8816522bd9a74c2e6e65b2ae3d791affe0 38SHA1 (patch-mm) = faabab8816522bd9a74c2e6e65b2ae3d791affe0
39SHA1 (patch-mn) = 17641f46ecf1019f3cc02583a22baa9f9a327d1f 39SHA1 (patch-mn) = 17641f46ecf1019f3cc02583a22baa9f9a327d1f
40SHA1 (patch-mp) = 33128f10b6146419bcebd85f7e6e7fa72e770be1 40SHA1 (patch-mp) = 33128f10b6146419bcebd85f7e6e7fa72e770be1
 41SHA1 (patch-na) = 10a09ddb5de67c3cc2f605c75de7ac2e30a92ae7
 42SHA1 (patch-nb) = 6b1719219df7cdd7bf5335fcf7f48567a37ffa87
 43SHA1 (patch-nc) = f2a3cc803a114702e856947c25fd79baa85b0e26
 44SHA1 (patch-nd) = f5156ca4d1e61dd1b355bbaa5ebd9cc490d8d865
41SHA1 (patch-pa) = d03ef72ea7efceef5e2f12a245950b9a587ace82 45SHA1 (patch-pa) = d03ef72ea7efceef5e2f12a245950b9a587ace82
42SHA1 (patch-pb) = 32da908450ab463971bea1aafc9d6e37b1e78c0f 46SHA1 (patch-pb) = 32da908450ab463971bea1aafc9d6e37b1e78c0f
43SHA1 (patch-pc) = baa2c72df21c6ddda65bdb435561323f4ee008ff 47SHA1 (patch-pc) = baa2c72df21c6ddda65bdb435561323f4ee008ff
44SHA1 (patch-pd) = b87adef8cfb53d4a1926f4bab5481dd1b9cf14ab 48SHA1 (patch-pd) = b87adef8cfb53d4a1926f4bab5481dd1b9cf14ab
45SHA1 (patch-pe) = 3e4db1032a1e1f26f3a4e86653804b435aaf3ee8 49SHA1 (patch-pe) = 3e4db1032a1e1f26f3a4e86653804b435aaf3ee8
46SHA1 (patch-pf) = 95b3f07dfd0e3de9961181ec6e42f7174180942d 50SHA1 (patch-pf) = 95b3f07dfd0e3de9961181ec6e42f7174180942d
47SHA1 (patch-pg) = 33f0664512c94b1f1b7b65f43accc1dae457a2d0 51SHA1 (patch-pg) = 33f0664512c94b1f1b7b65f43accc1dae457a2d0
48SHA1 (patch-xa) = ae5ed1f0fb9a0fd45242a94739853b199ed7da72 52SHA1 (patch-xa) = ae5ed1f0fb9a0fd45242a94739853b199ed7da72
49SHA1 (patch-xb) = c09bd676d21bef02e04c68c2362e32f408ea9201 53SHA1 (patch-xb) = c09bd676d21bef02e04c68c2362e32f408ea9201
50SHA1 (patch-xc) = 6e1d6b21d7ded744b082173ea6f35b45999fa965 54SHA1 (patch-xc) = 6e1d6b21d7ded744b082173ea6f35b45999fa965
51SHA1 (patch-xd) = 2ddf436186ccebab28380b9e80f52f061ca3d73e 55SHA1 (patch-xd) = 2ddf436186ccebab28380b9e80f52f061ca3d73e
52SHA1 (patch-xe) = 1bcd9def6f9636fa9deb0edb994e5672529b615b 56SHA1 (patch-xe) = 1bcd9def6f9636fa9deb0edb994e5672529b615b
53SHA1 (patch-xf) = 756c17e4add771f4cc2a2e6f2ad576f458ee02f0 57SHA1 (patch-xf) = 756c17e4add771f4cc2a2e6f2ad576f458ee02f0

File Added: pkgsrc/devel/xulrunner/patches/Attic/patch-na
$NetBSD: patch-na,v 1.1 2009/09/09 17:01:07 tnn Exp $

# reported upstream as:
#   https://bugzilla.mozilla.org/show_bug.cgi?id=512802

--- js/src/jsscript.cpp.orig	2009-08-24 01:32:14.000000000 +0200
+++ js/src/jsscript.cpp	2009-08-24 01:36:20.000000000 +0200
@@ -1370,19 +1370,49 @@ js_NewScript(JSContext *cx, uint32 lengt
     size_t size, vectorSize;
     JSScript *script;
     uint8 *cursor;
+#ifdef _LP64
+#define LP64_ALIGN(V)  if ((V) & 7) (V) = (((V)|7) + 1)
+#define LP64_ALIGNP(P)  if ((uintptr_t)(P) & 7) (P) = (uint8*)(((uintptr_t)(P)|7) + 1)
+#else
+#define LP64_ALIGN(V)
+#define LP64_ALIGNP(V)
+#endif
 
-    size = sizeof(JSScript) +
-           sizeof(JSAtom *) * natoms +
-           length * sizeof(jsbytecode) +
-           nsrcnotes * sizeof(jssrcnote);
-    if (nobjects != 0)
-        size += sizeof(JSObjectArray) + nobjects * sizeof(JSObject *);
-    if (nupvars != 0)
-        size += sizeof(JSUpvarArray) + nupvars * sizeof(uint32);
-    if (nregexps != 0)
-        size += sizeof(JSObjectArray) + nregexps * sizeof(JSObject *);
-    if (ntrynotes != 0)
-        size += sizeof(JSTryNoteArray) + ntrynotes * sizeof(JSTryNote);
+    size = sizeof(JSScript);
+    if (nobjects != 0) {
+	LP64_ALIGN(size);
+        size += sizeof(JSObjectArray);
+    }
+    if (nupvars != 0) {
+	LP64_ALIGN(size);
+        size += sizeof(JSUpvarArray);
+    }
+    if (nregexps != 0) {
+	LP64_ALIGN(size);
+        size += sizeof(JSObjectArray);
+    }
+    if (ntrynotes != 0) {
+	LP64_ALIGN(size);
+        size += sizeof(JSTryNoteArray);
+    }
+    if (natoms != 0) {
+	LP64_ALIGN(size);
+	size += sizeof(JSAtom *) * natoms;
+    }
+    if (nobjects != 0) {
+	LP64_ALIGN(size);
+        size += nobjects * sizeof(JSObject *);
+    }
+    if (nupvars != 0) {
+        size += nupvars * sizeof(uint32);
+    }
+    if (nregexps != 0) {
+	LP64_ALIGN(size);
+        size += nregexps * sizeof(JSObject *);
+    }
+    size += length * sizeof(jsbytecode) +
+	nsrcnotes * sizeof(jssrcnote) +
+	ntrynotes * sizeof(JSTryNote);
 
     script = (JSScript *) JS_malloc(cx, size);
     if (!script)
@@ -1393,23 +1423,28 @@ js_NewScript(JSContext *cx, uint32 lengt
 
     cursor = (uint8 *)script + sizeof(JSScript);
     if (nobjects != 0) {
+	LP64_ALIGNP(cursor);
         script->objectsOffset = (uint8)(cursor - (uint8 *)script);
         cursor += sizeof(JSObjectArray);
     }
     if (nupvars != 0) {
+	LP64_ALIGNP(cursor);
         script->upvarsOffset = (uint8)(cursor - (uint8 *)script);
         cursor += sizeof(JSUpvarArray);
     }
     if (nregexps != 0) {
+	LP64_ALIGNP(cursor);
         script->regexpsOffset = (uint8)(cursor - (uint8 *)script);
         cursor += sizeof(JSObjectArray);
     }
     if (ntrynotes != 0) {
+	LP64_ALIGNP(cursor);
         script->trynotesOffset = (uint8)(cursor - (uint8 *)script);
         cursor += sizeof(JSTryNoteArray);
     }
 
     if (natoms != 0) {
+	LP64_ALIGNP(cursor);
         script->atomMap.length = natoms;
         script->atomMap.vector = (JSAtom **)cursor;
         vectorSize = natoms * sizeof(script->atomMap.vector[0]);
@@ -1423,6 +1458,7 @@ js_NewScript(JSContext *cx, uint32 lengt
     }
 
     if (nobjects != 0) {
+	LP64_ALIGNP(cursor);
         JS_SCRIPT_OBJECTS(script)->length = nobjects;
         JS_SCRIPT_OBJECTS(script)->vector = (JSObject **)cursor;
         vectorSize = nobjects * sizeof(JS_SCRIPT_OBJECTS(script)->vector[0]);
@@ -1431,6 +1467,7 @@ js_NewScript(JSContext *cx, uint32 lengt
     }
 
     if (nupvars != 0) {
+	LP64_ALIGNP(cursor);
         JS_SCRIPT_UPVARS(script)->length = nupvars;
         JS_SCRIPT_UPVARS(script)->vector = (uint32 *)cursor;
         vectorSize = nupvars * sizeof(JS_SCRIPT_UPVARS(script)->vector[0]);
@@ -1439,6 +1476,7 @@ js_NewScript(JSContext *cx, uint32 lengt
     }
 
     if (nregexps != 0) {
+	LP64_ALIGNP(cursor);
         JS_SCRIPT_REGEXPS(script)->length = nregexps;
         JS_SCRIPT_REGEXPS(script)->vector = (JSObject **)cursor;
         vectorSize = nregexps * sizeof(JS_SCRIPT_REGEXPS(script)->vector[0]);

File Added: pkgsrc/devel/xulrunner/patches/Attic/patch-nb
$NetBSD: patch-nb,v 1.1 2009/09/09 17:01:07 tnn Exp $

# reported upstream as:
#    https://bugzilla.mozilla.org/show_bug.cgi?id=512792

--- media/liboggz/src/liboggz/oggz_byteorder.h.orig	2009-08-26 22:28:18.000000000 +0200
+++ media/liboggz/src/liboggz/oggz_byteorder.h	2009-08-26 22:41:39.000000000 +0200
@@ -123,4 +123,27 @@ int32_be_at (unsigned char *c)
   return (c [0] <<  24) + (c [1] <<  16) + (c [2] <<  8) + c [3] ;
 }
 
+static ogg_uint32_t
+_le_32_at (unsigned char *c)
+{
+  return (c [3] <<  24) + (c [2] <<  16) + (c [1] <<  8) + c [0] ;
+}
+
+#ifdef HAVE_STDINT_H
+#include <stdint.h>
+#endif
+static uint64_t
+_le_64_at (unsigned char *c)
+{
+  return (uint64_t)((uint64_t)c[7] <<  56) + ((uint64_t)c[6] <<  48)
+    + ((uint64_t)c[5] <<  40) + ((uint64_t)c[4] << 32)
+    + (c [3] <<  24) + (c [2] <<  16) + (c [1] <<  8) + c [0] ;
+}
+
+static ogg_uint16_t
+_be_16_at (unsigned char *c)
+{
+  return (c [0] <<  8) + c [1] ;
+}
+
 #endif /* __OGGZ_BYTEORDER_H__ */

File Added: pkgsrc/devel/xulrunner/patches/Attic/patch-nc
$NetBSD: patch-nc,v 1.1 2009/09/09 17:01:07 tnn Exp $

# reported upstream as:
#    https://bugzilla.mozilla.org/show_bug.cgi?id=512792

--- media/liboggz/src/liboggz/oggz_auto.c.orig	2009-08-26 22:20:35.000000000 +0200
+++ media/liboggz/src/liboggz/oggz_auto.c	2009-08-26 22:40:51.000000000 +0200
@@ -62,9 +62,9 @@ int oggz_set_metric_linear (OGGZ * oggz,
 			    ogg_int64_t granule_rate_numerator,
 			    ogg_int64_t granule_rate_denominator);
 
-#define INT16_BE_AT(x) _be_16((*(ogg_int32_t *)(x)))
-#define INT32_LE_AT(x) _le_32((*(ogg_int32_t *)(x)))
-#define INT64_LE_AT(x) _le_64((*(ogg_int64_t *)(x)))
+#define INT16_BE_AT(x) _be_16_at(x)
+#define INT32_LE_AT(x) _le_32_at(x)
+#define INT64_LE_AT(x) _le_64_at(x)
 
 static int
 oggz_stream_set_numheaders (OGGZ * oggz, long serialno, int numheaders)

File Added: pkgsrc/devel/xulrunner/patches/Attic/patch-nd
$NetBSD: patch-nd,v 1.1 2009/09/09 17:01:07 tnn Exp $

# reported upstream as
#   https://bugzilla.mozilla.org/show_bug.cgi?id=514002

--- gfx/qcms/iccread.c.orig	2009-07-30 17:30:16.000000000 +0200
+++ gfx/qcms/iccread.c	2009-09-01 21:29:29.000000000 +0200
@@ -23,6 +23,7 @@
 #include <math.h>
 #include <assert.h>
 #include <stdlib.h>
+#include <string.h>
 #include "qcmsint.h"
 
 //XXX: use a better typename
@@ -84,7 +85,9 @@ static uint32_t read_u32(struct mem_sour
 		invalid_source(mem, "Invalid offset");
 		return 0;
 	} else {
-		return be32_to_cpu(*(__be32*)(mem->buf + offset));
+		uint32_t v;
+		memcpy(&v, mem->buf + offset, 4);
+		return be32_to_cpu(v);
 	}
 }
 
@@ -94,7 +97,9 @@ static uint16_t read_u16(struct mem_sour
 		invalid_source(mem, "Invalid offset");
 		return 0;
 	} else {
-		return be16_to_cpu(*(__be16*)(mem->buf + offset));
+		uint16_t v;
+		memcpy(&v, mem->buf + offset, 2);
+		return be16_to_cpu(v);
 	}
 }