diff -Nurd -x'*~' mozilla-release.orig/.mozconfig mozilla-release/.mozconfig
--- mozilla-release.orig/.mozconfig	1969-12-31 19:00:00.000000000 -0500
+++ mozilla-release/.mozconfig	2015-10-13 02:33:27.000000000 -0400
@@ -0,0 +1,45 @@
+# sh
+# Build configuration script
+#
+# See https://developer.mozilla.org/en/Configuring_Build_Options for build options.
+#
+
+. $topsrcdir/browser/config/mozconfig
+
+# Options for client.mk.
+# environment variables to set
+
+mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/obj-@FINK_ARCH_TARGET@-apple-darwin`uname -r`
+mk_add_options AUTOCONF=@FINKPREFIX@/lib/autoconf2.13/bin/autoconf
+ac_add_options --target=@FINK_ARCH_TARGET@-apple-darwin`uname -r`
+
+# Options for 'configure' (same as command-line options).
+ac_add_options --prefix=@FINKPREFIX@
+ac_add_options --enable-official-branding
+ac_add_options --with-distribution-id=org.fink
+ac_add_options --enable-default-toolkit=cairo-gtk2
+ac_add_options --disable-gnomevfs
+ac_add_options --disable-gnomeui
+ac_add_options --enable-extensions=default,-gnomevfs
+
+ac_add_options --disable-dependency-tracking
+ac_add_options --disable-crashreporter
+#ac_add_options --disable-ipc
+#ac_add_options --enable-necko-wifi
+ac_add_options --disable-libnotify
+
+ac_add_options --disable-debug
+ac_add_options --disable-tests
+ac_add_options --enable-strip
+#ac_add_options --enable-strip # causes build-failure under clang
+#    (See: https://bugzilla.redhat.com/show_bug.cgi?id=515700)
+#    (See: https://llvm.org/bugs/show_bug.cgi?id=19658)
+#ac_add_options --enable-strip # causes build-failure under clang
+#ac_add_options --with-default-mozilla-five-home=@FINKPREFIX@/lib/firefox@FIREFOX_MAJOR_VERSION@
+ac_add_options --with-system-jpeg=@FINKPREFIX@/lib/libjpeg8.2-turbo
+ac_add_options --disable-system-cairo
+ac_add_options --enable-system-sqlite
+ac_add_options --with-system-nspr
+ac_add_options --with-nspr-prefix=@FINKPREFIX@
+ac_add_options --with-system-nss
+ac_add_options --with-nss-prefix=@FINKPREFIX@
diff -Nurd -x'*~' mozilla-release.orig/browser/locales/generic/profile/bookmarks.html.in mozilla-release/browser/locales/generic/profile/bookmarks.html.in
--- mozilla-release.orig/browser/locales/generic/profile/bookmarks.html.in	2011-11-20 14:44:27.000000000 -0500
+++ mozilla-release/browser/locales/generic/profile/bookmarks.html.in	2015-10-13 02:33:27.000000000 -0400
@@ -13,6 +13,7 @@
     <DL><p>
         <DT><A HREF="http://www.mozilla.com/@AB_CD@/firefox/central/" ID="rdf:#$GvPhC3">@getting_started@</A>
         <DT><A HREF="http://fxfeeds.mozilla.com/@AB_CD@/firefox/livebookmarks/" FEEDURL="http://fxfeeds.mozilla.com/@AB_CD@/firefox/headlines.xml" ID="rdf:#$HvPhC3">@latest_headlines@</A>
+        <DT><A HREF="http://www.finkproject.org/" ICON_URI="http://www.finkproject.org/favicon.ico" ICON="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAA+0lEQVQ4jWNgGDLg/6sTqv9OVe75uzv43J+TpUv/MzAwEqfxfEfU3y3O///u9P//d5v7/7/HCir/vz8n//9ir9+fffF+eDX/O5yxCqLR4///28u0GRgYGP6uN/sPN/zNBWlMG9+e4Pt7tq0bbutO//9/t3v9///qFQ9e2/7uCZ3/b3fwvX9HMg//PZpz7e9O//9/9ye8+Lc34ubf7V7/f1+e4Irdj3dWVf//f5UNzn91VeLvzoD/f0+U1OK1EadLtrr8/3+uoYcszf+PZHX/OxB/jizNDAwMDP92BX0hW/P/o1k7ydbMwMDA8P98D/ZQJkrz+6sJFNk+oAAAPwyICxl3w8YAAAAASUVORK5CYII=">Fink - Home</A>
     </DL><p>
     <DT><H3 ID="rdf:#$ZvPhC3">@firefox_heading@</H3>
     <DL><p>
diff -Nurd -x'*~' mozilla-release.orig/config/autoconf.mk.in mozilla-release/config/autoconf.mk.in
--- mozilla-release.orig/config/autoconf.mk.in	2011-11-20 14:44:27.000000000 -0500
+++ mozilla-release/config/autoconf.mk.in	2015-10-13 02:33:27.000000000 -0400
@@ -62,14 +62,14 @@
 prefix		= @prefix@
 exec_prefix	= @exec_prefix@
 bindir		= @bindir@
-includedir	= @includedir@/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)
+includedir	= @includedir@/$(MOZ_APP_NAME)@FIREFOX_MAJOR_VERSION@
 libdir		= @libdir@
 datadir		= @datadir@
 mandir		= @mandir@
-idldir		= $(datadir)/idl/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)
+idldir		= $(datadir)/idl/$(MOZ_APP_NAME)@FIREFOX_MAJOR_VERSION@
 
-installdir	= $(libdir)/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)
-sdkdir		= $(libdir)/$(MOZ_APP_NAME)-devel-$(MOZ_APP_VERSION)
+installdir	= $(libdir)/$(MOZ_APP_NAME)@FIREFOX_MAJOR_VERSION@
+sdkdir		= $(libdir)/$(MOZ_APP_NAME)@FIREFOX_MAJOR_VERSION@-devel
 
 DIST		= $(DEPTH)/dist
 LIBXUL_SDK      = @LIBXUL_SDK@
diff -Nurd -x'*~' mozilla-release.orig/configure.in mozilla-release/configure.in
--- mozilla-release.orig/configure.in	2011-11-20 14:44:27.000000000 -0500
+++ mozilla-release/configure.in	2015-10-13 02:33:27.000000000 -0400
@@ -1955,7 +1955,8 @@
     ;;
 
 *-darwin*)
-    HOST_CFLAGS="$HOST_CFLAGS -DXP_UNIX -DXP_MACOSX -DNO_X11"
+    HOST_CFLAGS="$HOST_CFLAGS -DXP_UNIX -DXP_MACOSX"
+    HOST_CXXFLAGS="$HOST_CFLAGS -DXP_UNIX -DXP_MACOSX"
     HOST_NSPR_MDCPUCFG='\"md/_darwin.cfg\"'
     HOST_OPTIMIZE_FLAGS="${HOST_OPTIMIZE_FLAGS=-O3}"
     ;;
diff -Nurd -x'*~' mozilla-release.orig/content/svg/content/src/SVGNumberList.cpp mozilla-release/content/svg/content/src/SVGNumberList.cpp
--- mozilla-release.orig/content/svg/content/src/SVGNumberList.cpp	2011-11-20 14:44:29.000000000 -0500
+++ mozilla-release/content/svg/content/src/SVGNumberList.cpp	2015-10-13 02:33:27.000000000 -0400
@@ -93,7 +93,7 @@
   while (tokenizer.hasMoreTokens()) {
     CopyUTF16toUTF8(tokenizer.nextToken(), str); // NS_ConvertUTF16toUTF8
     const char *token = str.get();
-    if (token == '\0') {
+    if (*token == '\0') {
       return NS_ERROR_DOM_SYNTAX_ERR; // nothing between commas
     }
     char *end;
diff -Nurd -x'*~' mozilla-release.orig/fink/applications/firefox.desktop mozilla-release/fink/applications/firefox.desktop
--- mozilla-release.orig/fink/applications/firefox.desktop	1969-12-31 19:00:00.000000000 -0500
+++ mozilla-release/fink/applications/firefox.desktop	2015-10-13 02:33:27.000000000 -0400
@@ -0,0 +1,10 @@
+[Desktop Entry]
+Encoding=UTF-8
+Name=Firefox Web Browser
+Comment=Browse the World Wide Web
+Exec=firefox
+Icon=firefox.png
+Terminal=false
+Type=Application
+Categories=Application;Network
+StartupNotify=true
diff -Nurd -x'*~' mozilla-release.orig/fink/fink.js mozilla-release/fink/fink.js
--- mozilla-release.orig/fink/fink.js	1969-12-31 19:00:00.000000000 -0500
+++ mozilla-release/fink/fink.js	2015-10-13 02:33:27.000000000 -0400
@@ -0,0 +1 @@
+pref("dom.ipc.plugins.enabled", false);
diff -Nurd -x'*~' mozilla-release.orig/netwerk/wifi/nsWifiMonitor.h mozilla-release/netwerk/wifi/nsWifiMonitor.h
--- mozilla-release.orig/netwerk/wifi/nsWifiMonitor.h	2011-11-20 14:44:47.000000000 -0500
+++ mozilla-release/netwerk/wifi/nsWifiMonitor.h	2015-10-13 02:33:27.000000000 -0400
@@ -89,7 +89,7 @@
 
   nsresult DoScan();
 
-#if defined(XP_MACOSX)
+#if defined(__APPLE__)
   nsresult DoScanWithCoreWLAN();
   nsresult DoScanOld();
 #endif
diff -Nurd -x'*~' mozilla-release.orig/xpcom/io/nsAppFileLocationProvider.cpp mozilla-release/xpcom/io/nsAppFileLocationProvider.cpp
--- mozilla-release.orig/xpcom/io/nsAppFileLocationProvider.cpp	2011-11-20 14:44:55.000000000 -0500
+++ mozilla-release/xpcom/io/nsAppFileLocationProvider.cpp	2015-10-13 02:33:27.000000000 -0400
@@ -236,9 +236,9 @@
     else if (nsCRT::strcmp(prop, NS_SYSTEM_PLUGINS_DIR) == 0) {
         static const char *const sysLPlgDir = 
 #if defined(HAVE_USR_LIB64_DIR) && defined(__LP64__)
-          "/usr/lib64/mozilla/plugins";
+          "@FINKPREFIX@/lib64/mozilla/plugins";
 #else
-          "/usr/lib/mozilla/plugins";
+          "@FINKPREFIX@/lib/mozilla/plugins";
 #endif
         rv = NS_NewNativeLocalFile(nsDependentCString(sysLPlgDir),
                                    PR_FALSE, getter_AddRefs(localFile));
