[Home]

Summary:ASTERISK-27709: [patch] BuildSystem: Avoid == for comparison in ./configure.
Reporter:Alexander Traud (traud)Labels:patch
Date Opened:2018-03-02 04:41:53.000-0600Date Closed:2018-03-05 12:16:15.000-0600
Priority:MinorRegression?
Status:Closed/CompleteComponents:Core/BuildSystem
Versions:13.19.2 15.2.1 Frequency of
Occurrence
Related
Issues:
Environment:NetBSD 7.1.1Attachments:( 0) test_jansson.patch
Description:With Asterisk 12 and commit [cf9324b|http://github.com/asterisk/asterisk/commit/cf9324b25eb8a7dc5cef77f54e12758dfbcd6645], the external library Jansson got a required dependency. Therefore, the script {{./configure}} tests and stops when that library is not present . Because of a typo, that test fails in some shells, for example in the default shell of NetBSD 7.1.1.

*Steps to Reproduce*
{code}ftp http://downloads.asterisk.org/pub/telephony/asterisk/asterisk-13-current.tar.gz
tar -zxf asterisk-*
cd asterisk-*
export PKG_PATH="http://cdn.NetBSD.org/pub/pkgsrc/packages/$(uname -s)/$(uname -p)/$(uname -r)/All"
pkg_add gcc7 gmake pkg-config editline jansson sqlite3 libuuid libxml2 wget mozilla-rootcerts
mozilla-rootcerts install
CC="/usr/pkg/gcc7/bin/gcc" CXX="/usr/pkg/gcc7/bin/g++" CFLAGS="-I/usr/pkg/include" LDFLAGS="-L/usr/pkg/lib -Wl,-R/usr/pkg/lib" ./configure{code}

*Expected Results*
The script {{./configure}} should succeed without any warning or error.

*Actual Results*
{code}test: ==: unexpected operator{code}

*Notes*
The attached patch does not simply change the '==' to '=' but uses the PBX_ test for consistency with the rest of the code. The short-term workaround is to install the Jansson library which avoids that error. The same issue was already found/posted two years ago in December 2015 by John Nemeth, member of the NetBSD team.
Comments:By: Asterisk Team (asteriskteam) 2018-03-02 04:41:54.494-0600

Thanks for creating a report! The issue has entered the triage process. That means the issue will wait in this status until a Bug Marshal has an opportunity to review the issue. Once the issue has been reviewed you will receive comments regarding the next steps towards resolution.

A good first step is for you to review the [Asterisk Issue Guidelines|https://wiki.asterisk.org/wiki/display/AST/Asterisk+Issue+Guidelines] if you haven't already. The guidelines detail what is expected from an Asterisk issue report.

Then, if you are submitting a patch, please review the [Patch Contribution Process|https://wiki.asterisk.org/wiki/display/AST/Patch+Contribution+Process].

By: Friendly Automation (friendly-automation) 2018-03-05 12:16:16.016-0600

Change 8400 merged by Joshua Colp:
BuildSystem: Avoid == for comparison in ./configure.

[https://gerrit.asterisk.org/8400|https://gerrit.asterisk.org/8400]

By: Friendly Automation (friendly-automation) 2018-03-05 12:27:45.252-0600

Change 8402 merged by Jenkins2:
BuildSystem: Avoid == for comparison in ./configure.

[https://gerrit.asterisk.org/8402|https://gerrit.asterisk.org/8402]

By: Friendly Automation (friendly-automation) 2018-03-05 12:37:46.023-0600

Change 8401 merged by Jenkins2:
BuildSystem: Avoid == for comparison in ./configure.

[https://gerrit.asterisk.org/8401|https://gerrit.asterisk.org/8401]