[arch-commits] Commit in xulrunner/repos (20 files)

Evangelos Foutras foutrelis at archlinux.org
Sun Nov 27 15:19:05 UTC 2016


    Date: Sunday, November 27, 2016 @ 15:19:05
  Author: foutrelis
Revision: 197034

archrelease: copy trunk to community-staging-i686, community-staging-x86_64

Added:
  xulrunner/repos/community-staging-i686/
  xulrunner/repos/community-staging-i686/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch
    (from rev 197033, xulrunner/trunk/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch)
  xulrunner/repos/community-staging-i686/LFS_graphite2_harfbuzz.patch
    (from rev 197033, xulrunner/trunk/LFS_graphite2_harfbuzz.patch)
  xulrunner/repos/community-staging-i686/PKGBUILD
    (from rev 197033, xulrunner/trunk/PKGBUILD)
  xulrunner/repos/community-staging-i686/freetype261.patch
    (from rev 197033, xulrunner/trunk/freetype261.patch)
  xulrunner/repos/community-staging-i686/gcc6.diff
    (from rev 197033, xulrunner/trunk/gcc6.diff)
  xulrunner/repos/community-staging-i686/mozconfig
    (from rev 197033, xulrunner/trunk/mozconfig)
  xulrunner/repos/community-staging-i686/mozilla-pkgconfig.patch
    (from rev 197033, xulrunner/trunk/mozilla-pkgconfig.patch)
  xulrunner/repos/community-staging-i686/shared-libs.patch
    (from rev 197033, xulrunner/trunk/shared-libs.patch)
  xulrunner/repos/community-staging-i686/unbreak-plugin-build.patch
    (from rev 197033, xulrunner/trunk/unbreak-plugin-build.patch)
  xulrunner/repos/community-staging-x86_64/
  xulrunner/repos/community-staging-x86_64/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch
    (from rev 197033, xulrunner/trunk/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch)
  xulrunner/repos/community-staging-x86_64/LFS_graphite2_harfbuzz.patch
    (from rev 197033, xulrunner/trunk/LFS_graphite2_harfbuzz.patch)
  xulrunner/repos/community-staging-x86_64/PKGBUILD
    (from rev 197033, xulrunner/trunk/PKGBUILD)
  xulrunner/repos/community-staging-x86_64/freetype261.patch
    (from rev 197033, xulrunner/trunk/freetype261.patch)
  xulrunner/repos/community-staging-x86_64/gcc6.diff
    (from rev 197033, xulrunner/trunk/gcc6.diff)
  xulrunner/repos/community-staging-x86_64/mozconfig
    (from rev 197033, xulrunner/trunk/mozconfig)
  xulrunner/repos/community-staging-x86_64/mozilla-pkgconfig.patch
    (from rev 197033, xulrunner/trunk/mozilla-pkgconfig.patch)
  xulrunner/repos/community-staging-x86_64/shared-libs.patch
    (from rev 197033, xulrunner/trunk/shared-libs.patch)
  xulrunner/repos/community-staging-x86_64/unbreak-plugin-build.patch
    (from rev 197033, xulrunner/trunk/unbreak-plugin-build.patch)

------------------------------------------------------------------------------------------+
 community-staging-i686/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch   |   49 ++
 community-staging-i686/LFS_graphite2_harfbuzz.patch                                      |  212 ++++++++++
 community-staging-i686/PKGBUILD                                                          |   94 ++++
 community-staging-i686/freetype261.patch                                                 |   31 +
 community-staging-i686/gcc6.diff                                                         |   37 +
 community-staging-i686/mozconfig                                                         |   33 +
 community-staging-i686/mozilla-pkgconfig.patch                                           |   40 +
 community-staging-i686/shared-libs.patch                                                 |   12 
 community-staging-i686/unbreak-plugin-build.patch                                        |   76 +++
 community-staging-x86_64/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch |   49 ++
 community-staging-x86_64/LFS_graphite2_harfbuzz.patch                                    |  212 ++++++++++
 community-staging-x86_64/PKGBUILD                                                        |   94 ++++
 community-staging-x86_64/freetype261.patch                                               |   31 +
 community-staging-x86_64/gcc6.diff                                                       |   37 +
 community-staging-x86_64/mozconfig                                                       |   33 +
 community-staging-x86_64/mozilla-pkgconfig.patch                                         |   40 +
 community-staging-x86_64/shared-libs.patch                                               |   12 
 community-staging-x86_64/unbreak-plugin-build.patch                                      |   76 +++
 18 files changed, 1168 insertions(+)

Copied: xulrunner/repos/community-staging-i686/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch (from rev 197033, xulrunner/trunk/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch)
===================================================================
--- community-staging-i686/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch	                        (rev 0)
+++ community-staging-i686/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,49 @@
+From 4d0fe8f40364c170226f1ef3bc98975630463e87 Mon Sep 17 00:00:00 2001
+From: Mike Hommey <mh+mozilla at glandium.org>
+Date: Tue, 19 Jan 2016 14:31:04 +0900
+Subject: [PATCH] Bug 1233963 - Work around recent GNU gold behavior with
+ segments starting before the first section they contain
+
+---
+ build/unix/elfhack/elf.cpp | 7 +++++--
+ 1 file changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/build/unix/elfhack/elf.cpp b/build/unix/elfhack/elf.cpp
+index 666b535..743afde 100644
+--- a/build/unix/elfhack/elf.cpp
++++ b/build/unix/elfhack/elf.cpp
+@@ -253,26 +253,29 @@ Elf::Elf(std::ifstream &file)
+         }
+         if (phdr.p_type == PT_PHDR)
+             segment->addSection(phdr_section);
+         for (int j = 1; j < ehdr->e_shnum; j++)
+             if (phdr.contains(sections[j]))
+                 segment->addSection(sections[j]);
+         // Make sure that our view of segments corresponds to the original
+         // ELF file.
+-        assert(segment->getFileSize() == phdr.p_filesz);
++        // GNU gold likes to start some segments before the first section
++        // they contain. https://sourceware.org/bugzilla/show_bug.cgi?id=19392
++        unsigned int gold_adjustment = segment->getAddr() - phdr.p_vaddr;
++        assert(segment->getFileSize() == phdr.p_filesz - gold_adjustment);
+         // gold makes TLS segments end on an aligned virtual address, even
+         // when the underlying section ends before that, while bfd ld
+         // doesn't. It's fine if we don't keep that alignment.
+         unsigned int memsize = segment->getMemSize();
+         if (phdr.p_type == PT_TLS && memsize != phdr.p_memsz) {
+             unsigned int align = segment->getAlign();
+             memsize = (memsize + align - 1) & ~(align - 1);
+         }
+-        assert(memsize == phdr.p_memsz);
++        assert(memsize == phdr.p_memsz - gold_adjustment);
+         segments.push_back(segment);
+     }
+ 
+     new (&eh_entry) ElfLocation(ehdr->e_entry, this);
+ }
+ 
+ Elf::~Elf()
+ {
+-- 
+2.7.0
+

Copied: xulrunner/repos/community-staging-i686/LFS_graphite2_harfbuzz.patch (from rev 197033, xulrunner/trunk/LFS_graphite2_harfbuzz.patch)
===================================================================
--- community-staging-i686/LFS_graphite2_harfbuzz.patch	                        (rev 0)
+++ community-staging-i686/LFS_graphite2_harfbuzz.patch	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,212 @@
+Submitted By: Ken Moffat <ken at linuxfromscratch dot org>
+Date: 2016-06-13
+Initial Package Version: 47.0
+Upstream Status: Waiting for review
+Origin: OpenBSD (found at gentoo, rediffed because of one offset > 1500 lines)
+Description: Allow use of system versions of graphite2 and harfbuzz.  This
+should be regarded as experimental.  Add the options --enable-system-graphite
+and --enable-system-harfbuzz to use this (needs recent versions of both).
+
+diff -Naur ff47-vanilla/config/Makefile.in ff47-patched/config/Makefile.in
+--- ff47-vanilla/config/Makefile.in	2016-06-01 05:11:40.000000000 +0100
++++ ff47-patched/config/Makefile.in	2016-06-11 18:51:40.389876996 +0100
+@@ -49,6 +49,8 @@
+ 		-DMOZ_NATIVE_LIBEVENT=$(MOZ_NATIVE_LIBEVENT) \
+ 		-DMOZ_NATIVE_LIBVPX=$(MOZ_NATIVE_LIBVPX) \
+ 		-DMOZ_NATIVE_ICU=$(MOZ_NATIVE_ICU) \
++		-DMOZ_NATIVE_GRAPHITE2=$(MOZ_NATIVE_GRAPHITE2) \
++		-DMOZ_NATIVE_HARFBUZZ=$(MOZ_NATIVE_HARFBUZZ) \
+ 		$(srcdir)/system-headers | $(PERL) $(topsrcdir)/nsprpub/config/make-system-wrappers.pl system_wrappers
+ 	$(INSTALL) system_wrappers $(DIST)
+ 
+diff -Naur ff47-vanilla/config/system-headers ff47-patched/config/system-headers
+--- ff47-vanilla/config/system-headers	2016-06-01 05:11:40.000000000 +0100
++++ ff47-patched/config/system-headers	2016-06-11 18:51:40.389876996 +0100
+@@ -1345,3 +1345,11 @@
+ #endif
+ libutil.h
+ unwind.h
++#if MOZ_NATIVE_GRAPHITE2==1
++graphite2/Font.h
++graphite2/Segment.h
++#endif
++#if MOZ_NATIVE_HARFBUZZ==1
++harfbuzz/hb-ot.h
++harfbuzz/hb.h
++#endif
+diff -Naur ff47-vanilla/dom/base/moz.build ff47-patched/dom/base/moz.build
+--- ff47-vanilla/dom/base/moz.build	2016-06-01 05:11:44.000000000 +0100
++++ ff47-patched/dom/base/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -482,6 +482,9 @@
+ if CONFIG['MOZ_X11']:
+     CXXFLAGS += CONFIG['TK_CFLAGS']
+ 
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
++
+ GENERATED_FILES += [
+     'PropertyUseCounterMap.inc',
+     'UseCounterList.h',
+diff -Naur ff47-vanilla/gfx/moz.build ff47-patched/gfx/moz.build
+--- ff47-vanilla/gfx/moz.build	2016-05-12 18:13:06.000000000 +0100
++++ ff47-patched/gfx/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -7,6 +7,12 @@
+ if CONFIG['MOZ_TREE_CAIRO']:
+     DIRS += ['cairo']
+ 
++if not CONFIG['MOZ_NATIVE_GRAPHITE2']:
++    DIRS += ['graphite2/src' ]
++
++if not CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    DIRS += ['harfbuzz/src']
++
+ DIRS += [
+     '2d',
+     'ycbcr',
+@@ -15,8 +21,6 @@
+     'qcms',
+     'gl',
+     'layers',
+-    'graphite2/src',
+-    'harfbuzz/src',
+     'ots/src',
+     'thebes',
+     'ipc',
+diff -Naur ff47-vanilla/gfx/skia/generate_mozbuild.py ff47-patched/gfx/skia/generate_mozbuild.py
+--- ff47-vanilla/gfx/skia/generate_mozbuild.py	2016-06-01 05:11:44.000000000 +0100
++++ ff47-patched/gfx/skia/generate_mozbuild.py	2016-06-11 18:51:40.389876996 +0100
+@@ -134,6 +134,9 @@
+         '-Wno-unused-private-field',
+     ]
+ 
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
++
+ if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3', 'android', 'gonk', 'qt'):
+     CXXFLAGS += CONFIG['MOZ_CAIRO_CFLAGS']
+     CXXFLAGS += CONFIG['CAIRO_FT_CFLAGS']
+diff -Naur ff47-vanilla/gfx/skia/moz.build ff47-patched/gfx/skia/moz.build
+--- ff47-vanilla/gfx/skia/moz.build	2016-06-01 05:11:44.000000000 +0100
++++ ff47-patched/gfx/skia/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -752,6 +752,9 @@
+         '-Wno-unused-private-field',
+     ]
+ 
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
++
+ if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3', 'android', 'gonk', 'qt'):
+     CXXFLAGS += CONFIG['MOZ_CAIRO_CFLAGS']
+     CXXFLAGS += CONFIG['CAIRO_FT_CFLAGS']
+diff -Naur ff47-vanilla/gfx/thebes/moz.build ff47-patched/gfx/thebes/moz.build
+--- ff47-vanilla/gfx/thebes/moz.build	2016-06-01 05:11:44.000000000 +0100
++++ ff47-patched/gfx/thebes/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -307,7 +307,14 @@
+ 
+ LOCAL_INCLUDES += CONFIG['SKIA_INCLUDES']
+ 
+-DEFINES['GRAPHITE2_STATIC'] = True
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
++
++if CONFIG['MOZ_NATIVE_GRAPHITE2']:
++    CXXFLAGS += CONFIG['MOZ_GRAPHITE2_CFLAGS']
++else:
++    DEFINES['GRAPHITE2_STATIC'] = True
++
+ 
+ if CONFIG['CLANG_CXX']:
+     # Suppress warnings from Skia header files.
+diff -Naur ff47-vanilla/intl/unicharutil/util/moz.build ff47-patched/intl/unicharutil/util/moz.build
+--- ff47-vanilla/intl/unicharutil/util/moz.build	2016-06-01 05:11:45.000000000 +0100
++++ ff47-patched/intl/unicharutil/util/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -44,4 +44,7 @@
+     LOCAL_INCLUDES += CONFIG['MOZ_ICU_INCLUDES']
+     USE_LIBS += ['icu']
+ 
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
++
+ DIST_INSTALL = True
+diff -Naur ff47-vanilla/netwerk/dns/moz.build ff47-patched/netwerk/dns/moz.build
+--- ff47-vanilla/netwerk/dns/moz.build	2016-05-12 18:13:28.000000000 +0100
++++ ff47-patched/netwerk/dns/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -66,6 +66,9 @@
+     '/netwerk/base',
+ ]
+ 
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
++
+ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk' and CONFIG['ANDROID_VERSION'] > '19':
+     LOCAL_INCLUDES += ['%' + '%s/bionic/libc/dns/include' % CONFIG['ANDROID_SOURCE']]
+ 
+diff -Naur ff47-vanilla/configure.in ff47-patched/old-configure.in
+--- ff47-vanilla/configure.in	2016-06-01 05:11:44.000000000 +0100
++++ ff47-patched/configure.in	2016-06-11 18:51:40.389876996 +0100
+@@ -8013,6 +8013,49 @@
+ fi
+ 
+ dnl ========================================================
++dnl Check for harfbuzz
++dnl ========================================================
++
++MOZ_ARG_WITH_BOOL(system-harfbuzz,
++[  --with-system-harfbuzz  Use system harfbuzz (located with pkgconfig)],
++MOZ_NATIVE_HARFBUZZ=1,
++MOZ_NATIVE_HARFBUZZ=)
++
++if test -n "$MOZ_NATIVE_HARFBUZZ"; then
++    PKG_CHECK_MODULES(MOZ_HARFBUZZ, harfbuzz >= 1.1.3)
++fi
++
++AC_SUBST(MOZ_NATIVE_HARFBUZZ)
++
++dnl ========================================================
++dnl Check for graphite2
++dnl ========================================================
++
++MOZ_ARG_WITH_BOOL(system-graphite2,
++[  --with-system-graphite2 Use system graphite2 (located with pkgconfig)],
++MOZ_NATIVE_GRAPHITE2=1,
++MOZ_NATIVE_GRAPHITE2=)
++
++if test -n "$MOZ_NATIVE_GRAPHITE2"; then
++    PKG_CHECK_MODULES(MOZ_GRAPHITE2, graphite2)
++
++    dnl graphite2.pc has bogus version, check manually
++    AC_TRY_COMPILE([ #include <graphite2/Font.h>
++                     #define GR2_VERSION_REQUIRE(major,minor,bugfix)  \
++                             ( GR2_VERSION_MAJOR * 10000 + GR2_VERSION_MINOR \
++                               * 100 + GR2_VERSION_BUGFIX >= \
++                               (major) * 10000 + (minor) * 100 + (bugfix) )
++                   ], [
++                     #if !GR2_VERSION_REQUIRE(1,3,8)
++                     #error "Insufficient graphite2 version."
++                     #endif
++                   ], [],
++                   [AC_MSG_ERROR([--with-system-graphite2 requested but no working libgraphite2 found])])
++fi
++
++AC_SUBST(MOZ_NATIVE_GRAPHITE2)
++
++dnl ========================================================
+ dnl Check for pixman and cairo
+ dnl ========================================================
+ 
+diff -Naur ff47-vanilla/toolkit/library/moz.build ff47-patched/toolkit/library/moz.build
+--- ff47-vanilla/toolkit/library/moz.build	2016-06-01 05:11:43.000000000 +0100
++++ ff47-patched/toolkit/library/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -235,6 +235,12 @@
+ if CONFIG['MOZ_ALSA']:
+     OS_LIBS += CONFIG['MOZ_ALSA_LIBS']
+ 
++if CONFIG['MOZ_NATIVE_GRAPHITE2']:
++    OS_LIBS += CONFIG['MOZ_GRAPHITE2_LIBS']
++
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    OS_LIBS += CONFIG['MOZ_HARFBUZZ_LIBS']
++
+ if CONFIG['HAVE_CLOCK_MONOTONIC']:
+     OS_LIBS += CONFIG['REALTIME_LIBS']
+ 

Copied: xulrunner/repos/community-staging-i686/PKGBUILD (from rev 197033, xulrunner/trunk/PKGBUILD)
===================================================================
--- community-staging-i686/PKGBUILD	                        (rev 0)
+++ community-staging-i686/PKGBUILD	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,94 @@
+# $Id$
+# Maintainer: Connor Behan <connor.behan at gmail.com>
+# Contributor: Jan de Groot <jgc at archlinux.org>
+# Contributor: Alexander Baldeck <alexander at archlinux.org>
+
+pkgname=xulrunner
+pkgver=41.0.2
+pkgrel=9
+pkgdesc="Mozilla Runtime Environment"
+arch=('i686' 'x86_64')
+license=('MPL' 'GPL' 'LGPL')
+depends=('gtk2' 'mozilla-common' 'nss>3.18' 'libxt' 'startup-notification' 'mime-types' 'dbus-glib' 'libpulse' 'libevent' 'libvpx' 'icu' 'python2')
+makedepends=('zip' 'unzip' 'pkg-config' 'diffutils' 'yasm' 'mesa' 'gconf' 'autoconf2.13' 'gst-plugins-base-libs')
+url="http://wiki.mozilla.org/XUL:Xul_Runner"
+source=(https://ftp.mozilla.org/pub/mozilla.org/xulrunner/releases/$pkgver/source/xulrunner-$pkgver.source.tar.xz
+        mozconfig
+        freetype261.patch
+        0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch
+        LFS_graphite2_harfbuzz.patch
+        mozilla-pkgconfig.patch
+        shared-libs.patch
+        gcc6.diff)
+options=('!emptydirs' '!makeflags' 'staticlibs')
+replaces=('xulrunner-oss')
+sha256sums=('f7abb2e2989779305ab1f80d30caf9fc55d96c7e66d1394e2cc9639442e2b864'
+            'ba32eaa7e8c3b92414eb041722553c3d5282e5077b0d054ca10164d51ea970cd'
+            '3aea9a83bf304da5525f34a911712cf42f8ded1c8b6becf0a2cf8a4b4f7facd6'
+            '13a27a385fab88938ac7417f1e7ca7225ec6b88840bafe67e0f5642e5446554a'
+            'afcd7d3f6113b0f9ead0cb1b47b3fccedadce56a16b4406c439411864bd11863'
+            '1aa9ebe67542a2b8c28905d070829ada5b29438c6a7961f2b0cdd6b92d8b9f5c'
+            '59d9fc421bc10a5515b73e159f44a72365bf7b7e8b3fc8a8c46043ef40bd3a40'
+            '0992d5dce883de760ff0445448466f096d0baa75fe5fd1e60bfd3cc13cb4d098')
+
+prepare() {
+  cd "$srcdir/mozilla-release"
+  cp "$srcdir/mozconfig" .mozconfig
+
+  # GCC6
+  patch -Np1 -i ../gcc6.diff
+
+  # https://bugzilla.mozilla.org/show_bug.cgi?id=1194520
+  patch -Np1 -i ../freetype261.patch
+
+  # https://bugzilla.mozilla.org/show_bug.cgi?id=1233963
+  patch -Np1 -i ../0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch
+
+  # https://bugzilla.mozilla.org/show_bug.cgi?id=847568
+  patch -Np1 -i ../LFS_graphite2_harfbuzz.patch
+  rm configure
+  autoconf-2.13
+
+  # fix libdir/sdkdir - fedora
+  patch -Np1 -i ../mozilla-pkgconfig.patch
+  patch -Np1 -i ../shared-libs.patch
+
+  # WebRTC build tries to execute "python" and expects Python 2
+  # Workaround taken from chromium PKGBUILD
+  mkdir "$srcdir/python2-path"
+  ln -s /usr/bin/python2 "$srcdir/python2-path/python"
+
+  # configure script misdetects the preprocessor without an optimization level
+  # https://bugs.archlinux.org/task/34644
+  sed -i '/ac_cpp=/s/$CPPFLAGS/& -O2/' configure
+}
+
+build() {
+  cd "$srcdir/mozilla-release"
+
+  export PATH="$srcdir/python2-path:$PATH"
+  export LDFLAGS="$LDFALGS -Wl,-rpath,/usr/lib/xulrunner-$pkgver"
+  export PYTHON="/usr/bin/python2"
+
+  make -j1 -f client.mk build
+}
+
+package() {
+  cd "$srcdir/mozilla-release"
+  make -j1 -f client.mk DESTDIR="$pkgdir" install
+
+  # Use system-provided dictionaries
+  rm -rf "$pkgdir"/usr/lib/xulrunner-$pkgver/{dictionaries,hyphenation}
+  ln -sf /usr/share/hunspell "$pkgdir/usr/lib/xulrunner-$pkgver/dictionaries"
+  ln -sf /usr/share/hyphen "$pkgdir/usr/lib/xulrunner-$pkgver/hyphenation"
+
+  # add xulrunner library path to ld.so.conf
+  install -d $pkgdir/etc/ld.so.conf.d
+  echo "/usr/lib/xulrunner-$pkgver" > $pkgdir/etc/ld.so.conf.d/xulrunner.conf
+
+  chmod +x "${pkgdir}/usr/lib/xulrunner-devel-$pkgver/sdk/bin/xpt.py"
+  chmod +x "${pkgdir}/usr/lib/xulrunner-devel-$pkgver/sdk/bin/xpcshell"
+  ln -s /usr/lib/xulrunner-devel-$pkgver/sdk/bin/xpcshell "${pkgdir}/usr/lib/xulrunner-$pkgver/xpcshell"
+  sed -i 's|!/usr/bin/env python$|!/usr/bin/env python2|' \
+    "$pkgdir"/usr/lib/xulrunner-devel-$pkgver/sdk/bin/{xpt,header,typelib,xpidl}.py
+}

Copied: xulrunner/repos/community-staging-i686/freetype261.patch (from rev 197033, xulrunner/trunk/freetype261.patch)
===================================================================
--- community-staging-i686/freetype261.patch	                        (rev 0)
+++ community-staging-i686/freetype261.patch	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,31 @@
+
+# HG changeset patch
+# User Mike Hommey <mh+mozilla at glandium.org>
+# Date 1439509838 -32400
+# Node ID af40750720b59cb7af58c32f4f3325d6e03bbbc4
+# Parent  e578cc44a96a2a953e75e295b0d8954f467d5cff
+Bug 1194520 - Add a system header wrapper for <freetype/ftfntfmt.h>. r=mshal
+
+
+diff --git a/config/system-headers b/config/system-headers
+--- a/config/system-headers
++++ b/config/system-headers
+@@ -450,16 +450,17 @@ foundation/base64.h
+ foundation/hexdump.h
+ #endif
+ fp.h
+ fpieee.h
+ frame/log.h
+ frame/req.h
+ freetype/freetype.h
+ freetype/ftcache.h
++freetype/ftfntfmt.h
+ freetype/ftglyph.h
+ freetype/ftsynth.h
+ freetype/ftoutln.h
+ freetype/ttnameid.h
+ freetype/tttables.h
+ freetype/t1tables.h
+ freetype/ftlcdfil.h
+ freetype/ftsizes.h
+

Copied: xulrunner/repos/community-staging-i686/gcc6.diff (from rev 197033, xulrunner/trunk/gcc6.diff)
===================================================================
--- community-staging-i686/gcc6.diff	                        (rev 0)
+++ community-staging-i686/gcc6.diff	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,37 @@
+--- mozilla-release/config/gcc-stl-wrapper.template.h	2015-10-14 23:40:56.000000000 +0200
++++ mozilla-release/config/gcc-stl-wrapper.template.h.new	2016-06-14 19:40:50.542435101 +0200
+@@ -22,6 +22,11 @@
+ #define NOMINMAX 1
+ #endif
+ 
++// Don't include mozalloc for cstdlib. See bug 1245076.
++#ifndef moz_dont_include_mozalloc_for_cstdlib
++#  define moz_dont_include_mozalloc_for_cstdlib
++#endif
++#ifndef moz_dont_include_mozalloc_for_${HEADER}
+ // mozalloc.h wants <new>; break the cycle by always explicitly
+ // including <new> here.  NB: this is a tad sneaky.  Sez the gcc docs:
+ //
+@@ -30,15 +35,17 @@
+ //    same name as the current file. It simply looks for the file
+ //    named, starting with the directory in the search path after the
+ //    one where the current file was found.
+-#include_next <new>
++#  include_next <new>
+ 
+ // See if we're in code that can use mozalloc.  NB: this duplicates
+ // code in nscore.h because nscore.h pulls in prtypes.h, and chromium
+ // can't build with that being included before base/basictypes.h.
+-#if !defined(XPCOM_GLUE) && !defined(NS_NO_XPCOM) && !defined(MOZ_NO_MOZALLOC)
+-#  include "mozilla/mozalloc.h"
+-#else
+-#  error "STL code can only be used with infallible ::operator new()"
++#  if !defined(XPCOM_GLUE) && !defined(NS_NO_XPCOM) && !defined(MOZ_NO_MOZALLOC)
++#    include "mozilla/mozalloc.h"
++#  else
++#    error "STL code can only be used with infallible ::operator new()"
++#  endif
++
+ #endif
+ 
+ #if defined(DEBUG) && !defined(_GLIBCXX_DEBUG)

Copied: xulrunner/repos/community-staging-i686/mozconfig (from rev 197033, xulrunner/trunk/mozconfig)
===================================================================
--- community-staging-i686/mozconfig	                        (rev 0)
+++ community-staging-i686/mozconfig	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,33 @@
+. $topsrcdir/xulrunner/config/mozconfig
+
+ac_add_options --prefix=/usr
+ac_add_options --libdir=/usr/lib
+
+# System libraries
+ac_add_options --with-system-nspr
+ac_add_options --with-system-nss
+ac_add_options --with-system-jpeg
+ac_add_options --with-system-zlib
+ac_add_options --with-system-bz2
+ac_add_options --with-system-png
+ac_add_options --with-system-libevent
+ac_add_options --with-system-libvpx
+ac_add_options --with-system-icu
+ac_add_options --with-system-graphite2
+#ac_add_options --enable-system-hunspell   # cannot use system hunspell 1.5.0
+ac_add_options --enable-system-sqlite
+ac_add_options --enable-system-ffi
+ac_add_options --enable-system-cairo
+ac_add_options --enable-system-pixman
+ac_add_options --with-pthreads
+
+# Features
+ac_add_options --enable-startup-notification
+ac_add_options --enable-gstreamer=1.0
+ac_add_options --disable-crashreporter
+ac_add_options --disable-updater
+ac_add_options --disable-tests
+ac_add_options --disable-installer
+
+# https://bugzilla.mozilla.org/show_bug.cgi?id=955876
+#ac_add_options --enable-release

Copied: xulrunner/repos/community-staging-i686/mozilla-pkgconfig.patch (from rev 197033, xulrunner/trunk/mozilla-pkgconfig.patch)
===================================================================
--- community-staging-i686/mozilla-pkgconfig.patch	                        (rev 0)
+++ community-staging-i686/mozilla-pkgconfig.patch	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,40 @@
+diff -Nur mozilla-release.orig/xulrunner/installer/libxul-embedding.pc.in mozilla-release/xulrunner/installer/libxul-embedding.pc.in
+--- mozilla-release.orig/xulrunner/installer/libxul-embedding.pc.in	2011-12-19 22:11:38.100005674 +0000
++++ mozilla-release/xulrunner/installer/libxul-embedding.pc.in	2011-12-19 22:14:35.095147521 +0000
+@@ -6,5 +6,6 @@
+ Name: libxul-embedding
+ Description: Static library for version-independent embedding of the Mozilla runtime
+ Version: %MOZILLA_VERSION%
++Requires: %NSPR_NAME% >= %NSPR_VERSION%
+ Libs: -L${sdkdir}/lib -lxpcomglue -ldl
+ Cflags: -DXPCOM_GLUE -I${includedir} %WCHAR_CFLAGS%
+diff -Nur mozilla-release.orig/xulrunner/installer/libxul.pc.in mozilla-release/xulrunner/installer/libxul.pc.in
+--- mozilla-release.orig/xulrunner/installer/libxul.pc.in	2011-12-19 22:11:38.126672110 +0000
++++ mozilla-release/xulrunner/installer/libxul.pc.in	2011-12-19 22:14:04.375412141 +0000
+@@ -1,5 +1,6 @@
+ prefix=%prefix%
+ sdkdir=%sdkdir%
++libdir=%libdir%
+ includedir=%includedir%
+ idldir=%idldir%
+ 
+diff -Nur mozilla-release.orig/xulrunner/installer/Makefile.in mozilla-release/xulrunner/installer/Makefile.in
+--- mozilla-release.orig/xulrunner/installer/Makefile.in	2011-12-19 22:11:38.126672110 +0000
++++ mozilla-release/xulrunner/installer/Makefile.in	2011-12-19 22:18:28.743135321 +0000
+@@ -108,6 +108,7 @@
+ 	-e "s|%includedir%|$(includedir)|" \
+ 	-e "s|%idldir%|$(idldir)|" \
+ 	-e "s|%sdkdir%|$(sdkdir)|" \
++	-e "s|%libdir%|$(installdir)|" \
+ 	-e "s|%MOZ_APP_NAME%|$(MOZ_APP_NAME)|" \
+ 	-e "s|%MOZILLA_VERSION%|$(MOZ_APP_VERSION)|" \
+ 	-e "s|%WCHAR_CFLAGS%|$(WCHAR_CFLAGS)|" \
+diff -Nur mozilla-release.orig/xulrunner/installer/mozilla-js.pc.in mozilla-release/xulrunner/installer/mozilla-js.pc.in
+--- mozilla-release.orig/xulrunner/installer/mozilla-js.pc.in	2011-12-19 22:11:38.126672110 +0000
++++ mozilla-release/xulrunner/installer/mozilla-js.pc.in	2011-12-19 22:18:55.569571004 +0000
+@@ -7,4 +7,4 @@
+ Version: %MOZILLA_VERSION%
+ Requires: %NSPR_NAME% >= %NSPR_VERSION%
+ Libs: -L${sdkdir}/lib %MOZ_JS_LINK%
+-Cflags: -I${includedir} -DXP_UNIX
++Cflags: -I${includedir} -I${includedir}/js -DXP_UNIX

Copied: xulrunner/repos/community-staging-i686/shared-libs.patch (from rev 197033, xulrunner/trunk/shared-libs.patch)
===================================================================
--- community-staging-i686/shared-libs.patch	                        (rev 0)
+++ community-staging-i686/shared-libs.patch	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,12 @@
+diff -Nur mozilla-release.orig/browser/installer/Makefile.in mozilla-release/browser/installer/Makefile.in
+--- mozilla-release.orig/browser/installer/Makefile.in	2012-07-17 16:19:29.480356991 +0000
++++ mozilla-release/browser/installer/Makefile.in	2012-07-17 17:32:41.250937293 +0000
+@@ -17,7 +17,7 @@
+ 
+ # Some files have been already bundled with xulrunner
+ ifndef MOZ_MULET
+-MOZ_PKG_FATAL_WARNINGS = 1
++MOZ_PKG_FATAL_WARNINGS = 0
+ endif
+ 
+ DEFINES += -DAB_CD=$(AB_CD) -DMOZ_APP_NAME=$(MOZ_APP_NAME) -DPREF_DIR=$(PREF_DIR)

Copied: xulrunner/repos/community-staging-i686/unbreak-plugin-build.patch (from rev 197033, xulrunner/trunk/unbreak-plugin-build.patch)
===================================================================
--- community-staging-i686/unbreak-plugin-build.patch	                        (rev 0)
+++ community-staging-i686/unbreak-plugin-build.patch	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,76 @@
+
+# HG changeset patch
+# User Ehsan Akhgari <ehsan at mozilla.com>
+# Date 1392421799 18000
+# Node ID 0691948a0abedc7db35c4cb67ec11ad06f782ab0
+# Parent  6f78482c5792b03adca38c924cc4a41f6e16b8ff
+Bug 784739 follow-up: Use NULL in npruntime.h
+
+diff --git a/dom/plugins/base/npruntime.h b/dom/plugins/base/npruntime.h
+--- a/dom/plugins/base/npruntime.h
++++ b/dom/plugins/base/npruntime.h
+@@ -132,23 +132,23 @@ void NPN_ReleaseVariantValue(NPVariant *
+ #define NPVARIANT_TO_INT32(_v)   ((_v).value.intValue)
+ #define NPVARIANT_TO_DOUBLE(_v)  ((_v).value.doubleValue)
+ #define NPVARIANT_TO_STRING(_v)  ((_v).value.stringValue)
+ #define NPVARIANT_TO_OBJECT(_v)  ((_v).value.objectValue)
+ 
+ #define VOID_TO_NPVARIANT(_v)                                                 \
+ NP_BEGIN_MACRO                                                                \
+     (_v).type = NPVariantType_Void;                                           \
+-    (_v).value.objectValue = nullptr;                                         \
++    (_v).value.objectValue = NULL;                                            \
+ NP_END_MACRO
+ 
+ #define NULL_TO_NPVARIANT(_v)                                                 \
+ NP_BEGIN_MACRO                                                                \
+     (_v).type = NPVariantType_Null;                                           \
+-    (_v).value.objectValue = nullptr;                                         \
++    (_v).value.objectValue = NULL;                                            \
+ NP_END_MACRO
+ 
+ #define BOOLEAN_TO_NPVARIANT(_val, _v)                                        \
+ NP_BEGIN_MACRO                                                                \
+     (_v).type = NPVariantType_Bool;                                           \
+     (_v).value.boolValue = !!(_val);                                          \
+ NP_END_MACRO
+ 
+@@ -211,17 +211,17 @@ typedef void *NPIdentifier;
+ 
+ /*
+     NPObjects have methods and properties.  Methods and properties are
+     identified with NPIdentifiers.  These identifiers may be reflected
+     in script.  NPIdentifiers can be either strings or integers, IOW,
+     methods and properties can be identified by either strings or
+     integers (i.e. foo["bar"] vs foo[1]). NPIdentifiers can be
+     compared using ==.  In case of any errors, the requested
+-    NPIdentifier(s) will be nullptr. NPIdentifier lifetime is controlled
++    NPIdentifier(s) will be NULL. NPIdentifier lifetime is controlled
+     by the browser. Plugins do not need to worry about memory management
+     with regards to NPIdentifiers.
+ */
+ NPIdentifier NPN_GetStringIdentifier(const NPUTF8 *name);
+ void NPN_GetStringIdentifiers(const NPUTF8 **names, int32_t nameCount,
+                               NPIdentifier *identifiers);
+ NPIdentifier NPN_GetIntIdentifier(int32_t intid);
+ bool NPN_IdentifierIsString(NPIdentifier identifier);
+@@ -278,17 +278,17 @@ typedef bool (*NPConstructFunctionPtr)(N
+     NPInvokeFunctionPtr function may return 0 to indicate a void
+     result.
+ 
+     NPInvalidateFunctionPtr is called by the scripting environment
+     when the native code is shutdown.  Any attempt to message a
+     NPObject instance after the invalidate callback has been
+     called will result in undefined behavior, even if the native code
+     is still retaining those NPObject instances.  (The runtime
+-    will typically return immediately, with 0 or nullptr, from an
++    will typically return immediately, with 0 or NULL, from an
+     attempt to dispatch to a NPObject, but this behavior should not
+     be depended upon.)
+ 
+     The NPEnumerationFunctionPtr function may pass an array of
+     NPIdentifiers back to the caller. The callee allocs the memory of
+     the array using NPN_MemAlloc(), and it's the caller's responsibility
+     to release it using NPN_MemFree().
+ */
+

Copied: xulrunner/repos/community-staging-x86_64/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch (from rev 197033, xulrunner/trunk/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch)
===================================================================
--- community-staging-x86_64/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch	                        (rev 0)
+++ community-staging-x86_64/0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,49 @@
+From 4d0fe8f40364c170226f1ef3bc98975630463e87 Mon Sep 17 00:00:00 2001
+From: Mike Hommey <mh+mozilla at glandium.org>
+Date: Tue, 19 Jan 2016 14:31:04 +0900
+Subject: [PATCH] Bug 1233963 - Work around recent GNU gold behavior with
+ segments starting before the first section they contain
+
+---
+ build/unix/elfhack/elf.cpp | 7 +++++--
+ 1 file changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/build/unix/elfhack/elf.cpp b/build/unix/elfhack/elf.cpp
+index 666b535..743afde 100644
+--- a/build/unix/elfhack/elf.cpp
++++ b/build/unix/elfhack/elf.cpp
+@@ -253,26 +253,29 @@ Elf::Elf(std::ifstream &file)
+         }
+         if (phdr.p_type == PT_PHDR)
+             segment->addSection(phdr_section);
+         for (int j = 1; j < ehdr->e_shnum; j++)
+             if (phdr.contains(sections[j]))
+                 segment->addSection(sections[j]);
+         // Make sure that our view of segments corresponds to the original
+         // ELF file.
+-        assert(segment->getFileSize() == phdr.p_filesz);
++        // GNU gold likes to start some segments before the first section
++        // they contain. https://sourceware.org/bugzilla/show_bug.cgi?id=19392
++        unsigned int gold_adjustment = segment->getAddr() - phdr.p_vaddr;
++        assert(segment->getFileSize() == phdr.p_filesz - gold_adjustment);
+         // gold makes TLS segments end on an aligned virtual address, even
+         // when the underlying section ends before that, while bfd ld
+         // doesn't. It's fine if we don't keep that alignment.
+         unsigned int memsize = segment->getMemSize();
+         if (phdr.p_type == PT_TLS && memsize != phdr.p_memsz) {
+             unsigned int align = segment->getAlign();
+             memsize = (memsize + align - 1) & ~(align - 1);
+         }
+-        assert(memsize == phdr.p_memsz);
++        assert(memsize == phdr.p_memsz - gold_adjustment);
+         segments.push_back(segment);
+     }
+ 
+     new (&eh_entry) ElfLocation(ehdr->e_entry, this);
+ }
+ 
+ Elf::~Elf()
+ {
+-- 
+2.7.0
+

Copied: xulrunner/repos/community-staging-x86_64/LFS_graphite2_harfbuzz.patch (from rev 197033, xulrunner/trunk/LFS_graphite2_harfbuzz.patch)
===================================================================
--- community-staging-x86_64/LFS_graphite2_harfbuzz.patch	                        (rev 0)
+++ community-staging-x86_64/LFS_graphite2_harfbuzz.patch	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,212 @@
+Submitted By: Ken Moffat <ken at linuxfromscratch dot org>
+Date: 2016-06-13
+Initial Package Version: 47.0
+Upstream Status: Waiting for review
+Origin: OpenBSD (found at gentoo, rediffed because of one offset > 1500 lines)
+Description: Allow use of system versions of graphite2 and harfbuzz.  This
+should be regarded as experimental.  Add the options --enable-system-graphite
+and --enable-system-harfbuzz to use this (needs recent versions of both).
+
+diff -Naur ff47-vanilla/config/Makefile.in ff47-patched/config/Makefile.in
+--- ff47-vanilla/config/Makefile.in	2016-06-01 05:11:40.000000000 +0100
++++ ff47-patched/config/Makefile.in	2016-06-11 18:51:40.389876996 +0100
+@@ -49,6 +49,8 @@
+ 		-DMOZ_NATIVE_LIBEVENT=$(MOZ_NATIVE_LIBEVENT) \
+ 		-DMOZ_NATIVE_LIBVPX=$(MOZ_NATIVE_LIBVPX) \
+ 		-DMOZ_NATIVE_ICU=$(MOZ_NATIVE_ICU) \
++		-DMOZ_NATIVE_GRAPHITE2=$(MOZ_NATIVE_GRAPHITE2) \
++		-DMOZ_NATIVE_HARFBUZZ=$(MOZ_NATIVE_HARFBUZZ) \
+ 		$(srcdir)/system-headers | $(PERL) $(topsrcdir)/nsprpub/config/make-system-wrappers.pl system_wrappers
+ 	$(INSTALL) system_wrappers $(DIST)
+ 
+diff -Naur ff47-vanilla/config/system-headers ff47-patched/config/system-headers
+--- ff47-vanilla/config/system-headers	2016-06-01 05:11:40.000000000 +0100
++++ ff47-patched/config/system-headers	2016-06-11 18:51:40.389876996 +0100
+@@ -1345,3 +1345,11 @@
+ #endif
+ libutil.h
+ unwind.h
++#if MOZ_NATIVE_GRAPHITE2==1
++graphite2/Font.h
++graphite2/Segment.h
++#endif
++#if MOZ_NATIVE_HARFBUZZ==1
++harfbuzz/hb-ot.h
++harfbuzz/hb.h
++#endif
+diff -Naur ff47-vanilla/dom/base/moz.build ff47-patched/dom/base/moz.build
+--- ff47-vanilla/dom/base/moz.build	2016-06-01 05:11:44.000000000 +0100
++++ ff47-patched/dom/base/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -482,6 +482,9 @@
+ if CONFIG['MOZ_X11']:
+     CXXFLAGS += CONFIG['TK_CFLAGS']
+ 
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
++
+ GENERATED_FILES += [
+     'PropertyUseCounterMap.inc',
+     'UseCounterList.h',
+diff -Naur ff47-vanilla/gfx/moz.build ff47-patched/gfx/moz.build
+--- ff47-vanilla/gfx/moz.build	2016-05-12 18:13:06.000000000 +0100
++++ ff47-patched/gfx/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -7,6 +7,12 @@
+ if CONFIG['MOZ_TREE_CAIRO']:
+     DIRS += ['cairo']
+ 
++if not CONFIG['MOZ_NATIVE_GRAPHITE2']:
++    DIRS += ['graphite2/src' ]
++
++if not CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    DIRS += ['harfbuzz/src']
++
+ DIRS += [
+     '2d',
+     'ycbcr',
+@@ -15,8 +21,6 @@
+     'qcms',
+     'gl',
+     'layers',
+-    'graphite2/src',
+-    'harfbuzz/src',
+     'ots/src',
+     'thebes',
+     'ipc',
+diff -Naur ff47-vanilla/gfx/skia/generate_mozbuild.py ff47-patched/gfx/skia/generate_mozbuild.py
+--- ff47-vanilla/gfx/skia/generate_mozbuild.py	2016-06-01 05:11:44.000000000 +0100
++++ ff47-patched/gfx/skia/generate_mozbuild.py	2016-06-11 18:51:40.389876996 +0100
+@@ -134,6 +134,9 @@
+         '-Wno-unused-private-field',
+     ]
+ 
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
++
+ if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3', 'android', 'gonk', 'qt'):
+     CXXFLAGS += CONFIG['MOZ_CAIRO_CFLAGS']
+     CXXFLAGS += CONFIG['CAIRO_FT_CFLAGS']
+diff -Naur ff47-vanilla/gfx/skia/moz.build ff47-patched/gfx/skia/moz.build
+--- ff47-vanilla/gfx/skia/moz.build	2016-06-01 05:11:44.000000000 +0100
++++ ff47-patched/gfx/skia/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -752,6 +752,9 @@
+         '-Wno-unused-private-field',
+     ]
+ 
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
++
+ if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3', 'android', 'gonk', 'qt'):
+     CXXFLAGS += CONFIG['MOZ_CAIRO_CFLAGS']
+     CXXFLAGS += CONFIG['CAIRO_FT_CFLAGS']
+diff -Naur ff47-vanilla/gfx/thebes/moz.build ff47-patched/gfx/thebes/moz.build
+--- ff47-vanilla/gfx/thebes/moz.build	2016-06-01 05:11:44.000000000 +0100
++++ ff47-patched/gfx/thebes/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -307,7 +307,14 @@
+ 
+ LOCAL_INCLUDES += CONFIG['SKIA_INCLUDES']
+ 
+-DEFINES['GRAPHITE2_STATIC'] = True
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
++
++if CONFIG['MOZ_NATIVE_GRAPHITE2']:
++    CXXFLAGS += CONFIG['MOZ_GRAPHITE2_CFLAGS']
++else:
++    DEFINES['GRAPHITE2_STATIC'] = True
++
+ 
+ if CONFIG['CLANG_CXX']:
+     # Suppress warnings from Skia header files.
+diff -Naur ff47-vanilla/intl/unicharutil/util/moz.build ff47-patched/intl/unicharutil/util/moz.build
+--- ff47-vanilla/intl/unicharutil/util/moz.build	2016-06-01 05:11:45.000000000 +0100
++++ ff47-patched/intl/unicharutil/util/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -44,4 +44,7 @@
+     LOCAL_INCLUDES += CONFIG['MOZ_ICU_INCLUDES']
+     USE_LIBS += ['icu']
+ 
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
++
+ DIST_INSTALL = True
+diff -Naur ff47-vanilla/netwerk/dns/moz.build ff47-patched/netwerk/dns/moz.build
+--- ff47-vanilla/netwerk/dns/moz.build	2016-05-12 18:13:28.000000000 +0100
++++ ff47-patched/netwerk/dns/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -66,6 +66,9 @@
+     '/netwerk/base',
+ ]
+ 
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
++
+ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk' and CONFIG['ANDROID_VERSION'] > '19':
+     LOCAL_INCLUDES += ['%' + '%s/bionic/libc/dns/include' % CONFIG['ANDROID_SOURCE']]
+ 
+diff -Naur ff47-vanilla/configure.in ff47-patched/old-configure.in
+--- ff47-vanilla/configure.in	2016-06-01 05:11:44.000000000 +0100
++++ ff47-patched/configure.in	2016-06-11 18:51:40.389876996 +0100
+@@ -8013,6 +8013,49 @@
+ fi
+ 
+ dnl ========================================================
++dnl Check for harfbuzz
++dnl ========================================================
++
++MOZ_ARG_WITH_BOOL(system-harfbuzz,
++[  --with-system-harfbuzz  Use system harfbuzz (located with pkgconfig)],
++MOZ_NATIVE_HARFBUZZ=1,
++MOZ_NATIVE_HARFBUZZ=)
++
++if test -n "$MOZ_NATIVE_HARFBUZZ"; then
++    PKG_CHECK_MODULES(MOZ_HARFBUZZ, harfbuzz >= 1.1.3)
++fi
++
++AC_SUBST(MOZ_NATIVE_HARFBUZZ)
++
++dnl ========================================================
++dnl Check for graphite2
++dnl ========================================================
++
++MOZ_ARG_WITH_BOOL(system-graphite2,
++[  --with-system-graphite2 Use system graphite2 (located with pkgconfig)],
++MOZ_NATIVE_GRAPHITE2=1,
++MOZ_NATIVE_GRAPHITE2=)
++
++if test -n "$MOZ_NATIVE_GRAPHITE2"; then
++    PKG_CHECK_MODULES(MOZ_GRAPHITE2, graphite2)
++
++    dnl graphite2.pc has bogus version, check manually
++    AC_TRY_COMPILE([ #include <graphite2/Font.h>
++                     #define GR2_VERSION_REQUIRE(major,minor,bugfix)  \
++                             ( GR2_VERSION_MAJOR * 10000 + GR2_VERSION_MINOR \
++                               * 100 + GR2_VERSION_BUGFIX >= \
++                               (major) * 10000 + (minor) * 100 + (bugfix) )
++                   ], [
++                     #if !GR2_VERSION_REQUIRE(1,3,8)
++                     #error "Insufficient graphite2 version."
++                     #endif
++                   ], [],
++                   [AC_MSG_ERROR([--with-system-graphite2 requested but no working libgraphite2 found])])
++fi
++
++AC_SUBST(MOZ_NATIVE_GRAPHITE2)
++
++dnl ========================================================
+ dnl Check for pixman and cairo
+ dnl ========================================================
+ 
+diff -Naur ff47-vanilla/toolkit/library/moz.build ff47-patched/toolkit/library/moz.build
+--- ff47-vanilla/toolkit/library/moz.build	2016-06-01 05:11:43.000000000 +0100
++++ ff47-patched/toolkit/library/moz.build	2016-06-11 18:51:40.389876996 +0100
+@@ -235,6 +235,12 @@
+ if CONFIG['MOZ_ALSA']:
+     OS_LIBS += CONFIG['MOZ_ALSA_LIBS']
+ 
++if CONFIG['MOZ_NATIVE_GRAPHITE2']:
++    OS_LIBS += CONFIG['MOZ_GRAPHITE2_LIBS']
++
++if CONFIG['MOZ_NATIVE_HARFBUZZ']:
++    OS_LIBS += CONFIG['MOZ_HARFBUZZ_LIBS']
++
+ if CONFIG['HAVE_CLOCK_MONOTONIC']:
+     OS_LIBS += CONFIG['REALTIME_LIBS']
+ 

Copied: xulrunner/repos/community-staging-x86_64/PKGBUILD (from rev 197033, xulrunner/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,94 @@
+# $Id$
+# Maintainer: Connor Behan <connor.behan at gmail.com>
+# Contributor: Jan de Groot <jgc at archlinux.org>
+# Contributor: Alexander Baldeck <alexander at archlinux.org>
+
+pkgname=xulrunner
+pkgver=41.0.2
+pkgrel=9
+pkgdesc="Mozilla Runtime Environment"
+arch=('i686' 'x86_64')
+license=('MPL' 'GPL' 'LGPL')
+depends=('gtk2' 'mozilla-common' 'nss>3.18' 'libxt' 'startup-notification' 'mime-types' 'dbus-glib' 'libpulse' 'libevent' 'libvpx' 'icu' 'python2')
+makedepends=('zip' 'unzip' 'pkg-config' 'diffutils' 'yasm' 'mesa' 'gconf' 'autoconf2.13' 'gst-plugins-base-libs')
+url="http://wiki.mozilla.org/XUL:Xul_Runner"
+source=(https://ftp.mozilla.org/pub/mozilla.org/xulrunner/releases/$pkgver/source/xulrunner-$pkgver.source.tar.xz
+        mozconfig
+        freetype261.patch
+        0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch
+        LFS_graphite2_harfbuzz.patch
+        mozilla-pkgconfig.patch
+        shared-libs.patch
+        gcc6.diff)
+options=('!emptydirs' '!makeflags' 'staticlibs')
+replaces=('xulrunner-oss')
+sha256sums=('f7abb2e2989779305ab1f80d30caf9fc55d96c7e66d1394e2cc9639442e2b864'
+            'ba32eaa7e8c3b92414eb041722553c3d5282e5077b0d054ca10164d51ea970cd'
+            '3aea9a83bf304da5525f34a911712cf42f8ded1c8b6becf0a2cf8a4b4f7facd6'
+            '13a27a385fab88938ac7417f1e7ca7225ec6b88840bafe67e0f5642e5446554a'
+            'afcd7d3f6113b0f9ead0cb1b47b3fccedadce56a16b4406c439411864bd11863'
+            '1aa9ebe67542a2b8c28905d070829ada5b29438c6a7961f2b0cdd6b92d8b9f5c'
+            '59d9fc421bc10a5515b73e159f44a72365bf7b7e8b3fc8a8c46043ef40bd3a40'
+            '0992d5dce883de760ff0445448466f096d0baa75fe5fd1e60bfd3cc13cb4d098')
+
+prepare() {
+  cd "$srcdir/mozilla-release"
+  cp "$srcdir/mozconfig" .mozconfig
+
+  # GCC6
+  patch -Np1 -i ../gcc6.diff
+
+  # https://bugzilla.mozilla.org/show_bug.cgi?id=1194520
+  patch -Np1 -i ../freetype261.patch
+
+  # https://bugzilla.mozilla.org/show_bug.cgi?id=1233963
+  patch -Np1 -i ../0001-Bug-1233963-Work-around-recent-GNU-gold-behavior-wit.patch
+
+  # https://bugzilla.mozilla.org/show_bug.cgi?id=847568
+  patch -Np1 -i ../LFS_graphite2_harfbuzz.patch
+  rm configure
+  autoconf-2.13
+
+  # fix libdir/sdkdir - fedora
+  patch -Np1 -i ../mozilla-pkgconfig.patch
+  patch -Np1 -i ../shared-libs.patch
+
+  # WebRTC build tries to execute "python" and expects Python 2
+  # Workaround taken from chromium PKGBUILD
+  mkdir "$srcdir/python2-path"
+  ln -s /usr/bin/python2 "$srcdir/python2-path/python"
+
+  # configure script misdetects the preprocessor without an optimization level
+  # https://bugs.archlinux.org/task/34644
+  sed -i '/ac_cpp=/s/$CPPFLAGS/& -O2/' configure
+}
+
+build() {
+  cd "$srcdir/mozilla-release"
+
+  export PATH="$srcdir/python2-path:$PATH"
+  export LDFLAGS="$LDFALGS -Wl,-rpath,/usr/lib/xulrunner-$pkgver"
+  export PYTHON="/usr/bin/python2"
+
+  make -j1 -f client.mk build
+}
+
+package() {
+  cd "$srcdir/mozilla-release"
+  make -j1 -f client.mk DESTDIR="$pkgdir" install
+
+  # Use system-provided dictionaries
+  rm -rf "$pkgdir"/usr/lib/xulrunner-$pkgver/{dictionaries,hyphenation}
+  ln -sf /usr/share/hunspell "$pkgdir/usr/lib/xulrunner-$pkgver/dictionaries"
+  ln -sf /usr/share/hyphen "$pkgdir/usr/lib/xulrunner-$pkgver/hyphenation"
+
+  # add xulrunner library path to ld.so.conf
+  install -d $pkgdir/etc/ld.so.conf.d
+  echo "/usr/lib/xulrunner-$pkgver" > $pkgdir/etc/ld.so.conf.d/xulrunner.conf
+
+  chmod +x "${pkgdir}/usr/lib/xulrunner-devel-$pkgver/sdk/bin/xpt.py"
+  chmod +x "${pkgdir}/usr/lib/xulrunner-devel-$pkgver/sdk/bin/xpcshell"
+  ln -s /usr/lib/xulrunner-devel-$pkgver/sdk/bin/xpcshell "${pkgdir}/usr/lib/xulrunner-$pkgver/xpcshell"
+  sed -i 's|!/usr/bin/env python$|!/usr/bin/env python2|' \
+    "$pkgdir"/usr/lib/xulrunner-devel-$pkgver/sdk/bin/{xpt,header,typelib,xpidl}.py
+}

Copied: xulrunner/repos/community-staging-x86_64/freetype261.patch (from rev 197033, xulrunner/trunk/freetype261.patch)
===================================================================
--- community-staging-x86_64/freetype261.patch	                        (rev 0)
+++ community-staging-x86_64/freetype261.patch	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,31 @@
+
+# HG changeset patch
+# User Mike Hommey <mh+mozilla at glandium.org>
+# Date 1439509838 -32400
+# Node ID af40750720b59cb7af58c32f4f3325d6e03bbbc4
+# Parent  e578cc44a96a2a953e75e295b0d8954f467d5cff
+Bug 1194520 - Add a system header wrapper for <freetype/ftfntfmt.h>. r=mshal
+
+
+diff --git a/config/system-headers b/config/system-headers
+--- a/config/system-headers
++++ b/config/system-headers
+@@ -450,16 +450,17 @@ foundation/base64.h
+ foundation/hexdump.h
+ #endif
+ fp.h
+ fpieee.h
+ frame/log.h
+ frame/req.h
+ freetype/freetype.h
+ freetype/ftcache.h
++freetype/ftfntfmt.h
+ freetype/ftglyph.h
+ freetype/ftsynth.h
+ freetype/ftoutln.h
+ freetype/ttnameid.h
+ freetype/tttables.h
+ freetype/t1tables.h
+ freetype/ftlcdfil.h
+ freetype/ftsizes.h
+

Copied: xulrunner/repos/community-staging-x86_64/gcc6.diff (from rev 197033, xulrunner/trunk/gcc6.diff)
===================================================================
--- community-staging-x86_64/gcc6.diff	                        (rev 0)
+++ community-staging-x86_64/gcc6.diff	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,37 @@
+--- mozilla-release/config/gcc-stl-wrapper.template.h	2015-10-14 23:40:56.000000000 +0200
++++ mozilla-release/config/gcc-stl-wrapper.template.h.new	2016-06-14 19:40:50.542435101 +0200
+@@ -22,6 +22,11 @@
+ #define NOMINMAX 1
+ #endif
+ 
++// Don't include mozalloc for cstdlib. See bug 1245076.
++#ifndef moz_dont_include_mozalloc_for_cstdlib
++#  define moz_dont_include_mozalloc_for_cstdlib
++#endif
++#ifndef moz_dont_include_mozalloc_for_${HEADER}
+ // mozalloc.h wants <new>; break the cycle by always explicitly
+ // including <new> here.  NB: this is a tad sneaky.  Sez the gcc docs:
+ //
+@@ -30,15 +35,17 @@
+ //    same name as the current file. It simply looks for the file
+ //    named, starting with the directory in the search path after the
+ //    one where the current file was found.
+-#include_next <new>
++#  include_next <new>
+ 
+ // See if we're in code that can use mozalloc.  NB: this duplicates
+ // code in nscore.h because nscore.h pulls in prtypes.h, and chromium
+ // can't build with that being included before base/basictypes.h.
+-#if !defined(XPCOM_GLUE) && !defined(NS_NO_XPCOM) && !defined(MOZ_NO_MOZALLOC)
+-#  include "mozilla/mozalloc.h"
+-#else
+-#  error "STL code can only be used with infallible ::operator new()"
++#  if !defined(XPCOM_GLUE) && !defined(NS_NO_XPCOM) && !defined(MOZ_NO_MOZALLOC)
++#    include "mozilla/mozalloc.h"
++#  else
++#    error "STL code can only be used with infallible ::operator new()"
++#  endif
++
+ #endif
+ 
+ #if defined(DEBUG) && !defined(_GLIBCXX_DEBUG)

Copied: xulrunner/repos/community-staging-x86_64/mozconfig (from rev 197033, xulrunner/trunk/mozconfig)
===================================================================
--- community-staging-x86_64/mozconfig	                        (rev 0)
+++ community-staging-x86_64/mozconfig	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,33 @@
+. $topsrcdir/xulrunner/config/mozconfig
+
+ac_add_options --prefix=/usr
+ac_add_options --libdir=/usr/lib
+
+# System libraries
+ac_add_options --with-system-nspr
+ac_add_options --with-system-nss
+ac_add_options --with-system-jpeg
+ac_add_options --with-system-zlib
+ac_add_options --with-system-bz2
+ac_add_options --with-system-png
+ac_add_options --with-system-libevent
+ac_add_options --with-system-libvpx
+ac_add_options --with-system-icu
+ac_add_options --with-system-graphite2
+#ac_add_options --enable-system-hunspell   # cannot use system hunspell 1.5.0
+ac_add_options --enable-system-sqlite
+ac_add_options --enable-system-ffi
+ac_add_options --enable-system-cairo
+ac_add_options --enable-system-pixman
+ac_add_options --with-pthreads
+
+# Features
+ac_add_options --enable-startup-notification
+ac_add_options --enable-gstreamer=1.0
+ac_add_options --disable-crashreporter
+ac_add_options --disable-updater
+ac_add_options --disable-tests
+ac_add_options --disable-installer
+
+# https://bugzilla.mozilla.org/show_bug.cgi?id=955876
+#ac_add_options --enable-release

Copied: xulrunner/repos/community-staging-x86_64/mozilla-pkgconfig.patch (from rev 197033, xulrunner/trunk/mozilla-pkgconfig.patch)
===================================================================
--- community-staging-x86_64/mozilla-pkgconfig.patch	                        (rev 0)
+++ community-staging-x86_64/mozilla-pkgconfig.patch	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,40 @@
+diff -Nur mozilla-release.orig/xulrunner/installer/libxul-embedding.pc.in mozilla-release/xulrunner/installer/libxul-embedding.pc.in
+--- mozilla-release.orig/xulrunner/installer/libxul-embedding.pc.in	2011-12-19 22:11:38.100005674 +0000
++++ mozilla-release/xulrunner/installer/libxul-embedding.pc.in	2011-12-19 22:14:35.095147521 +0000
+@@ -6,5 +6,6 @@
+ Name: libxul-embedding
+ Description: Static library for version-independent embedding of the Mozilla runtime
+ Version: %MOZILLA_VERSION%
++Requires: %NSPR_NAME% >= %NSPR_VERSION%
+ Libs: -L${sdkdir}/lib -lxpcomglue -ldl
+ Cflags: -DXPCOM_GLUE -I${includedir} %WCHAR_CFLAGS%
+diff -Nur mozilla-release.orig/xulrunner/installer/libxul.pc.in mozilla-release/xulrunner/installer/libxul.pc.in
+--- mozilla-release.orig/xulrunner/installer/libxul.pc.in	2011-12-19 22:11:38.126672110 +0000
++++ mozilla-release/xulrunner/installer/libxul.pc.in	2011-12-19 22:14:04.375412141 +0000
+@@ -1,5 +1,6 @@
+ prefix=%prefix%
+ sdkdir=%sdkdir%
++libdir=%libdir%
+ includedir=%includedir%
+ idldir=%idldir%
+ 
+diff -Nur mozilla-release.orig/xulrunner/installer/Makefile.in mozilla-release/xulrunner/installer/Makefile.in
+--- mozilla-release.orig/xulrunner/installer/Makefile.in	2011-12-19 22:11:38.126672110 +0000
++++ mozilla-release/xulrunner/installer/Makefile.in	2011-12-19 22:18:28.743135321 +0000
+@@ -108,6 +108,7 @@
+ 	-e "s|%includedir%|$(includedir)|" \
+ 	-e "s|%idldir%|$(idldir)|" \
+ 	-e "s|%sdkdir%|$(sdkdir)|" \
++	-e "s|%libdir%|$(installdir)|" \
+ 	-e "s|%MOZ_APP_NAME%|$(MOZ_APP_NAME)|" \
+ 	-e "s|%MOZILLA_VERSION%|$(MOZ_APP_VERSION)|" \
+ 	-e "s|%WCHAR_CFLAGS%|$(WCHAR_CFLAGS)|" \
+diff -Nur mozilla-release.orig/xulrunner/installer/mozilla-js.pc.in mozilla-release/xulrunner/installer/mozilla-js.pc.in
+--- mozilla-release.orig/xulrunner/installer/mozilla-js.pc.in	2011-12-19 22:11:38.126672110 +0000
++++ mozilla-release/xulrunner/installer/mozilla-js.pc.in	2011-12-19 22:18:55.569571004 +0000
+@@ -7,4 +7,4 @@
+ Version: %MOZILLA_VERSION%
+ Requires: %NSPR_NAME% >= %NSPR_VERSION%
+ Libs: -L${sdkdir}/lib %MOZ_JS_LINK%
+-Cflags: -I${includedir} -DXP_UNIX
++Cflags: -I${includedir} -I${includedir}/js -DXP_UNIX

Copied: xulrunner/repos/community-staging-x86_64/shared-libs.patch (from rev 197033, xulrunner/trunk/shared-libs.patch)
===================================================================
--- community-staging-x86_64/shared-libs.patch	                        (rev 0)
+++ community-staging-x86_64/shared-libs.patch	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,12 @@
+diff -Nur mozilla-release.orig/browser/installer/Makefile.in mozilla-release/browser/installer/Makefile.in
+--- mozilla-release.orig/browser/installer/Makefile.in	2012-07-17 16:19:29.480356991 +0000
++++ mozilla-release/browser/installer/Makefile.in	2012-07-17 17:32:41.250937293 +0000
+@@ -17,7 +17,7 @@
+ 
+ # Some files have been already bundled with xulrunner
+ ifndef MOZ_MULET
+-MOZ_PKG_FATAL_WARNINGS = 1
++MOZ_PKG_FATAL_WARNINGS = 0
+ endif
+ 
+ DEFINES += -DAB_CD=$(AB_CD) -DMOZ_APP_NAME=$(MOZ_APP_NAME) -DPREF_DIR=$(PREF_DIR)

Copied: xulrunner/repos/community-staging-x86_64/unbreak-plugin-build.patch (from rev 197033, xulrunner/trunk/unbreak-plugin-build.patch)
===================================================================
--- community-staging-x86_64/unbreak-plugin-build.patch	                        (rev 0)
+++ community-staging-x86_64/unbreak-plugin-build.patch	2016-11-27 15:19:05 UTC (rev 197034)
@@ -0,0 +1,76 @@
+
+# HG changeset patch
+# User Ehsan Akhgari <ehsan at mozilla.com>
+# Date 1392421799 18000
+# Node ID 0691948a0abedc7db35c4cb67ec11ad06f782ab0
+# Parent  6f78482c5792b03adca38c924cc4a41f6e16b8ff
+Bug 784739 follow-up: Use NULL in npruntime.h
+
+diff --git a/dom/plugins/base/npruntime.h b/dom/plugins/base/npruntime.h
+--- a/dom/plugins/base/npruntime.h
++++ b/dom/plugins/base/npruntime.h
+@@ -132,23 +132,23 @@ void NPN_ReleaseVariantValue(NPVariant *
+ #define NPVARIANT_TO_INT32(_v)   ((_v).value.intValue)
+ #define NPVARIANT_TO_DOUBLE(_v)  ((_v).value.doubleValue)
+ #define NPVARIANT_TO_STRING(_v)  ((_v).value.stringValue)
+ #define NPVARIANT_TO_OBJECT(_v)  ((_v).value.objectValue)
+ 
+ #define VOID_TO_NPVARIANT(_v)                                                 \
+ NP_BEGIN_MACRO                                                                \
+     (_v).type = NPVariantType_Void;                                           \
+-    (_v).value.objectValue = nullptr;                                         \
++    (_v).value.objectValue = NULL;                                            \
+ NP_END_MACRO
+ 
+ #define NULL_TO_NPVARIANT(_v)                                                 \
+ NP_BEGIN_MACRO                                                                \
+     (_v).type = NPVariantType_Null;                                           \
+-    (_v).value.objectValue = nullptr;                                         \
++    (_v).value.objectValue = NULL;                                            \
+ NP_END_MACRO
+ 
+ #define BOOLEAN_TO_NPVARIANT(_val, _v)                                        \
+ NP_BEGIN_MACRO                                                                \
+     (_v).type = NPVariantType_Bool;                                           \
+     (_v).value.boolValue = !!(_val);                                          \
+ NP_END_MACRO
+ 
+@@ -211,17 +211,17 @@ typedef void *NPIdentifier;
+ 
+ /*
+     NPObjects have methods and properties.  Methods and properties are
+     identified with NPIdentifiers.  These identifiers may be reflected
+     in script.  NPIdentifiers can be either strings or integers, IOW,
+     methods and properties can be identified by either strings or
+     integers (i.e. foo["bar"] vs foo[1]). NPIdentifiers can be
+     compared using ==.  In case of any errors, the requested
+-    NPIdentifier(s) will be nullptr. NPIdentifier lifetime is controlled
++    NPIdentifier(s) will be NULL. NPIdentifier lifetime is controlled
+     by the browser. Plugins do not need to worry about memory management
+     with regards to NPIdentifiers.
+ */
+ NPIdentifier NPN_GetStringIdentifier(const NPUTF8 *name);
+ void NPN_GetStringIdentifiers(const NPUTF8 **names, int32_t nameCount,
+                               NPIdentifier *identifiers);
+ NPIdentifier NPN_GetIntIdentifier(int32_t intid);
+ bool NPN_IdentifierIsString(NPIdentifier identifier);
+@@ -278,17 +278,17 @@ typedef bool (*NPConstructFunctionPtr)(N
+     NPInvokeFunctionPtr function may return 0 to indicate a void
+     result.
+ 
+     NPInvalidateFunctionPtr is called by the scripting environment
+     when the native code is shutdown.  Any attempt to message a
+     NPObject instance after the invalidate callback has been
+     called will result in undefined behavior, even if the native code
+     is still retaining those NPObject instances.  (The runtime
+-    will typically return immediately, with 0 or nullptr, from an
++    will typically return immediately, with 0 or NULL, from an
+     attempt to dispatch to a NPObject, but this behavior should not
+     be depended upon.)
+ 
+     The NPEnumerationFunctionPtr function may pass an array of
+     NPIdentifiers back to the caller. The callee allocs the memory of
+     the array using NPN_MemAlloc(), and it's the caller's responsibility
+     to release it using NPN_MemFree().
+ */
+



More information about the arch-commits mailing list