<p>Joshua C. Colp <strong>merged</strong> this change.</p><p><a href="https://gerrit.asterisk.org/10917">View Change</a></p><div style="white-space:pre-wrap">Approvals:
George Joseph: Looks good to me, but someone else must approve
Joshua C. Colp: Looks good to me, approved; Approved for Submit
</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">build : Fix cross-compilation errors<br><br>Bundled pjproject and jansson must be configured with the host and build<br>parameters provided to the configure script.<br>Autotools do not permit to check for the existence of local header files, so<br>the control of hrirs.h must not be done when cross-compiling.<br><br>ASTERISK-28250<br><br>Change-Id: If0a76e52a87d4ab82b7d4c72d27d8759ca931880<br>---<br>M configure<br>M configure.ac<br>M third-party/jansson/configure.m4<br>M third-party/pjproject/configure.m4<br>4 files changed, 16 insertions(+), 10 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/configure b/configure</span><br><span>index a69ba62..d8e1cbf 100755</span><br><span>--- a/configure</span><br><span>+++ b/configure</span><br><span>@@ -9270,10 +9270,10 @@</span><br><span> </span><br><span> this_host=$(./config.sub $(./config.guess))</span><br><span> if test "$build" != "$this_host" ; then</span><br><span style="color: hsl(0, 100%, 40%);">- JANSSON_CONFIGURE_OPTS+=" --build=$build"</span><br><span style="color: hsl(120, 100%, 40%);">+ JANSSON_CONFIGURE_OPTS+=" --build=$build_alias"</span><br><span> fi</span><br><span> if test "$host" != "$this_host" ; then</span><br><span style="color: hsl(0, 100%, 40%);">- JANSSON_CONFIGURE_OPTS+=" --host=$host"</span><br><span style="color: hsl(120, 100%, 40%);">+ JANSSON_CONFIGURE_OPTS+=" --host=$host_alias"</span><br><span> fi</span><br><span> </span><br><span> export TAR PATCH SED NM EXTERNALS_CACHE_DIR AST_DOWNLOAD_CACHE DOWNLOAD_TO_STDOUT DOWNLOAD_TIMEOUT DOWNLOAD MD5 CAT CUT GREP</span><br><span>@@ -9391,10 +9391,10 @@</span><br><span> </span><br><span> this_host=$(./config.sub $(./config.guess))</span><br><span> if test "$build" != "$this_host" ; then</span><br><span style="color: hsl(0, 100%, 40%);">- PJPROJECT_CONFIGURE_OPTS+=" --build=$build"</span><br><span style="color: hsl(120, 100%, 40%);">+ PJPROJECT_CONFIGURE_OPTS+=" --build=$build_alias"</span><br><span> fi</span><br><span> if test "$host" != "$this_host" ; then</span><br><span style="color: hsl(0, 100%, 40%);">- PJPROJECT_CONFIGURE_OPTS+=" --host=$host"</span><br><span style="color: hsl(120, 100%, 40%);">+ PJPROJECT_CONFIGURE_OPTS+=" --host=$host_alias"</span><br><span> fi</span><br><span> # This was a copy of the autoconf generated code from the root ./configure.</span><br><span> # Hopefully, when you read this, the code is still the same.</span><br><span>@@ -34577,7 +34577,9 @@</span><br><span> fi</span><br><span> </span><br><span> # conf_bridge (binaural rendering): check if HRIRs are available</span><br><span style="color: hsl(0, 100%, 40%);">-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for bridges/bridge_softmix/include/hrirs.h" >&5</span><br><span style="color: hsl(120, 100%, 40%);">+# this check does not work when cross-compiling</span><br><span style="color: hsl(120, 100%, 40%);">+if test "${cross_compiling}" = "no"; then</span><br><span style="color: hsl(120, 100%, 40%);">+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bridges/bridge_softmix/include/hrirs.h" >&5</span><br><span> $as_echo_n "checking for bridges/bridge_softmix/include/hrirs.h... " >&6; }</span><br><span> if ${ac_cv_file_bridges_bridge_softmix_include_hrirs_h+:} false; then :</span><br><span> $as_echo_n "(cached) " >&6</span><br><span>@@ -34600,6 +34602,7 @@</span><br><span> </span><br><span> fi</span><br><span> </span><br><span style="color: hsl(120, 100%, 40%);">+fi</span><br><span> </span><br><span> ac_config_files="$ac_config_files build_tools/menuselect-deps makeopts"</span><br><span> </span><br><span>diff --git a/configure.ac b/configure.ac</span><br><span>index 9a016f4..7acfcbc 100644</span><br><span>--- a/configure.ac</span><br><span>+++ b/configure.ac</span><br><span>@@ -2811,7 +2811,10 @@</span><br><span> fi</span><br><span> </span><br><span> # conf_bridge (binaural rendering): check if HRIRs are available</span><br><span style="color: hsl(0, 100%, 40%);">-AC_CHECK_FILES([bridges/bridge_softmix/include/hrirs.h])</span><br><span style="color: hsl(120, 100%, 40%);">+# this check does not work when cross-compiling</span><br><span style="color: hsl(120, 100%, 40%);">+if test "${cross_compiling}" = "no"; then</span><br><span style="color: hsl(120, 100%, 40%);">+ AC_CHECK_FILES([bridges/bridge_softmix/include/hrirs.h])</span><br><span style="color: hsl(120, 100%, 40%);">+fi</span><br><span> </span><br><span> AC_CONFIG_FILES([build_tools/menuselect-deps makeopts])</span><br><span> AST_CHECK_MANDATORY</span><br><span>diff --git a/third-party/jansson/configure.m4 b/third-party/jansson/configure.m4</span><br><span>index 9b10cad..4570de1 100644</span><br><span>--- a/third-party/jansson/configure.m4</span><br><span>+++ b/third-party/jansson/configure.m4</span><br><span>@@ -49,10 +49,10 @@</span><br><span> AC_ARG_VAR([JANSSON_CONFIGURE_OPTS],[Additional configure options to pass to bundled jansson])</span><br><span> this_host=$(./config.sub $(./config.guess))</span><br><span> if test "$build" != "$this_host" ; then</span><br><span style="color: hsl(0, 100%, 40%);">- JANSSON_CONFIGURE_OPTS+=" --build=$build"</span><br><span style="color: hsl(120, 100%, 40%);">+ JANSSON_CONFIGURE_OPTS+=" --build=$build_alias"</span><br><span> fi</span><br><span> if test "$host" != "$this_host" ; then</span><br><span style="color: hsl(0, 100%, 40%);">- JANSSON_CONFIGURE_OPTS+=" --host=$host"</span><br><span style="color: hsl(120, 100%, 40%);">+ JANSSON_CONFIGURE_OPTS+=" --host=$host_alias"</span><br><span> fi</span><br><span> </span><br><span> export TAR PATCH SED NM EXTERNALS_CACHE_DIR AST_DOWNLOAD_CACHE DOWNLOAD_TO_STDOUT DOWNLOAD_TIMEOUT DOWNLOAD MD5 CAT CUT GREP</span><br><span>diff --git a/third-party/pjproject/configure.m4 b/third-party/pjproject/configure.m4</span><br><span>index 8541710..9175a11 100644</span><br><span>--- a/third-party/pjproject/configure.m4</span><br><span>+++ b/third-party/pjproject/configure.m4</span><br><span>@@ -49,10 +49,10 @@</span><br><span> AC_ARG_VAR([PJPROJECT_CONFIGURE_OPTS],[Additional configure options to pass to bundled pjproject])</span><br><span> this_host=$(./config.sub $(./config.guess))</span><br><span> if test "$build" != "$this_host" ; then</span><br><span style="color: hsl(0, 100%, 40%);">- PJPROJECT_CONFIGURE_OPTS+=" --build=$build"</span><br><span style="color: hsl(120, 100%, 40%);">+ PJPROJECT_CONFIGURE_OPTS+=" --build=$build_alias"</span><br><span> fi</span><br><span> if test "$host" != "$this_host" ; then</span><br><span style="color: hsl(0, 100%, 40%);">- PJPROJECT_CONFIGURE_OPTS+=" --host=$host"</span><br><span style="color: hsl(120, 100%, 40%);">+ PJPROJECT_CONFIGURE_OPTS+=" --host=$host_alias"</span><br><span> fi</span><br><span> # This was a copy of the autoconf generated code from the root ./configure.</span><br><span> # Hopefully, when you read this, the code is still the same.</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/10917">change 10917</a>. To unsubscribe, or for help writing mail filters, 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/10917"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 16 </div>
<div style="display:none"> Gerrit-MessageType: merged </div>
<div style="display:none"> Gerrit-Change-Id: If0a76e52a87d4ab82b7d4c72d27d8759ca931880 </div>
<div style="display:none"> Gerrit-Change-Number: 10917 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Jean Aunis - Prescom <jean.aunis@prescom.fr> </div>
<div style="display:none"> Gerrit-Reviewer: Friendly Automation (1000185) </div>
<div style="display:none"> Gerrit-Reviewer: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Joshua C. Colp <jcolp@digium.com> </div>