<p>Jenkins2 <strong>merged</strong> this change.</p><p><a href="https://gerrit.asterisk.org/6822">View Change</a></p><div style="white-space:pre-wrap">Approvals:
Joshua Colp: Looks good to me, but someone else must approve
George Joseph: Looks good to me, approved
Jenkins2: Approved for Submit
</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">res_corosync: Fix linking issue with Corosync 2.x<br><br>At some point in time in the history of Corosync (certainly within the<br>2.x branch), the corosync_cfg_state_track function was removed.<br>Unfortunately, the cfg library is only linked if this function is<br>present. Without the cfg library being linked to res_corosync, loading<br>of res_corosync will fail.<br><br>This patch makes it so that detecting corosync's core libraries,<br>determined by the COROSYNC external library checks, links both the cpg<br>and cfg libraries with res_corosync.<br><br>Change-Id: I674e9e1c8fea11c3bf81154aaa7c1fd43f945465<br>---<br>M configure<br>M configure.ac<br>2 files changed, 21 insertions(+), 9 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">diff --git a/configure b/configure<br>index 8308b9e..784e775 100755<br>--- a/configure<br>+++ b/configure<br>@@ -1330,6 +1330,7 @@<br> docdir<br> oldincludedir<br> includedir<br>+runstatedir<br> localstatedir<br> sharedstatedir<br> sysconfdir<br>@@ -1511,6 +1512,7 @@<br> sysconfdir='${prefix}/etc'<br> sharedstatedir='${prefix}/com'<br> localstatedir='${prefix}/var'<br>+runstatedir='${localstatedir}/run'<br> includedir='${prefix}/include'<br> oldincludedir='/usr/include'<br> docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'<br>@@ -1763,6 +1765,15 @@<br> | -silent | --silent | --silen | --sile | --sil)<br> silent=yes ;;<br> <br>+ -runstatedir | --runstatedir | --runstatedi | --runstated \<br>+ | --runstate | --runstat | --runsta | --runst | --runs \<br>+ | --run | --ru | --r)<br>+ ac_prev=runstatedir ;;<br>+ -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \<br>+ | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \<br>+ | --run=* | --ru=* | --r=*)<br>+ runstatedir=$ac_optarg ;;<br>+<br> -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)<br> ac_prev=sbindir ;;<br> -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \<br>@@ -1900,7 +1911,7 @@<br> for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \<br> datadir sysconfdir sharedstatedir localstatedir includedir \<br> oldincludedir docdir infodir htmldir dvidir pdfdir psdir \<br>- libdir localedir mandir<br>+ libdir localedir mandir runstatedir<br> do<br> eval ac_val=\$$ac_var<br> # Remove trailing slashes.<br>@@ -2053,6 +2064,7 @@<br> --sysconfdir=DIR read-only single-machine data [PREFIX/etc]<br> --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]<br> --localstatedir=DIR modifiable single-machine data [PREFIX/var]<br>+ --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]<br> --libdir=DIR object code libraries [EPREFIX/lib]<br> --includedir=DIR C header files [PREFIX/include]<br> --oldincludedir=DIR C header files for non-gcc [/usr/include]<br>@@ -14703,7 +14715,7 @@<br> We can't simply define LARGE_OFF_T to be 9223372036854775807,<br> since some C++ compilers masquerading as C compilers<br> incorrectly reject 9223372036854775807. */<br>-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))<br>+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))<br> int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721<br> && LARGE_OFF_T % 2147483647 == 1)<br> ? 1 : -1];<br>@@ -14749,7 +14761,7 @@<br> We can't simply define LARGE_OFF_T to be 9223372036854775807,<br> since some C++ compilers masquerading as C compilers<br> incorrectly reject 9223372036854775807. */<br>-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))<br>+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))<br> int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721<br> && LARGE_OFF_T % 2147483647 == 1)<br> ? 1 : -1];<br>@@ -14773,7 +14785,7 @@<br> We can't simply define LARGE_OFF_T to be 9223372036854775807,<br> since some C++ compilers masquerading as C compilers<br> incorrectly reject 9223372036854775807. */<br>-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))<br>+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))<br> int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721<br> && LARGE_OFF_T % 2147483647 == 1)<br> ? 1 : -1];<br>@@ -14818,7 +14830,7 @@<br> We can't simply define LARGE_OFF_T to be 9223372036854775807,<br> since some C++ compilers masquerading as C compilers<br> incorrectly reject 9223372036854775807. */<br>-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))<br>+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))<br> int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721<br> && LARGE_OFF_T % 2147483647 == 1)<br> ? 1 : -1];<br>@@ -14842,7 +14854,7 @@<br> We can't simply define LARGE_OFF_T to be 9223372036854775807,<br> since some C++ compilers masquerading as C compilers<br> incorrectly reject 9223372036854775807. */<br>-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))<br>+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))<br> int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721<br> && LARGE_OFF_T % 2147483647 == 1)<br> ? 1 : -1];<br>@@ -31141,7 +31153,7 @@<br> $as_echo_n "(cached) " >&6<br> else<br> ac_check_lib_save_LIBS=$LIBS<br>-LIBS="-lcpg ${pbxlibdir} -lcpg $LIBS"<br>+LIBS="-lcpg ${pbxlibdir} -lcpg -lcfg $LIBS"<br> cat confdefs.h - <<_ACEOF >conftest.$ac_ext<br> /* end confdefs.h. */<br> <br>@@ -31183,7 +31195,7 @@<br> <br> # now check for the header.<br> if test "${AST_COROSYNC_FOUND}" = "yes"; then<br>- COROSYNC_LIB="${pbxlibdir} -lcpg -lcpg"<br>+ COROSYNC_LIB="${pbxlibdir} -lcpg -lcpg -lcfg"<br> # if --with-COROSYNC=DIR has been specified, use it.<br> if test "x${COROSYNC_DIR}" != "x"; then<br> COROSYNC_INCLUDE="-I${COROSYNC_DIR}/include"<br>diff --git a/configure.ac b/configure.ac<br>index 6c5f4e3..1cdeea9 100644<br>--- a/configure.ac<br>+++ b/configure.ac<br>@@ -2374,7 +2374,7 @@<br> AST_EXT_LIB_CHECK([RADIUS], [radiusclient-ng], [rc_read_config], [radiusclient-ng.h])<br> fi<br> <br>-AST_EXT_LIB_CHECK([COROSYNC], [cpg], [cpg_join], [corosync/cpg.h], [-lcpg])<br>+AST_EXT_LIB_CHECK([COROSYNC], [cpg], [cpg_join], [corosync/cpg.h], [-lcpg -lcfg])<br> AST_EXT_LIB_CHECK([COROSYNC_CFG_STATE_TRACK], [cfg], [corosync_cfg_state_track], [corosync/cfg.h], [-lcfg])<br> <br> AST_EXT_LIB_CHECK([SPEEX], [speex], [speex_encode], [speex/speex.h], [-lm])<br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/6822">change 6822</a>. To unsubscribe, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/6822"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 13 </div>
<div style="display:none"> Gerrit-MessageType: merged </div>
<div style="display:none"> Gerrit-Change-Id: I674e9e1c8fea11c3bf81154aaa7c1fd43f945465 </div>
<div style="display:none"> Gerrit-Change-Number: 6822 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Joshua Colp <jcolp@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins2 </div>
<div style="display:none"> Gerrit-Reviewer: Joshua Colp <jcolp@digium.com> </div>