[asterisk-bugs] [JIRA] (ASTERISK-27931) [patch] BuildSystem: Enable ./configure in Solaris 11.

Alexander Traud (JIRA) noreply at issues.asterisk.org
Thu Jun 21 03:19:54 CDT 2018


Alexander Traud created ASTERISK-27931:
------------------------------------------

             Summary: [patch] BuildSystem: Enable ./configure in Solaris 11.
                 Key: ASTERISK-27931
                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-27931
             Project: Asterisk
          Issue Type: Bug
      Security Level: None
          Components: Core/BuildSystem
    Affects Versions: 15.4.1, 13.21.1
         Environment: Solaris 11.3
            Reporter: Alexander Traud
         Attachments: solaris_raii.patch

To avoid any confusion: Solaris 11 is a platform [not supported officially|http://lists.digium.com/pipermail/asterisk-dev/2018-January/076770.html] but relies on contributions from the community. This patch here is part of a series to get Asterisk going on the latest Oracle Solaris. Or stated differently: Much more must be done, to get Asterisk working there. Let us tackle this one after another.

This issues was caused by Commit [29304d1|http://github.com/asterisk/asterisk/commit/29304d10a0981fddf020b0c8655d041d3f15960f#diff-67e997bcfdac55191033d57a16d1408a] (ASTERISK-20850). The problem is the use of double-quotes within backticks within double-quotes. Some shell parsers like the one of Solaris 11, do not match the backticks but stop on double-quote. The parser thinks the quote ended after {{`echo}}. The rest is then executed on the shell, which creates chaos.

On the Stack Exchange network, a lot of discussions exists how to tackle this: [387246|http://unix.stackexchange.com/q/387246]. My approach are single-quotes as inner quotes because their content is needed literally. As a side-effect that helps the parser not to end the initial quote. That approach is taken in the attached patch.

Normally, single-quotes within double-quotes [lose their meaning|http://unix.stackexchange.com/a/169512]. However, the single-quotes are within backticks and evaluated as 'usual'. Other approaches would have been:
* replace backticks with {{$(...)}} and/or
* replace the double-quotes with test -n or test -z.



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



More information about the asterisk-bugs mailing list