[asterisk-bugs] [JIRA] (ASTERISK-25591) [patch] Complete List of Header Files (#include): iwyu

Asterisk Team (JIRA) noreply at issues.asterisk.org
Wed Nov 25 07:29:33 CST 2015


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

Asterisk Team commented on ASTERISK-25591:
------------------------------------------

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].

> [patch] Complete List of Header Files (#include): iwyu
> ------------------------------------------------------
>
>                 Key: ASTERISK-25591
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-25591
>             Project: Asterisk
>          Issue Type: New Feature
>      Security Level: None
>            Reporter: Alexander Traud
>            Severity: Trivial
>
> Recently, I had to add a new module. Therefore, I had to list all its header files. Thanks to the Clang support added in May 2015, one can use the Google project include-what-you-use ([iwyu|http://include-what-you-use.org/]) with Asterisk now.
> For example, in Ubuntu 14.04 LTS:
> {{sudo apt-get -y install build-essential libssl-dev libncurses-dev libnewt-dev libxml2-dev libsqlite3-dev uuid-dev libjansson-dev libblocksruntime-dev git iwyu}}
> {{cd /usr/src/}}
> {{git clone http://gerrit.asterisk.org/asterisk}}
> {{cd asterisk/}}
> {{./configure}}
> {{make}}
> {{include-what-you-use -fblocks -DAST_MODULE=NULL -DAST_MODULE_SELF=NULL -I$PWD/include res/res_format_attr_opus.c}}
> Asterisk uses the two proxy/wrapper headers {{asterisk/compat.h}} and {{asterisk/astmm.h}} which should never be included. Instead, {{asterisk.h}} should be used. To automate this, I had to add three pragma statements. With the attached patch, iwyu works out of the box. If more headers should never be included, Asterisk team, please say so!
> Thanks to iwyu, the list of header files was a simple copy-and-paste experience. Hopefully, this helps others to create better lists of header files, too. Therefore, please, consider this change/feature for inclusion.



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



More information about the asterisk-bugs mailing list