(Created page with "In Ear Headphones are generally headphones that directly placed within the ears. They are tailored and so which they can be held at the particular opening of the particular ea...") |
(Updated for Asterisk 11.11.0) |
||
(12 intermediate revisions by one user not shown) | |||
Line 1: | Line 1: | ||
− | + | == Prerequisites == | |
− | + | ||
− | + | === ncurses === | |
− | + | ||
− | + | Download, build and install the ncurses library: | |
− | + | ||
− | + | <PRE> | |
+ | wget http://ftp.gnu.org/pub/gnu/ncurses/ncurses-5.9.tar.gz | ||
+ | tar -xzf ncurses-5.9.tar.gz | ||
+ | cd ncurses-5.9 | ||
+ | ./configure --host=arm-linux-gnueabi --prefix=/usr/arm-linux-gnueabi CXX="arm-linux-gnueabi-g++" | ||
+ | make | ||
+ | make install | ||
+ | </PRE> | ||
+ | |||
+ | === SQLite === | ||
+ | |||
+ | [http://sqlite.org/ SQLite] is a software library that implements a self contained server-less transactional SQL database engine. | ||
+ | |||
+ | <PRE> | ||
+ | wget https://sqlite.org/2014/sqlite-autoconf-3080500.tar.gz | ||
+ | tar -xzf sqlite-autoconf-3080500.tar.gz | ||
+ | cd sqlite-autoconf-3080500 | ||
+ | ./configure --host=arm-linux-gnueabi --prefix=/usr/arm-linux-gnueabi | ||
+ | make | ||
+ | make install | ||
+ | </PRE> | ||
+ | |||
+ | === OpenSSL === | ||
+ | |||
+ | Certain Asterisk modules such as chan_sip and chan_iax2 require the res_crypto resource module. The res_crypto module will only be built if the libssl dependency is installed. | ||
+ | |||
+ | <PRE> | ||
+ | wget http://www.openssl.org/source/openssl-1.0.1h.tar.gz | ||
+ | tar -xzf openssl-1.0.1h.tar.gz | ||
+ | cd openssl-1.0.1h | ||
+ | ./Configure linux-generic32 shared --prefix=/usr/arm-linux-gnueabi | ||
+ | make CC=arm-linux-gnueabi-gcc RANLIB=arm-linux-gnueabi-ranlib LD=arm-linux-gnueabi-ld MAKEDEPPROG=arm-linux-gnueabi-gcc | ||
+ | make install CC=arm-linux-gnueabi-gcc RANLIB=arm-linux-gnueabi-ranlib LD=arm-linux-gnueabi-ld | ||
+ | </PRE> | ||
+ | |||
+ | === BlueZ Bluetooth Libraries (Optional) === | ||
+ | |||
+ | If you want to use chan_mobile to connect asterisk to your mobile phone via Bluetooth, then you will require the Bluetooth libraries and header files installed at this point. | ||
+ | |||
+ | See [[Cross_Compiling_BlueZ_Bluetooth_tools_for_ARM|Cross Compiling BlueZ Bluetooth tools for ARM]] | ||
+ | |||
+ | == Asterisk == | ||
+ | |||
+ | With all our prerequisites built, you can now download, build and install Asterisk: | ||
+ | |||
+ | <PRE> | ||
+ | wget http://downloads.asterisk.org/pub/telephony/asterisk/releases/asterisk-11.11.0.tar.gz | ||
+ | tar -xzf asterisk-11.11.0.tar.gz | ||
+ | cd asterisk-11.11.0 | ||
+ | ./configure --host=arm-linux-gnueabi --target=arm-linux-gnueabi --build=i686-pc-linux-gnu --disable-xmldoc | ||
+ | make menuselect | ||
+ | make | ||
+ | sudo make install DESTDIR=/home/export/rootfs | ||
+ | sudo make samples DESTDIR=/home/export/rootfs | ||
+ | </PRE> | ||
+ | |||
+ | Asterisk will require shared libraries to load. Copy over libsqlite3.so, libssl.so, libcrypto.so and libgcc_s.so to your root filesystem: | ||
+ | |||
+ | <PRE> | ||
+ | cp /usr/arm-linux-gnueabi/lib/libz.so.1.2.8 /home/export/rootfs/lib | ||
+ | cp /usr/arm-linux-gnueabi/lib/libsqlite3.so.0.8.6 /home/export/rootfs/lib | ||
+ | cp /usr/arm-linux-gnueabi/lib/libssl.so.1.0.0 /home/export/rootfs/lib | ||
+ | cp /usr/arm-linux-gnueabi/lib/libcrypto.so.1.0.0 /home/export/rootfs/lib | ||
+ | cp /usr/lib/gcc-cross/arm-linux-gnueabi/4.7.3/libgcc_s.so.1 /home/export/rootfs/lib | ||
+ | </PRE> | ||
+ | |||
+ | And if you are using chan_mobile (Bluetooth): | ||
+ | |||
+ | <PRE> | ||
+ | cp /usr/arm-linux-gnueabi/lib/libbluetooth.so.3.17.8 /home/export/rootfs/lib | ||
+ | </PRE> | ||
+ | |||
+ | In addition to the above new libraries, Asterisk also places libasteriskssl.so in /usr/lib. If ldconfig is not executed to re-configure dynamic linker run-time bindings, Asterisk is likely to generate an error: error while loading shared libraries: libasteriskssl.so.1: cannot open shared object file: No such file or directory. | ||
+ | |||
+ | To generate new dynamic linker run-time bindings, on the actual host, execute: | ||
+ | |||
+ | <PRE> | ||
+ | ldconfig -v | ||
+ | </PRE> | ||
+ | |||
+ | Outside of modifying Asterisk configuration files, Asterisk should now we ready to run. To start with a console CLI: | ||
+ | |||
+ | <PRE> | ||
+ | asterisk -c | ||
+ | </PRE> |
Download, build and install the ncurses library:
wget http://ftp.gnu.org/pub/gnu/ncurses/ncurses-5.9.tar.gz tar -xzf ncurses-5.9.tar.gz cd ncurses-5.9 ./configure --host=arm-linux-gnueabi --prefix=/usr/arm-linux-gnueabi CXX="arm-linux-gnueabi-g++" make make install
SQLite is a software library that implements a self contained server-less transactional SQL database engine.
wget https://sqlite.org/2014/sqlite-autoconf-3080500.tar.gz tar -xzf sqlite-autoconf-3080500.tar.gz cd sqlite-autoconf-3080500 ./configure --host=arm-linux-gnueabi --prefix=/usr/arm-linux-gnueabi make make install
Certain Asterisk modules such as chan_sip and chan_iax2 require the res_crypto resource module. The res_crypto module will only be built if the libssl dependency is installed.
wget http://www.openssl.org/source/openssl-1.0.1h.tar.gz tar -xzf openssl-1.0.1h.tar.gz cd openssl-1.0.1h ./Configure linux-generic32 shared --prefix=/usr/arm-linux-gnueabi make CC=arm-linux-gnueabi-gcc RANLIB=arm-linux-gnueabi-ranlib LD=arm-linux-gnueabi-ld MAKEDEPPROG=arm-linux-gnueabi-gcc make install CC=arm-linux-gnueabi-gcc RANLIB=arm-linux-gnueabi-ranlib LD=arm-linux-gnueabi-ld
If you want to use chan_mobile to connect asterisk to your mobile phone via Bluetooth, then you will require the Bluetooth libraries and header files installed at this point.
See Cross Compiling BlueZ Bluetooth tools for ARM
With all our prerequisites built, you can now download, build and install Asterisk:
wget http://downloads.asterisk.org/pub/telephony/asterisk/releases/asterisk-11.11.0.tar.gz tar -xzf asterisk-11.11.0.tar.gz cd asterisk-11.11.0 ./configure --host=arm-linux-gnueabi --target=arm-linux-gnueabi --build=i686-pc-linux-gnu --disable-xmldoc make menuselect make sudo make install DESTDIR=/home/export/rootfs sudo make samples DESTDIR=/home/export/rootfs
Asterisk will require shared libraries to load. Copy over libsqlite3.so, libssl.so, libcrypto.so and libgcc_s.so to your root filesystem:
cp /usr/arm-linux-gnueabi/lib/libz.so.1.2.8 /home/export/rootfs/lib cp /usr/arm-linux-gnueabi/lib/libsqlite3.so.0.8.6 /home/export/rootfs/lib cp /usr/arm-linux-gnueabi/lib/libssl.so.1.0.0 /home/export/rootfs/lib cp /usr/arm-linux-gnueabi/lib/libcrypto.so.1.0.0 /home/export/rootfs/lib cp /usr/lib/gcc-cross/arm-linux-gnueabi/4.7.3/libgcc_s.so.1 /home/export/rootfs/lib
And if you are using chan_mobile (Bluetooth):
cp /usr/arm-linux-gnueabi/lib/libbluetooth.so.3.17.8 /home/export/rootfs/lib
In addition to the above new libraries, Asterisk also places libasteriskssl.so in /usr/lib. If ldconfig is not executed to re-configure dynamic linker run-time bindings, Asterisk is likely to generate an error: error while loading shared libraries: libasteriskssl.so.1: cannot open shared object file: No such file or directory.
To generate new dynamic linker run-time bindings, on the actual host, execute:
ldconfig -v
Outside of modifying Asterisk configuration files, Asterisk should now we ready to run. To start with a console CLI:
asterisk -c