Toto je neúspěšný pokus o kompilaci projektu WebRTC2SIP, který jsem zamýšlel využít v projektu. Mělo jít o spuštění se všemi závislostmi na Ubuntu Server 14.04.3 LTS x64. Vycházel jsem při tom z oficiálních tutoriálů 1 a 2, bohužel jsem se zasekl na knihovně tinyNET obsaženou ve frameworku Doubango, kterou nejsem schopný bez hlubších znalostí opravit. Vzhledem k tomu, že se Doubango již dále nevyvíjí, tak nevím, jak dále odstranění problému směřovat.
Každopádně spousta dílčích problémů byla úspěšně vyřešena, takže pokud se této problematice věnujete a přijdete na nějaký update, dejte mi vědět v komentáři pod textem. Děkuji. Teď už ale k samotnému postupu:
#programové závislosti a prerekvizity
apt-get install -y make libtool autoconf subversion git cvs wget gcc
apt-get install -y libxml2-dev
#solution for E: Unable to locate package libogg-devel
apt-get install -y libogg-dev
#solution for E: Unable to locate package gcc-c+
apt-get install -y g++
#solution for E: Unable to locate package pkgconfig
apt-get install -y pkg-config
#solution for E: Unable to locate package libvpx-devel
apt-get install -y libvpx-dev
#solution for E: Unable to locate package speex-devel
apt-get install -y libspeex-dev
#libspeex (audio codec) an libspeexdsp (audio processing and jitter buffer) are optional.
wget http://downloads.xiph.org/releases/speex/speex-1.2beta3.tar.gz
tar -xvzf speex-1.2beta3.tar.gz
cd speex-1.2beta3
./configure --disable-oggtest --without-libogg
make && make install
#libsrtp nezbytné pro zabezpečené RTP
cd /usr/src/
git clone https://github.com/cisco/libsrtp/
cd /usr/src/libsrtp
CFLAGS="-fPIC" ./configure --enable-pic
make && make install
make runtest
#error fixing
#OpenSSL nutné pro zabezpečení
cd /usr/src/
wget http://www.openssl.org/source/openssl-1.0.1c.tar.gz
tar -xvzf openssl-1.0.1c.tar.gz
rm openssl-1.0.1c.tar.gz
cd /usr/src/openssl-1.0.1c
make install_sw
./config shared --prefix=/usr/local --openssldir=/usr/local/openssl
make && make install
#cms.pod around line 474: Expected text after =item, not a number
#POD document had syntax errors at /usr/bin/pod2man line 71.
#make: *** [install_docs] Error 255
#solution:
git clone https://github.com/openssl/openssl
cd /usr/src/openssl
./config shared --prefix=/usr/local --openssldir=/usr/local/openssl
make && make install
#kodek OPUS
wget http://downloads.xiph.org/releases/opus/opus-1.0.2.tar.gz
tar -xvzf opus-1.0.2.tar.gz
cd opus-1.0.2
./configure --with-pic --enable-float-approx
make && make install
cd ..
rm opus-1.0.2.tar.gz
#Yasm Modular Assembler Project používá kodek VP8
wget http://www.tortall.net/projects/yasm/releases/yasm-1.2.0.tar.gz
tar -xvzf yasm-1.2.0.tar.gz
cd yasm-1.2.0
./configure && make && make install
cd ..
rm yasm-1.2.0.tar.gz
#podpora H.264 video codec vyžadována FFmpegem
wget ftp://ftp.videolan.org/pub/x264/snapshots/last_x264.tar.bz2
tar -xvjf last_x264.tar.bz2
cd x264-snapshot-*
./configure --enable-shared --enable-pic && make && make installcd ..
rm last_x264.tar.bz2
#FFmpeg is solution to record, convert and stream audio, video.
git clone git://source.ffmpeg.org/ffmpeg.git ffmpeg
cd ffmpeg
git checkout -b n1.2
./configure --extra-cflags="-fPIC" --extra-ldflags="-lpthread" \
--enable-pic --enable-memalign-hack --enable-pthreads \
--enable-shared --disable-static --disable-network --enable-pthreads \
--disable-ffmpeg --disable-ffplay --disable-ffserver --disable-ffprobe \
--enable-gpl --disable-debug
make && make install
#framework Doubango
cd /usr/src/
svn checkout http://doubango.googlecode.com/svn/branches/2.0/doubango doubango
cd /usr/src/doubango
./autogen.sh
./configure --with-ssl --with-srtp --with-speexdsp --with-ffmpeg
#configure: error: You requested SRTP (requires libsrtp) but not found...die
#solution: reinstall SRTP
#configure: error: You requested SSL (requires OpenSSL) but not found...die
#solution: upgrade OpenSSL above
#documented
#configure: error: You requested SPEEX DSP but not found...die
#solution: install: speex-1.2beta3.tar.gz above
make && make install
#E: make[2]: *** [src/tls/libtinyNET_la-tnet_dtls.lo] Error 1
#E: make[2]: Leaving directory `/usr/src/doubango/tinyNET'
#E: make[1]: *** [all-recursive] Error 1
#E: make[1]: Leaving directory `/usr/src/doubango'
#E: make: *** [all] Error 2
#unsuccessful solution
cd /usr/src/
wget http://www.kostecky.cz/doubango/doubango.patch --no-check-certificate
#there is antispam: check content of file!
cd doubango
patch -p0 < ./../doubango.patch
#Error patch: **** Only garbage was found in the patch input.
#solution: check content of the patch
#E: patching file rce (read from tinyNET/test/test_ice.h)
#E: Hunk #1 FAILED at 58 (different line endings).
#E: 1 out of 1 hunk FAILED -- saving rejects to file rce.rej
#E: patching file rce (read from tinyNET/src/tnet_utils.c)
#E: Hunk #1 FAILED at 200.
#E: Hunk #2 FAILED at 215.
#E: 2 out of 2 hunks FAILED -- saving rejects to file rce.rej
#E: patching file rce (read from tinyNET/src/tinynet_config.h)
#E: Hunk #1 FAILED at 88.
#E: 1 out of 1 hunk FAILED -- saving rejects to file rce.rej
make && make install
#WITHOUT SUCCESS!
#tutorial continues by this commands
svn co http://webrtc2sip.googlecode.com/svn/trunk/ webrtc2sip
export PREFIX=/etc/webrtc2sip
cd webrtc2sip
./autogen.sh
./configure --prefix=$PREFIX
make && make install
#E: mp_object.h:23:23: fatal error: tsk_debug.h: No such file or directory
#E: make[1]: *** [webrtc2sip-mp_c2c.o] Error 1
#E: make[1]: Leaving directory `/usr/src/webrtc2sip'
#E: make: *** [all] Error 2
cp -f ./config.xml $PREFIX/sbin/config.xml
webrtc2sip --help
#Doubango ./configure final screen
**************************************************************************
* CONGRATULATIONS
**************************************************************************
Cross Compilation: no
Target OS: Linux
Host setup: x86_64-unknown-linux-gnu
Install prefix: /usr/local
Compiler: gcc
Build Type: doubango
Enable GPL: yes
Enable Non Free: yes
FFmpeg: yes
VP8 video codec: yes
OpenH264 video codec: no
OPUS audio codec: yes
ILBC audio codec: no
G.729 audio codec: no -> yes
GSM audio codec: yes
AMR audio codec: no -> yes
SPEEX audio codec: yes
G.722 audio codec: yes
G.711 audio codec: yes
YUV: no
JPEG: no
SPEEX DSP: yes
SSL: yes
DTLS-SRTP: yes
DTLS: yes
SRTP: yes
WebRTC: Enabled(no): AEC(no), NS(no)
Monotonic timers: yes
RESOLV: no
ALSA (audio): no
OSS (audio): yes
V4L2 (video): yes
DEBUG: no
DEBUG_LEVEL: error
#programové závislosti a prerekvizity
apt-get install -y make libtool autoconf subversion git cvs wget gcc
apt-get install -y libxml2-dev
#solution for E: Unable to locate package libogg-devel
apt-get install -y libogg-dev
#solution for E: Unable to locate package gcc-c+
apt-get install -y g++
#solution for E: Unable to locate package pkgconfig
apt-get install -y pkg-config
#solution for E: Unable to locate package libvpx-devel
apt-get install -y libvpx-dev
#solution for E: Unable to locate package speex-devel
apt-get install -y libspeex-dev
#libspeex (audio codec) an libspeexdsp (audio processing and jitter buffer) are optional.
wget http://downloads.xiph.org/releases/speex/speex-1.2beta3.tar.gz
tar -xvzf speex-1.2beta3.tar.gz
cd speex-1.2beta3
./configure --disable-oggtest --without-libogg
make && make install
#libsrtp nezbytné pro zabezpečené RTP
cd /usr/src/
git clone https://github.com/cisco/libsrtp/
cd /usr/src/libsrtp
CFLAGS="-fPIC" ./configure --enable-pic
make && make install
make runtest
#error fixing
#OpenSSL nutné pro zabezpečení
cd /usr/src/
wget http://www.openssl.org/source/openssl-1.0.1c.tar.gz
tar -xvzf openssl-1.0.1c.tar.gz
rm openssl-1.0.1c.tar.gz
cd /usr/src/openssl-1.0.1c
make install_sw
./config shared --prefix=/usr/local --openssldir=/usr/local/openssl
make && make install
#cms.pod around line 474: Expected text after =item, not a number
#POD document had syntax errors at /usr/bin/pod2man line 71.
#make: *** [install_docs] Error 255
#solution:
git clone https://github.com/openssl/openssl
cd /usr/src/openssl
./config shared --prefix=/usr/local --openssldir=/usr/local/openssl
make && make install
#kodek OPUS
wget http://downloads.xiph.org/releases/opus/opus-1.0.2.tar.gz
tar -xvzf opus-1.0.2.tar.gz
cd opus-1.0.2
./configure --with-pic --enable-float-approx
make && make install
cd ..
rm opus-1.0.2.tar.gz
#Yasm Modular Assembler Project používá kodek VP8
wget http://www.tortall.net/projects/yasm/releases/yasm-1.2.0.tar.gz
tar -xvzf yasm-1.2.0.tar.gz
cd yasm-1.2.0
./configure && make && make install
cd ..
rm yasm-1.2.0.tar.gz
#podpora H.264 video codec vyžadována FFmpegem
wget ftp://ftp.videolan.org/pub/x264/snapshots/last_x264.tar.bz2
tar -xvjf last_x264.tar.bz2
cd x264-snapshot-*
./configure --enable-shared --enable-pic && make && make installcd ..
rm last_x264.tar.bz2
#FFmpeg is solution to record, convert and stream audio, video.
git clone git://source.ffmpeg.org/ffmpeg.git ffmpeg
cd ffmpeg
git checkout -b n1.2
./configure --extra-cflags="-fPIC" --extra-ldflags="-lpthread" \
--enable-pic --enable-memalign-hack --enable-pthreads \
--enable-shared --disable-static --disable-network --enable-pthreads \
--disable-ffmpeg --disable-ffplay --disable-ffserver --disable-ffprobe \
--enable-gpl --disable-debug
make && make install
#framework Doubango
cd /usr/src/
svn checkout http://doubango.googlecode.com/svn/branches/2.0/doubango doubango
cd /usr/src/doubango
./autogen.sh
./configure --with-ssl --with-srtp --with-speexdsp --with-ffmpeg
#configure: error: You requested SRTP (requires libsrtp) but not found...die
#solution: reinstall SRTP
#configure: error: You requested SSL (requires OpenSSL) but not found...die
#solution: upgrade OpenSSL above
#documented
#configure: error: You requested SPEEX DSP but not found...die
#solution: install: speex-1.2beta3.tar.gz above
make && make install
#E: make[2]: *** [src/tls/libtinyNET_la-tnet_dtls.lo] Error 1
#E: make[2]: Leaving directory `/usr/src/doubango/tinyNET'
#E: make[1]: *** [all-recursive] Error 1
#E: make[1]: Leaving directory `/usr/src/doubango'
#E: make: *** [all] Error 2
#unsuccessful solution
cd /usr/src/
wget http://www.kostecky.cz/doubango/doubango.patch --no-check-certificate
#there is antispam: check content of file!
cd doubango
patch -p0 < ./../doubango.patch
#Error patch: **** Only garbage was found in the patch input.
#solution: check content of the patch
#E: patching file rce (read from tinyNET/test/test_ice.h)
#E: Hunk #1 FAILED at 58 (different line endings).
#E: 1 out of 1 hunk FAILED -- saving rejects to file rce.rej
#E: patching file rce (read from tinyNET/src/tnet_utils.c)
#E: Hunk #1 FAILED at 200.
#E: Hunk #2 FAILED at 215.
#E: 2 out of 2 hunks FAILED -- saving rejects to file rce.rej
#E: patching file rce (read from tinyNET/src/tinynet_config.h)
#E: Hunk #1 FAILED at 88.
#E: 1 out of 1 hunk FAILED -- saving rejects to file rce.rej
make && make install
#WITHOUT SUCCESS!
#tutorial continues by this commands
svn co http://webrtc2sip.googlecode.com/svn/trunk/ webrtc2sip
export PREFIX=/etc/webrtc2sip
cd webrtc2sip
./autogen.sh
./configure --prefix=$PREFIX
make && make install
#E: mp_object.h:23:23: fatal error: tsk_debug.h: No such file or directory
#E: make[1]: *** [webrtc2sip-mp_c2c.o] Error 1
#E: make[1]: Leaving directory `/usr/src/webrtc2sip'
#E: make: *** [all] Error 2
cp -f ./config.xml $PREFIX/sbin/config.xml
webrtc2sip --help
#Doubango ./configure final screen
**************************************************************************
* CONGRATULATIONS
**************************************************************************
Cross Compilation: no
Target OS: Linux
Host setup: x86_64-unknown-linux-gnu
Install prefix: /usr/local
Compiler: gcc
Build Type: doubango
Enable GPL: yes
Enable Non Free: yes
FFmpeg: yes
VP8 video codec: yes
OpenH264 video codec: no
OPUS audio codec: yes
ILBC audio codec: no
G.729 audio codec: no -> yes
GSM audio codec: yes
AMR audio codec: no -> yes
SPEEX audio codec: yes
G.722 audio codec: yes
G.711 audio codec: yes
YUV: no
JPEG: no
SPEEX DSP: yes
SSL: yes
DTLS-SRTP: yes
DTLS: yes
SRTP: yes
WebRTC: Enabled(no): AEC(no), NS(no)
Monotonic timers: yes
RESOLV: no
ALSA (audio): no
OSS (audio): yes
V4L2 (video): yes
DEBUG: no
DEBUG_LEVEL: error
Co s tím dále nevím... Nejvíce jsem se zdržel na kompilaci libtinyNET_la-tnet_dtls.lo, nicméně patchování mi nepomohlo a dále nevím, budu rád za případnou pomoc.
Žádné komentáře :
Okomentovat
Dotaz, připomínka, oprava?
(pokud máte problém s vložením příspěvku, vyzkoušejte to v prohlížeči Chrome)