[asterisk-bugs] [JIRA] (ASTERISK-28374) latest asterisk unconditionally launch gcc --version, even if the compiler is different

Alexander Traud (JIRA) noreply at issues.asterisk.org
Thu Mar 26 06:30:25 CDT 2020


    [ https://issues.asterisk.org/jira/browse/ASTERISK-28374?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=250044#comment-250044 ] 

Alexander Traud edited comment on ASTERISK-28374 at 3/26/20 6:28 AM:
---------------------------------------------------------------------

Although the latest ‘Certified Asterisk’ was released in December, it is still affected by this issue because it is based on Asterisk 16.3. The change was not backported but is going to come when ‘ Certified Asterisk 16.8’ is released. Therefore, I am adding the shown error message for those who have GCC installed alongside, so it is found easier perhaps:
{code}clang: error: unknown argument: '-fno-partial-inlining'{code}
Until asterisk-certified-16.8-cert1 is released, either go for
a) patch from the review ([Gerrit|https://gerrit.asterisk.org/changes/asterisk~11239/revisions/2/patch?zip&path=Makefile.rules] or [GitHub|https://github.com/asterisk/asterisk/commit/4dcfa8d1277b23a933152e37db342ff3e6c07c51.patch]) or
b) {{make menuselect}} → Compiler Flags → DONT_OPTIMIZE: Enable _and_ (because of ASTERISK-28792) Codec Translator → codec_gsm: Disable
c) not a certified release but the [current release…|https://www.asterisk.org/downloads/asterisk/all-asterisk-versions]


was (Author: traud):
Although the latest ‘Certified Asterisk’ was released in December, it is still affected by this issue because it is based on Asterisk 16.3. The change was not backported but is going to come when ‘ Certified Asterisk 16.8’ is released. Therefore, I am adding the shown error message for those who have GCC installed alongside, so it is found easier perhaps:
{code}clang: error: unknown argument: '-fno-partial-inlining'{code}
Until asterisk-certified-16.8-cert1 is released, either go for
a) patch from the review ([Gerrit|https://gerrit.asterisk.org/changes/asterisk~11239/revisions/2/patch?zip&path=Makefile.rules] or [GitHub|https://github.com/asterisk/asterisk/commit/4dcfa8d1277b23a933152e37db342ff3e6c07c51.patch]) or
b) {{make menuselect}} → Compiler Flags → DONT_OPTIMIZE: Enable _and_ (because of another bug) Codec Translator → codec_gsm: Disable
c) not a certified release but the [current release…|https://www.asterisk.org/downloads/asterisk/all-asterisk-versions]

> latest asterisk unconditionally launch gcc --version, even if the compiler is different
> ---------------------------------------------------------------------------------------
>
>                 Key: ASTERISK-28374
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-28374
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Core/BuildSystem
>    Affects Versions: 13.26.0, 16.3.0
>         Environment: Any where main compiler is named differently than gcc, but there is also gcc 8.x around.
> Encountered in the FreeBSD port.
>            Reporter: Guido Falsi
>            Assignee: Guido Falsi
>            Severity: Minor
>      Target Release: 13.27.0, 16.4.0, 17.0.0
>
>
> In latest asterisk a check for GCC version has been added. It is performed by unconditionally running "gcc --version".
> If the main compiler being used is another one (F.E. cc) this check will test the wrong compiler and add compiler flags which may be incorrect.
> On FreeBSD the main compiler is clang, named cc. When gcc 8 is installed on the system, this check will return true, and add a compiler flag which is refused by clang, causing the build to fail.
> I'm going to propose a review on gerrit patching the Makefile to perform the check using the $(CC) variable, containing the actual compiler being used for the build.



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list