Search the Asterisk Blog

Asterisk 13.8.0: Now With Easier PJSIP Install Method!

By Joshua Colp

Asterisk 13.8.0 will come with a new option for enabling PJSIP functionality. This functionality is called bundling and comes courtesy of a community member, George Joseph, who you can also thank for such PJSIP additions as wizards for configuration and the PJSIP_HEADER dialplan function. Before we talk about bundling let’s take a look at the history of PJSIP usage in Asterisk and how we got to where we are today.

PJSIP itself is part of a set of libraries and tools which forms PJPROJECT. Another part is referred to as PJNATH and has been used since Asterisk 11 to provide ICE, STUN, and TURN support in the res_rtp_asterisk module. When Asterisk 11 was released PJPROJECT was embedded in Asterisk itself to make it easier for users to have the new functionality available. When the decision was made to work on a new PJSIP channel driver one of the desires expressed by the community was to remove PJPROJECT from Asterisk and have it be distributed using other mechanisms, such as by the distributions as packages or from a manual install process. Before Asterisk 12 was released this was completed and contributed upstream to Teluu who created PJPROJECT. This has meant that to enable PJSIP support in Asterisk you have needed to install PJPROJECT yourself using some method. As of Asterisk 13.8.0 another simpler option will be available instead: bundling.

Bundling allows a self-contained PJSIP to exist within Asterisk and be used by all functionality within it. It is enabled by passing an option to the configure script:

When the option is enabled the build process will download a version of PJPROJECT as specified in the bundling configuration, patch it with any changes that may not have yet been published in a PJPROJECT release, build it using the best options suitable for Asterisk, make it available to all the Asterisk PJSIP modules, and make the Asterisk PJSIP modules available for building. This reduces the barrier to entry for using PJSIP to a minimal amount allowing more people to use the new SIP functionality. There is no additional work required except for enabling the option.

While the lower barrier to entry may seem like the only immediate benefit there’s also some internal things that are improved by using bundling. By controlling the version of PJSIP that Asterisk is used against we can ensure that Asterisk will build and work properly against it. We can also ensure that both Asterisk and PJSIP have been built using the same configuration and that the configuration matches the usage required by Asterisk. This can lead to improved performance and reduce crashes.

There’s also no harm in using this new bundled support if you already have PJSIP installed. The PJSIP downloaded and built for Asterisk will only be bundled in Asterisk and not exposed to the rest of your system.

So if you’ve been hesitant to try PJSIP why wait? Use bundling and have PJSIP functionality enabled in no time! As each distribution and environment is different I urge you to file an issue on JIRA if you encounter any problems with the bundling option. We want to ensure it works for as many people as possible.

There Are 2 Comments

Add to the Discussion

Your email address will not be published. Required fields are marked *

About the Author

Joshua Colp

Joshua Colp is a Senior Software Developer at Digium and a long time Asterisk developer. He originally started in the community submitting simple patches and grew into improving and creating new core components of Asterisk itself. He is a self-taught programmer who believes in finding the balance between doing things the way they should be done and doing what is right for the people using the software. In his spare time he enjoys smashing fax machines.

See All of Joshua's Articles

More From
The Digium Blog

  • No items