Hello.
I'm posting the procedure that I used (found online and changed accordingly) to install the opus codec and make it fully functional for Asterisk 13.x
Everything seems to be working but I'd prefer that Ward checked everything himself since I'm compiling from source and that can possibly lead to issues
So Ward to the wise use with caution or better yet wait until this gets approved
1) Install latest OPUS
2) Check if everything went ok and the library is indeed available
You should get something like
libopus.so.0 -> libopus.so.0.5.3
Note: The ldconfig command gave me a bit of trouble. Sometimes it seems to execute fine, other times it gives an error. In case you get an error try with:
You should see the above mentioned libraries inside the list after executing the command
3) Download patch files for Asterisk 13 (different patches for earlier versions)
4) Apply patch to Asterisk 13 source
5) We are now ready to recompile
6) Now we check to see if module is installed
You should get something like
codec_opus.so
res_format_attr_opus.so
7) Restart Asterisk and do some final checks
8) Final step is to go from inside the GUI to Settings --> Asterisk SIP Settings and enable and drag up the OPUS codec checkbox. Submit and Apply and you are ready
That's all.
Test it, change it and (why not) add it to the main IncrediblePBX installation script if possible
I'm posting the procedure that I used (found online and changed accordingly) to install the opus codec and make it fully functional for Asterisk 13.x
Everything seems to be working but I'd prefer that Ward checked everything himself since I'm compiling from source and that can possibly lead to issues
So Ward to the wise use with caution or better yet wait until this gets approved
1) Install latest OPUS
Code:
cd /root
wget http://downloads.xiph.org/releases/opus/opus-1.1.3.tar.gz
tar xvzf opus-1.1.3.tar.gz
rm -rf opus-1.1.3.tar.gz
cd opus-1.1.3/
./configure
make
make install
2) Check if everything went ok and the library is indeed available
Code:
ldconfig
/sbin/ldconfig -v | grep opus
You should get something like
libopus.so.0 -> libopus.so.0.5.3
Note: The ldconfig command gave me a bit of trouble. Sometimes it seems to execute fine, other times it gives an error. In case you get an error try with:
Code:
locate libopus
3) Download patch files for Asterisk 13 (different patches for earlier versions)
Code:
cd /root
wget https://github.com/seanbright/asterisk-opus/archive/asterisk-13.3.zip
mv asterisk-13.3.zip opus-vp8-asterisk-13.3.zip
unzip opus-vp8-asterisk-13.3.zip
rm opus-vp8-asterisk-13.3.zip
4) Apply patch to Asterisk 13 source
Code:
cd /usr/src/asterisk-13*
cp ../../../root/asterisk-opus-asterisk-13.3/codecs/* codecs/
cp ../../../root/asterisk-opus-asterisk-13.3/formats/* formats/
patch -p1 < ../../../root/asterisk-opus-asterisk-13.3/asterisk.patch
5) We are now ready to recompile
Code:
amportal stop
./bootstrap.sh
./configure --prefix=/usr
make menuselect # Make sure codec_opus and format_vp8 are selected, save and Exit
make
make install
6) Now we check to see if module is installed
Code:
ls /usr/lib/asterisk/modules/ | grep opus
codec_opus.so
res_format_attr_opus.so
7) Restart Asterisk and do some final checks
Code:
amportal restart
asterisk -rvvv
module load codec_opus.so # it's probably already loaded but just to make sure
core show translation # and you should see opus in the list
8) Final step is to go from inside the GUI to Settings --> Asterisk SIP Settings and enable and drag up the OPUS codec checkbox. Submit and Apply and you are ready
That's all.
Test it, change it and (why not) add it to the main IncrediblePBX installation script if possible
Last edited: