[asterisk-bugs] [JIRA] (ASTERISK-27720) [patch] BuildSystem: Enable Advanced Linux Sound Architecture (ALSA) in NetBSD.

Alexander Traud (JIRA) noreply at issues.asterisk.org
Mon Mar 5 10:05:13 CST 2018


Alexander Traud created ASTERISK-27720:
------------------------------------------

             Summary: [patch] BuildSystem: Enable Advanced Linux Sound Architecture (ALSA) in NetBSD.
                 Key: ASTERISK-27720
                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-27720
             Project: Asterisk
          Issue Type: Bug
      Security Level: None
          Components: Channels/chan_alsa, Core/BuildSystem
    Affects Versions: 15.2.2, 13.19.2
         Environment: NetBSD 7.1.1
            Reporter: Alexander Traud
            Severity: Minor
         Attachments: NetBSD_enable_alsa.patch

A shared library should specify all its dependencies by itself. That way, a user (here: Asterisk) simply adds that library, for example:
{code}cc hello.c -lasound{code}
Then, the platform loads the dependent libraries automatically. Therefore, looking for a library without any additional libraries should be the default. Everything else should be the exception. Since Autotools were added to Asterisk, the shared library {{libasound.so}} was always loaded together with -lm and -ldl, always. Why ever. The commit logs do not reveal which platform/version required that. Anyway, {{libdl.so}} is not available on BSD systems like NetBSD.

Therefore, the attached patch first tries without any additional libraries. To keep compatibility with an unknown platform/version, the script {{./configure}} retries with those libraries as previously.

Furthermore, the error code ESTRPIPE does not exist on NetBSD.

Finally, a check for an external library should use a symbol actually used in Asterisk. {{snd_spcm_init(.)}} is not used but {{snd_pcm_open(.)}} is.



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



More information about the asterisk-bugs mailing list