diff --git a/corosync-trunk_r1767.diff b/corosync-trunk_r1767.diff new file mode 100644 index 0000000..73d9a7e --- /dev/null +++ b/corosync-trunk_r1767.diff @@ -0,0 +1,15 @@ +Index: exec/crypto.c +=================================================================== +--- exec/crypto.c (revision 1766) ++++ exec/crypto.c (working copy) +@@ -37,8 +37,8 @@ + #define ENDIAN_LITTLE + #elif _BYTE_ORDER == _BIG_ENDIAN + #define ENDIAN_BIG +-#elif +-#warning "cannot detect byte order" ++#else ++#error "cannot detect byte order" + #endif + + #if defined(COROSYNC_LINUX) diff --git a/corosync-trunk_r1774.diff b/corosync-trunk_r1774.diff new file mode 100644 index 0000000..22252b2 --- /dev/null +++ b/corosync-trunk_r1774.diff @@ -0,0 +1,23 @@ +Index: exec/vsf_quorum.c +=================================================================== +--- exec/vsf_quorum.c (revision 1773) ++++ exec/vsf_quorum.c (revision 1774) +@@ -119,12 +119,14 @@ + memcpy(&quorum_ring_id, ring_id, sizeof (quorum_ring_id)); + + quorum_view_list_entries = view_list_entries; ++ ++ /* Tell sync() only if there is a new ring_id (ie this is not a 'fake' quorum event) */ ++ if (memcmp(&quorum_ring_id, ring_id, sizeof (quorum_ring_id))) { ++ sync_primary_callback_fn(view_list, view_list_entries, ++ primary_designated, ring_id); ++ } + memcpy(quorum_view_list, view_list, sizeof(unsigned int)*view_list_entries); + +- /* Tell sync() */ +- sync_primary_callback_fn(view_list, view_list_entries, +- primary_designated, &quorum_ring_id); +- + /* Tell internal listeners */ + send_internal_notification(); + diff --git a/corosync.spec b/corosync.spec index 19f9f91..a233eac 100644 --- a/corosync.spec +++ b/corosync.spec @@ -3,12 +3,13 @@ Name: corosync Summary: The Corosync Cluster Engine and Application Programming Interfaces Version: 0.93 -Release: 1%{?alphatag:.%{alphatag}}%{?dist} +Release: 2%{?alphatag:.%{alphatag}}%{?dist} License: BSD Group: System Environment/Base URL: http://www.openais.org Source0: http://developer.osdl.org/dev/openais/downloads/corosync-%{version}/corosync-%{version}.tar.gz -Patch0: gcc-44-fix.diff +Patch0: corosync-trunk_r1767.diff +Patch1: corosync-trunk_r1774.diff # Runtime bits Requires: corosynclib = %{version}-%{release} @@ -25,6 +26,7 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) %prep %setup -q -n corosync-%{version} %patch0 -p0 +%patch1 -p0 %build @@ -186,6 +188,10 @@ The Corosync Cluster Engine APIs. %{_mandir}/man8/votequorum_overview.8* %changelog +* Mon Feb 23 2009 Fabio M. Di Nitto - 0.93-2 +- Rename gcc-4.4 patch to match svn commit (r1767). +- Backport patch from trunk (commit r1774) to fix quorum engine. + * Thu Feb 19 2009 Fabio M. Di Nitto - 0.93-1 - New upstream release. - Drop alphatag from spec file. diff --git a/gcc-44-fix.diff b/gcc-44-fix.diff deleted file mode 100644 index 73d9a7e..0000000 --- a/gcc-44-fix.diff +++ /dev/null @@ -1,15 +0,0 @@ -Index: exec/crypto.c -=================================================================== ---- exec/crypto.c (revision 1766) -+++ exec/crypto.c (working copy) -@@ -37,8 +37,8 @@ - #define ENDIAN_LITTLE - #elif _BYTE_ORDER == _BIG_ENDIAN - #define ENDIAN_BIG --#elif --#warning "cannot detect byte order" -+#else -+#error "cannot detect byte order" - #endif - - #if defined(COROSYNC_LINUX)