summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mozilla-670719.patch53
-rw-r--r--thunderbird-enigmail.spec46
-rw-r--r--xulrunner-2.0-NetworkManager09.patch51
-rw-r--r--xulrunner-2.0-network-link-service.patch274
-rw-r--r--xulrunner-install.patch12
5 files changed, 417 insertions, 19 deletions
diff --git a/mozilla-670719.patch b/mozilla-670719.patch
new file mode 100644
index 0000000..afae907
--- /dev/null
+++ b/mozilla-670719.patch
@@ -0,0 +1,53 @@
+# HG changeset patch
+# User Mike Hommey <mh+mozilla@glandium.org>
+# Date 1313846520 -7200
+# Node ID fdc3b63938f5a76d99c1e2bb12fd448465debc94
+# Parent 07a5a618ebe3f67b23100ceb1b51e92bb79be0cd
+Bug 670719 - Only add -DENABLE_JIT=1 to CXXFLAGS if any of trace/method/yarr jit is enabled.
+
+diff --git a/js/src/Makefile.in b/js/src/Makefile.in
+--- a/js/src/Makefile.in
++++ b/js/src/Makefile.in
+@@ -433,16 +433,19 @@ CPPSRCS += \
+ YarrPattern.cpp \
+ YarrSyntaxChecker.cpp \
+ $(NULL)
+ else
+
+ ###############################################
+ # BEGIN include sources for the Nitro assembler
+ #
++
++ENABLE_YARR_JIT = 1
++
+ VPATH += $(srcdir)/assembler \
+ $(srcdir)/assembler/wtf \
+ $(srcdir)/assembler/jit \
+ $(srcdir)/assembler/assembler \
+ $(srcdir)/methodjit \
+ $(srcdir)/yarr \
+ $(NONE)
+
+@@ -1070,17 +1073,21 @@ endif
+
+ ###############################################
+ # BEGIN kludges for the Nitro assembler
+ #
+
+ # Needed to "configure" it correctly. Unfortunately these
+ # flags wind up being applied to all code in js/src, not just
+ # the code in js/src/assembler.
+-CXXFLAGS += -DUSE_SYSTEM_MALLOC=1 -DENABLE_ASSEMBLER=1 -DENABLE_JIT=1
++CXXFLAGS += -DUSE_SYSTEM_MALLOC=1 -DENABLE_ASSEMBLER=1
++
++ifneq (,$(ENABLE_YARR_JIT)$(ENABLE_TRACEJIT)$(ENABLE_METHODJIT))
++CXXFLAGS += -DENABLE_JIT=1
++endif
+
+ INCLUDES += -I$(srcdir)/assembler -I$(srcdir)/yarr
+
+ ifdef ENABLE_METHODJIT
+ # Build a standalone test program that exercises the assembler
+ # sources a bit.
+ TESTMAIN_OBJS = \
+ Assertions.$(OBJ_SUFFIX) \
diff --git a/thunderbird-enigmail.spec b/thunderbird-enigmail.spec
index 5f9e8ad..4735f43 100644
--- a/thunderbird-enigmail.spec
+++ b/thunderbird-enigmail.spec
@@ -8,7 +8,7 @@
%define build_langpacks 1
%define thunderbird_app_id \{3550f703-e582-4d05-9a08-453d09bdfdc6\}
-%global thunver 7.0.1
+%global thunver 8.0
# The tarball is pretty inconsistent with directory structure.
# Sometimes there is a top level directory. That goes here.
@@ -26,7 +26,7 @@
Summary: Authentication and encryption extension for Mozilla Thunderbird
Name: thunderbird-enigmail
-Version: 1.3.2
+Version: 1.3.3
%if 0%{?prever:1}
Release: 0.1.%{prever}%{?dist}
%else
@@ -60,6 +60,12 @@ Source101: enigmail-fixlang.php
Patch0: thunderbird-install-dir.patch
Patch7: crashreporter-remove-static.patch
Patch8: xulrunner-6.0-secondary-ipc.patch
+Patch9: mozilla-670719.patch
+Patch10: xulrunner-2.0-network-link-service.patch
+Patch11: xulrunner-2.0-NetworkManager09.patch
+
+# Build patches
+Patch100: xulrunner-install.patch
# Enigmail patch
@@ -111,9 +117,6 @@ BuildRequires: yasm
BuildRequires: mesa-libGL-devel
BuildRequires: GConf2-devel
BuildRequires: lcms-devel >= %{lcms_version}
-%ifarch %{ix86} x86_64
-BuildRequires: wireless-tools-devel
-%endif
## For fixing lang
BuildRequires: dos2unix, php-cli
@@ -146,6 +149,10 @@ cd %{tarballdir}
cd mozilla
%patch7 -p2 -b .static
%patch8 -p2 -b .secondary-ipc
+%patch9 -p1 -b .moz670719
+%patch10 -p1 -b .link-service
+%patch11 -p1 -b .NetworkManager09
+%patch100 -p2 -b .install
cd ..
%if %{official_branding}
@@ -169,17 +176,14 @@ cat %{SOURCE10} \
%if 0%{?fedora} < 15 && 0%{?rhel} <= 6
| grep -v enable-system-cairo \
%endif
-%ifarch %{ix86} x86_64
- | grep -v disable-necko-wifi \
-%endif
| tee .mozconfig
cat <<EOF | tee -a .mozconfig
-ac_add_options --enable-libnotify
-ac_add_options --enable-system-lcms
+#ac_add_options --enable-libnotify
+#ac_add_options --enable-system-lcms
ac_add_options --enable-chrome-format=jar
%if 0%{?fedora} >= 15
-ac_add_options --enable-system-sqlite
+#ac_add_options --enable-system-sqlite
%endif
%if 0%{?fedora} < 14 && 0%{?rhel} <= 6
ac_add_options --disable-libjpeg-turbo
@@ -238,19 +242,20 @@ export CXXFLAGS=$MOZ_OPT_FLAGS
export PREFIX='%{_prefix}'
export LIBDIR='%{_libdir}'
-%define moz_make_flags -j1
-%ifarch ppc ppc64 s390 s390x
-%define moz_make_flags -j1
-%else
-%define moz_make_flags %{?_smp_mflags}
+MOZ_SMP_FLAGS=-j1
+# On x86 architectures, Mozilla can build up to 4 jobs at once in parallel,
+# however builds tend to fail on other arches when building in parallel.
+%ifarch %{ix86} x86_64
+[ -z "$RPM_BUILD_NCPUS" ] && \
+ RPM_BUILD_NCPUS="`/usr/bin/getconf _NPROCESSORS_ONLN`"
+[ "$RPM_BUILD_NCPUS" -ge 2 ] && MOZ_SMP_FLAGS=-j2
+[ "$RPM_BUILD_NCPUS" -ge 4 ] && MOZ_SMP_FLAGS=-j4
%endif
-export LDFLAGS="-Wl,-rpath,%{mozappdir}"
-export MAKE="gmake %{moz_make_flags}"
# ===== Thunderbird build =====
# http://enigmail.mozdev.org/download/source.php.html
-make -f client.mk build
+make -f client.mk build STRIP="/bin/true" MOZ_MAKE_FLAGS="$MOZ_SMP_FLAGS"
# ===== Enigmail work =====
pushd mailnews/extensions/enigmail
@@ -284,6 +289,9 @@ cd %{tarballdir}
#===============================================================================
%changelog
+* Sat Nov 12 2011 Remi Collet <remi@fedoraproject.org> 1.3.3-1
+- Enigmail 1.3.3 for Thunderbird 8.0
+
* Wed Oct 12 2011 Georgi Georgiev <chutzimir@gmail.com> - 1.3.2-2
- Make it work on RHEL
diff --git a/xulrunner-2.0-NetworkManager09.patch b/xulrunner-2.0-NetworkManager09.patch
new file mode 100644
index 0000000..317a1b4
--- /dev/null
+++ b/xulrunner-2.0-NetworkManager09.patch
@@ -0,0 +1,51 @@
+https://bugzilla.mozilla.org/show_bug.cgi?id=639959
+
+--- source/toolkit/system/dbus/nsNetworkManagerListener.cpp.foo 2011-03-08 14:26:28.167074923 -0600
++++ source/toolkit/system/dbus/nsNetworkManagerListener.cpp 2011-03-08 14:30:54.260748294 -0600
+@@ -51,15 +51,13 @@
+ #define NM_DBUS_SERVICE "org.freedesktop.NetworkManager"
+ #define NM_DBUS_PATH "/org/freedesktop/NetworkManager"
+ #define NM_DBUS_INTERFACE "org.freedesktop.NetworkManager"
+-#define NM_DBUS_SIGNAL_STATE_CHANGE "StateChange"
+-typedef enum NMState
+-{
+- NM_STATE_UNKNOWN = 0,
+- NM_STATE_ASLEEP,
+- NM_STATE_CONNECTING,
+- NM_STATE_CONNECTED,
+- NM_STATE_DISCONNECTED
+-} NMState;
++#define NM_DBUS_SIGNAL_STATE_CHANGE "StateChange" /* Deprecated in 0.7.x */
++#define NM_DBUS_SIGNAL_STATE_CHANGED "StateChanged"
++
++#define NM_STATE_CONNECTED_OLD 3
++#define NM_STATE_CONNECTED_LOCAL 50
++#define NM_STATE_CONNECTED_SITE 60
++#define NM_STATE_CONNECTED_GLOBAL 70
+
+ nsNetworkManagerListener::nsNetworkManagerListener() :
+ mLinkUp(PR_TRUE), mNetworkManagerActive(PR_FALSE),
+@@ -174,7 +172,9 @@
+ PRBool
+ nsNetworkManagerListener::HandleMessage(DBusMessage* message) {
+ if (dbus_message_is_signal(message, NM_DBUS_INTERFACE,
+- NM_DBUS_SIGNAL_STATE_CHANGE)) {
++ NM_DBUS_SIGNAL_STATE_CHANGE) ||
++ dbus_message_is_signal(message, NM_DBUS_INTERFACE,
++ NM_DBUS_SIGNAL_STATE_CHANGED)) {
+ UpdateNetworkStatus(message);
+ return PR_TRUE;
+ }
+@@ -191,7 +191,10 @@
+ mNetworkManagerActive = PR_TRUE;
+
+ PRBool wasUp = mLinkUp;
+- mLinkUp = result == NM_STATE_CONNECTED;
++ mLinkUp = (result == NM_STATE_CONNECTED_OLD) ||
++ (result == NM_STATE_CONNECTED_LOCAL) ||
++ (result == NM_STATE_CONNECTED_SITE) ||
++ (result == NM_STATE_CONNECTED_GLOBAL);
+ if (wasUp == mLinkUp)
+ return;
+
+
diff --git a/xulrunner-2.0-network-link-service.patch b/xulrunner-2.0-network-link-service.patch
new file mode 100644
index 0000000..b3243a9
--- /dev/null
+++ b/xulrunner-2.0-network-link-service.patch
@@ -0,0 +1,274 @@
+# HG changeset patch
+# Parent 31879b88cc82c1f44e6a6c25a05aa2c70af22d7e
+# User Martin Stransky <stransky@redhat.com>
+Bug 627672 - XPCOM component (libdbusservice.so) is not registered although it should be; r=cbiesinger
+
+
+
+diff --git a/netwerk/base/src/nsIOService.cpp b/netwerk/base/src/nsIOService.cpp
+--- a/netwerk/base/src/nsIOService.cpp
++++ b/netwerk/base/src/nsIOService.cpp
+@@ -160,31 +160,33 @@ PRInt16 gBadPortList[] = {
+ 2049, // nfs
+ 4045, // lockd
+ 6000, // x11
+ 0, // This MUST be zero so that we can populating the array
+ };
+
+ static const char kProfileChangeNetTeardownTopic[] = "profile-change-net-teardown";
+ static const char kProfileChangeNetRestoreTopic[] = "profile-change-net-restore";
++static const char kStartupTopic[] = "profile-after-change";
+
+ // Necko buffer cache
+ nsIMemory* nsIOService::gBufferCache = nsnull;
+ PRUint32 nsIOService::gDefaultSegmentSize = 4096;
+ PRUint32 nsIOService::gDefaultSegmentCount = 24;
+
+ ////////////////////////////////////////////////////////////////////////////////
+
+ nsIOService::nsIOService()
+ : mOffline(PR_TRUE)
+ , mOfflineForProfileChange(PR_FALSE)
+ , mManageOfflineStatus(PR_TRUE)
+ , mSettingOffline(PR_FALSE)
+ , mSetOfflineValue(PR_FALSE)
+ , mShutdown(PR_FALSE)
++ , mNetworkLinkServiceInitialized(PR_FALSE)
+ , mChannelEventSinks(NS_CHANNEL_EVENT_SINK_CATEGORY)
+ , mContentSniffers(NS_CONTENT_SNIFFER_CATEGORY)
+ , mAutoDialEnabled(PR_FALSE)
+ {
+ }
+
+ nsresult
+ nsIOService::Init()
+@@ -230,16 +232,17 @@ nsIOService::Init()
+ }
+
+ // Register for profile change notifications
+ nsCOMPtr<nsIObserverService> observerService =
+ mozilla::services::GetObserverService();
+ if (observerService) {
+ observerService->AddObserver(this, kProfileChangeNetTeardownTopic, PR_TRUE);
+ observerService->AddObserver(this, kProfileChangeNetRestoreTopic, PR_TRUE);
++ observerService->AddObserver(this, kStartupTopic, PR_TRUE);
+ observerService->AddObserver(this, NS_XPCOM_SHUTDOWN_OBSERVER_ID, PR_TRUE);
+ observerService->AddObserver(this, NS_NETWORK_LINK_TOPIC, PR_TRUE);
+ }
+ else
+ NS_WARNING("failed to get observer service");
+
+ NS_TIME_FUNCTION_MARK("Registered observers");
+
+@@ -258,29 +261,19 @@ nsIOService::Init()
+ NS_WARN_IF_FALSE(NS_SUCCEEDED(rv), "Was unable to allocate. No gBufferCache.");
+ CallQueryInterface(recyclingAllocator, &gBufferCache);
+ }
+
+ NS_TIME_FUNCTION_MARK("Set up the recycling allocator");
+
+ gIOService = this;
+
+- // go into managed mode if we can, and chrome process
+- if (XRE_GetProcessType() == GeckoProcessType_Default)
+- mNetworkLinkService = do_GetService(NS_NETWORK_LINK_SERVICE_CONTRACTID);
+-
+- if (!mNetworkLinkService)
+- // We can't really determine if the machine has a usable network connection,
+- // so let's cross our fingers!
+- mManageOfflineStatus = PR_FALSE;
+-
+- if (mManageOfflineStatus)
+- TrackNetworkLinkStatusForOffline();
+- else
+- SetOffline(PR_FALSE);
++ // We can't really determine if the machine has a usable network connection,
++ // (mNetworkLinkService will be initialized later) so let's cross our fingers!
++ SetOffline(PR_FALSE);
+
+ NS_TIME_FUNCTION_MARK("Set up network link service");
+
+ return NS_OK;
+ }
+
+
+ nsIOService::~nsIOService()
+@@ -306,16 +299,57 @@ nsIOService::InitializeSocketTransportSe
+ rv = mSocketTransportService->Init();
+ NS_ASSERTION(NS_SUCCEEDED(rv), "socket transport service init failed");
+ mSocketTransportService->SetAutodialEnabled(mAutoDialEnabled);
+ }
+
+ return rv;
+ }
+
++nsresult
++nsIOService::InitializeNetworkLinkService()
++{
++ NS_TIME_FUNCTION;
++
++ nsresult rv = NS_OK;
++
++ if (mNetworkLinkServiceInitialized)
++ return rv;
++
++#if defined(MOZ_PLATFORM_MAEMO)
++ // libdbusservice fails to initialize on Maemo platform, see Bug 627672
++ mNetworkLinkService = NULL;
++#else
++ // go into managed mode if we can, and chrome process
++ if (XRE_GetProcessType() == GeckoProcessType_Default)
++ {
++ mNetworkLinkService = do_GetService(NS_NETWORK_LINK_SERVICE_CONTRACTID, &rv);
++ if (NS_FAILED(rv)) {
++ NS_WARNING("failed to get network link service");
++ return rv;
++ }
++ }
++#endif
++
++ mNetworkLinkServiceInitialized = PR_TRUE;
++
++ if (!mNetworkLinkService) {
++ // We can't really determine if the machine has a usable network connection,
++ // so let's cross our fingers!
++ mManageOfflineStatus = PR_FALSE;
++ }
++
++ if (mManageOfflineStatus)
++ TrackNetworkLinkStatusForOffline();
++ else
++ SetOffline(PR_FALSE);
++
++ return rv;
++}
++
+ nsIOService*
+ nsIOService::GetInstance() {
+ if (!gIOService) {
+ gIOService = new nsIOService();
+ if (!gIOService)
+ return nsnull;
+ NS_ADDREF(gIOService);
+
+@@ -689,16 +723,19 @@ nsIOService::NewChannel(const nsACString
+ if (NS_FAILED(rv)) return rv;
+
+ return NewChannelFromURI(uri, result);
+ }
+
+ PRBool
+ nsIOService::IsLinkUp()
+ {
++ NS_ASSERTION(mNetworkLinkServiceInitialized,
++ "network link service should be initialized");
++
+ if (!mNetworkLinkService) {
+ // We cannot decide, assume the link is up
+ return PR_TRUE;
+ }
+
+ PRBool isLinkUp;
+ nsresult rv;
+ rv = mNetworkLinkService->GetIsLinkUp(&isLinkUp);
+@@ -968,16 +1005,20 @@ nsIOService::Observe(nsISupports *subjec
+ if (mOfflineForProfileChange) {
+ mOfflineForProfileChange = PR_FALSE;
+ if (!mManageOfflineStatus ||
+ NS_FAILED(TrackNetworkLinkStatusForOffline())) {
+ SetOffline(PR_FALSE);
+ }
+ }
+ }
++ else if (!strcmp(topic, kStartupTopic)) {
++ // Lazy initialization of network link service (see bug 620472)
++ InitializeNetworkLinkService();
++ }
+ else if (!strcmp(topic, NS_XPCOM_SHUTDOWN_OBSERVER_ID)) {
+ // Remember we passed XPCOM shutdown notification to prevent any
+ // changes of the offline status from now. We must not allow going
+ // online after this point.
+ mShutdown = PR_TRUE;
+
+ SetOffline(PR_TRUE);
+
+@@ -1085,32 +1126,40 @@ nsIOService::NewSimpleNestedURI(nsIURI*
+ NS_IF_ADDREF(*aResult = new nsSimpleNestedURI(safeURI));
+ return *aResult ? NS_OK : NS_ERROR_OUT_OF_MEMORY;
+ }
+
+ NS_IMETHODIMP
+ nsIOService::SetManageOfflineStatus(PRBool aManage) {
+ PRBool wasManaged = mManageOfflineStatus;
+ mManageOfflineStatus = aManage;
++
++ if (!mNetworkLinkServiceInitialized) {
++ InitializeNetworkLinkService();
++ }
++
+ if (mManageOfflineStatus && !wasManaged)
+ return TrackNetworkLinkStatusForOffline();
+ return NS_OK;
+ }
+
+ NS_IMETHODIMP
+ nsIOService::GetManageOfflineStatus(PRBool* aManage) {
+ *aManage = mManageOfflineStatus;
+ return NS_OK;
+ }
+
+ nsresult
+ nsIOService::TrackNetworkLinkStatusForOffline()
+ {
+ NS_ASSERTION(mManageOfflineStatus,
+ "Don't call this unless we're managing the offline status");
++ NS_ASSERTION(mNetworkLinkServiceInitialized,
++ "network link service should be set up");
++
+ if (!mNetworkLinkService)
+ return NS_ERROR_FAILURE;
+
+ if (mShutdown)
+ return NS_ERROR_NOT_AVAILABLE;
+
+ // check to make sure this won't collide with Autodial
+ if (mSocketTransportService) {
+diff --git a/netwerk/base/src/nsIOService.h b/netwerk/base/src/nsIOService.h
+--- a/netwerk/base/src/nsIOService.h
++++ b/netwerk/base/src/nsIOService.h
+@@ -129,16 +129,17 @@ private:
+ nsIProtocolHandler* hdlr);
+
+ // Prefs wrangling
+ NS_HIDDEN_(void) PrefsChanged(nsIPrefBranch *prefs, const char *pref = nsnull);
+ NS_HIDDEN_(void) GetPrefBranch(nsIPrefBranch2 **);
+ NS_HIDDEN_(void) ParsePortList(nsIPrefBranch *prefBranch, const char *pref, PRBool remove);
+
+ nsresult InitializeSocketTransportService();
++ nsresult InitializeNetworkLinkService();
+
+ private:
+ PRPackedBool mOffline;
+ PRPackedBool mOfflineForProfileChange;
+ PRPackedBool mManageOfflineStatus;
+
+ // Used to handle SetOffline() reentrancy. See the comment in
+ // SetOffline() for more details.
+@@ -146,16 +147,17 @@ private:
+ PRPackedBool mSetOfflineValue;
+
+ PRPackedBool mShutdown;
+
+ nsCOMPtr<nsPISocketTransportService> mSocketTransportService;
+ nsCOMPtr<nsPIDNSService> mDNSService;
+ nsCOMPtr<nsIProtocolProxyService2> mProxyService;
+ nsCOMPtr<nsINetworkLinkService> mNetworkLinkService;
++ PRPackedBool mNetworkLinkServiceInitialized;
+
+ // Cached protocol handlers
+ nsWeakPtr mWeakHandler[NS_N(gScheme)];
+
+ // cached categories
+ nsCategoryCache<nsIChannelEventSink> mChannelEventSinks;
+ nsCategoryCache<nsIContentSniffer> mContentSniffers;
+
diff --git a/xulrunner-install.patch b/xulrunner-install.patch
new file mode 100644
index 0000000..c1393ef
--- /dev/null
+++ b/xulrunner-install.patch
@@ -0,0 +1,12 @@
+diff -up comm-release/mozilla/toolkit/mozapps/installer/packager.mk.install comm-release/mozilla/toolkit/mozapps/installer/packager.mk
+--- comm-release/mozilla/toolkit/mozapps/installer/packager.mk.install 2011-11-05 10:21:10.000000000 +0100
++++ comm-release/mozilla/toolkit/mozapps/installer/packager.mk 2011-11-08 18:48:08.674042803 +0100
+@@ -401,7 +401,7 @@ PRECOMPILE_GRE=$$PWD
+ endif
+
+ GENERATE_CACHE = \
+- $(_ABS_RUN_TEST_PROGRAM) $(LIBXUL_DIST)/bin/xpcshell$(BIN_SUFFIX) -g "$(PRECOMPILE_GRE)" -a "$$PWD" -f $(MOZILLA_DIR)/toolkit/mozapps/installer/precompile_cache.js -e "populate_startupcache('$(PRECOMPILE_DIR)', 'omni.jar', 'startupCache.zip');" && \
++ $(_ABS_RUN_TEST_PROGRAM) $(LIBXUL_DIST)/bin/xpcshell$(BIN_SUFFIX) -g "$(PRECOMPILE_GRE)" -a "$$PWD" -f $(call core_abspath,$(MOZILLA_DIR)/toolkit/mozapps/installer/precompile_cache.js) -e "populate_startupcache('$(PRECOMPILE_DIR)', 'omni.jar', 'startupCache.zip');" && \
+ rm -rf jsloader && \
+ $(UNZIP) startupCache.zip && \
+ rm startupCache.zip && \