Installing "ring.cx SIP Client" on Raspberry PI

Situation

I would like to receive terminal (headless) SIP calls working on my Raspberry Pi, and I already tried this with linphone:

RaspberryPI: Make outgoing SIP calls using linphonec or an alternative SIP cell phone

Since I was stuck there right now, I wanted to try another option that was SFLPhone . They pointed me to the ring project, which offers the dring daemon, which allows you to make SIP calls using the scripting interface:

Indeed, the daemon can work autonomously and be controlled using the DBus API.

Please note that the project has been renamed the "Ring" (version packed up to 2.x). Experimental packages are available at http://ring.cx/en/documentation/linux-installation The main feature of the 2.x ring is an optional DHT account type that allows you to make calls without any SIP server. There are many other improvements such as ICE support, UPnP support, stability improvements, etc. (note that the clients are chatting (GTK3, Qt5), and there is a new OS X client, they are not yet full-fledged and in heavy development.)

New demon dring source Git repo URI: https://gerrit-ring.savoirfairelinux.com/ring . The DBus API is basically the same as before. In the tools/dringctrl you will find an example python client that we use for testing (uses python3-dbus ).

We are ready to fix any errors that you may find, here is the bugtracker daemon: https://projects.savoirfairelinux.com/projects/ring-daemon/issues Also see https://projects.savoirfairelinux.com/projects/ring/wiki for build team, etc.

Regards and good luck for your embedded project, AB

Dependency Compilation

I tried to compile the dependencies for the project, as indicated in README :

 git clone https://gerrit-ring.savoirfairelinux.com/ring cd ring 

Compile Dependencies First

 cd ../contrib/ rm -fr native/ && mkdir native cd native ../bootstrap make 

I got this error:

 libvpx.webm-4640a0c4804b/third_party/googletest/src/include/gtest/gtest.h mv libvpx-4640a0c4804b49f1870d5a2d17df0c7d0a77af2f libvpx && touch libvpx cd libvpx && CROSS= ./configure --target=armv7-linux-gcc \ --as=yasm --disable-docs --disable-examples --disable-unit-tests --disable-install-bins --disable-install-docs --enable-realtime-only --enable-error-concealment --disable-runtime-cpu-detect --disable-webm-io --enable-pic --prefix=/home/pi/ring/contrib/arm-linux-gnueabihf disabling docs disabling examples disabling unit_tests disabling install_bins disabling install_docs enabling realtime_only enabling error_concealment disabling runtime_cpu_detect disabling webm_io enabling pic Configuring selected codecs enabling vp8_encoder enabling vp8_decoder enabling vp9_encoder enabling vp9_decoder Configuring for target 'armv7-linux-gcc' enabling armv7 enabling neon enabling neon_asm enabling media Unable to invoke compiler: arm-none-linux-gnueabi-gcc -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 Configuration failed. This could reflect a misconfiguration of your toolchains, improper options selected, or another problem. If you don't see any useful error messages above, the next step is to look at the configure error log file (config.log) to determine what configure was trying to do when it died. ../../contrib/src/vpx/rules.mak:105: recipe for target '.vpx' failed make: *** [.vpx] Error 1 

Ring compilation

Despite compiling the dependencies, I tried to compile the ring:

 git clone https://gerrit-ring.savoirfairelinux.com/ring cd ring ./autogen.sh ./configure make make install 

This caused the following error:

 checking for PJPROJECT... no configure: error: Missing pjproject files pi@phone ~/ring $ make make: *** No targets specified and no makefile found. Stop. pi@phone ~/ring $ make install make: *** No rule to make target 'install'. Stop. 

So, I'm currently stuck, and I'm afraid that I will not be able to go beyond the current state of my project (๐ŸŽฅ):

the-phone

Edit : now without video codecs (like those suggested by aberaud), I ran into the following error:

 /bin/bash ../libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H -I. -I.. -I../include/opendht -I/home/pi/sip-desaster/ring/contrib/arm-linux-gnueabihf/include -fPIC -I/home/pi/sip-desaster/ring/contrib/arm-linux-gnueabihf/include -g -fPIC -O3 -std=c++0x -I/home/pi/sip-desaster/ring/contrib/arm-linux-gnueabihf/include -g -fPIC -O3 -std=c++0x -c -o libopendht_la-dht.lo `test -f 'dht.cpp' || echo './'`dht.cpp libtool: compile: g++ -DHAVE_CONFIG_H -I. -I.. -I../include/opendht -I/home/pi/sip-desaster/ring/contrib/arm-linux-gnueabihf/include -fPIC -I/home/pi/sip-desaster/ring/contrib/arm-linux-gnueabihf/include -g -fPIC -O3 -std=c++0x -I/home/pi/sip-desaster/ring/contrib/arm-linux-gnueabihf/include -g -fPIC -O3 -std=c++0x -c dht.cpp -fPIC -DPIC -o libopendht_la-dht.o In file included from ../include/opendht/dht.h:29:0, from dht.cpp:27: ../include/opendht/infohash.h:58:22: error: expected initializer before ':' token dht.cpp:3105:1: error: expected '}' at end of input Makefile:386: recipe for target 'libopendht_la-dht.lo' failed make[2]: *** [libopendht_la-dht.lo] Error 1 make[2]: Leaving directory '/home/pi/sip-desaster/ring/contrib/native/opendht/src' Makefile:395: recipe for target 'install-recursive' failed make[1]: *** [install-recursive] Error 1 make[1]: Leaving directory '/home/pi/sip-desaster/ring/contrib/native/opendht' ../../contrib/src/opendht/rules.mak:28: recipe for target '.opendht' failed make: *** [.opendht] Error 2 
+4
source share
3 answers

Contrib

Part of the โ€œcontribโ€ assembly of the Ring assembly is related to building dependencies that are not available on the target system, mainly used to create complete work packages during cross-compilation or for systems without proper dependency management (basically all OSs except Linux distributions).

When in the contrib/native directory, you can run make list to see a list of packages to create. Since you are doing cross-compilation, you will need to build almost everything.

If you somehow mess up the Contrib assembly, you can safely remove the contrib/native and contrib/{target_tuple} (if any) and start over.

libvpx

The libvpx library is used by libav to provide vp8 and vp9 video codecs. This is not a complex dependency, and since your project does not use video, you can safely disable it. We also encountered problems when cross compiling vpx.

In line contrib/src/libav/rules.mak line 70, DEPS_libav defines the list of dependencies for libav. You can remove vpx , x264 and $(DEPS_vpx) from the list since you are not using video. You can also add speex and opus audio codecs to the list (they should be on the list but not listed, see this patch for an example).

After clearing the contributor as described above and vpx , when you run make list , vpx and x264 should not appear in the "Ready packages" list. Then try creating a contributor by doing make .

If after that you encounter the same problem for other packages, you may have some kind of problem with cross-compilation assembly (then I would need more logs / details).

In extreme cases, compiling on Pi itself (with Raspbian) is terribly slow, but has the advantage of using local distribution dependencies and remove cross-compilation issues.

Good luck.

+2
source

I provide my own answer, which should document my steps, which I hope will lead me to the desired end result:

Download sources

 git clone https://gerrit-ring.savoirfairelinux.com/ring cd ring 

Create a contrib section

According to @aberaud's notes, I can update contrib/src/libav/rules.mak and remove any video related dependencies (remember I'm headless):

So, I changed the shape of the line 70

 DEPS_libav = zlib x264 vpx $(DEPS_vpx) 

to

 DEPS_libav = zlib opus speex 

Now create a contrib section.

 cd ../contrib/ rm -fr native/ && mkdir native cd native ../bootstrap make 
+1
source

I used the same error trying to compile a tab.

The version of Raspbian I used has an old version of the gcc compiler version 4.6. After I upgraded to 4.8, it compiled instantly. Well, as instantly, whatever compiles on Pi.

0
source

Source: https://habr.com/ru/post/984660/


All Articles