Commit aadd9b0b authored by jehan's avatar jehan
Browse files

Merge branch 'master' of

parents 21c783a9 5de1f11f
Simon MORLAT (simon dot morlat at linphone dot org) wrotes:
- main graphical program (gnome)
- RTP library (oRTP)
- SIP user-agent library (osipua)
- audio library (mediastreamer), for codec and i/o handling.
- sipomatic, the automatic sip replier, which is often used for testing.
Main authors:
Florian Wintertein < f-win at gmx dot net > wrotes the console version of linphone (linphonec)
in console/ directory.
Belledonne Communications SARL team:
Simon Morlat, Jehan Monnier, Guillaume Beraudo
Aymeric Moizard (jack at atosc dot org) wrotes:
- the oSIP SIP transactionnal stack (not part of linphone)
- some piece of code of the osip distribution have been reused in osipua
- presence information support in osipua
- and contributes to some parts of osipua (digest authentification)
For more information about oSIP, see
Sharath Udupa is developing the media_api, a usefull library to manage audio and video streams
for basic calls as well as conference.
Florian Wintertein < f-win at gmx dot net > originaly wrotes the console version of linphone (linphonec)
in console/ directory.
Sandro Santilli < strk at keybit dot net > wrote enhancements in the
console interface (readline, new commands) and some bug fixes for
the core api.
Bryan Ogawa ( bko at cisco dot com ) sent a patch that made the linphone-0.7.1 release.
This patch fixed several issues in the SIP part while working with proxies.
Koichi KUNITAKE < kunitake at linux-ipv6 dot org > has contributed a patch bringing
full IPv6 support.
The Speex codec is a project from Jean Marc Valin. See for more
The GSM library was written by :
Jutta Degener and Carsten Bormann,Technische Universitaet Berlin.
The LPC10-1.5 library was written by:
Andy Fingerhut
Applied Research Laboratory <-- this line is optional if
Washington University, Campus Box 1045/Bryan 509 you have limited space
One Brookings Drive
Saint Louis, MO 63130-4899
See text files in gsmlib and lpc10-1.5 directories for further information.
G711 library has some code from the alsa-lib on
Icons by Pablo Marcelo Moia.
console interface (readline, new commands).
fr: Simon Morlat
en: Simon Morlat and Delphine Perreau
it: Alberto Zanoni <alberto.zanoni@-NO-SPAM-PLEASE!>
de: Jean-Jacques Sarton <>
es: Jesús Benítez <gnelson at inMail dot sk>
......@@ -48,16 +48,16 @@ SDK_EXCLUDED= \
GTK_FILELIST_PATH=$(shell cd $(top_srcdir) && pwd)/$(GTK_FILELIST)
ISS_SCRIPT_PATH=$(shell cd $(top_srcdir) && pwd)/$(ISS_SCRIPT)
#path to Inno Setup 5 compiler
ISCC=/c/Program\ Files/Inno\ Setup\ 5/ISCC.exe
EXTRA_DIST = config.rpath BUGS linphone.kdevelop \
......@@ -109,7 +109,11 @@ other-cherrypick:
cp $$file $(INSTALLDIR_WITH_PREFIX)/$$file ;\
fi \
cp /mingw/bin/libgcc_s*.dll $(INSTALLDIR_WITH_PREFIX)/bin/.
cp /mingw/bin/libgcc_s*.dll \
/mingw/bin/libstdc++-6.dll \
/mingw/bin/libintl-8.dll \
/mingw/bin/libiconv-2.dll \
linphone-3.4.0 -- February 7th, 2011
* implement multiple calls feature:
- call hold (with possibility to play a music file)
- call resume
- acceptance of 2nd call while putting the others on hold
- creation of another outgoing call while already in call
- blind call transfer
- attended call transfer
**CAUTION**: LinphoneCoreVTable has changed: pay attention to this when upgrading an old application to a newer liblinphone.
* improve bandwidth management (one b=AS line is used for audio+video)
* improvements in the echo limiter performance
* implement a echo calibration feature (see linphone_core_start_echo_calibration()).
* stun support bugfixes
* possibility to use two video windows, one for local preview, one for remote video (linphonec only)
* optimize by not re-creating streams when SDP is unchanged during a reinvite
* support for sending early media
* doxygen doc and javadoc improvements
* based on mediastreamer-2.7.0, please refer to mediastreamer NEWS for changes.
linphone-3.3.2 -- July 1st, 2010
* fix crash when setting firewall address in gtk interface
* fix crash while closing video window on windows
......@@ -5,16 +5,16 @@ This is Linphone, a free (GPL) video softphone based on the SIP protocol.
- you need at least:
- libosip2>=3.0.3
- libeXosip2>=3.0.3
- speex>=1.1.6
- libreadline
- speex>=1.2.0 (including libspeexdsp part)
- libreadline (optional: for convenient command line in linphonec)
+ gsm codec (gsm source package or libgsm-dev or gsm-devel) (optional)
+ if you want to gtk/glade interface:
- gtk>=2.16.0
- libglade>=2.2
+ if you want video support:
- SDL>=1.2.10
- libavcodec (ffmpeg) from a year 2007 or later cvs/svn
- libavcodec (ffmpeg)
- libswscale (part of ffmpeg too) for better scaling performance
- theora (optional)
with their corresponding -dev or -devel package if you don't use source packages.
......@@ -38,7 +38,7 @@ Here is a short description of the content of the source tree.
- coreapi/ is the central point of linphone, which handles relationship between sip signalisation and media
streaming. It contains an easy to use api to create a sip phone.
- gtk-glade/ is the directory that contains the gui frontend of linphone. It uses all libraries descibed above.
- gtk/ is the directory that contains the gui frontend of linphone. It uses all libraries descibed above.
- console/
* linphonec.c is the main file for the console version of linphone.
Software to install
* mingw32, using Automated windows installer (when launched, choose candidate to have lastest binaries)
* msys, using windows installer too.
run msys as Administrator (right click on the icon, and click 'run as administrator')
Download zip and unzip (download setup.exe and run) from
- add them to your path in msys terminal:
export PATH=$PATH:/c/Program\ Files/GnuWin32/bin
Download from mingw download page (, click download):
- MSYS automake-1.11
- MSYS autoconf-2.63
- MSYS libtool>=2.2.7
- MSYS libcrypt*-bin
- MSYS perl
- MSYS gettext-*bin* and gettext-*dev*
===> Uncompress all these packages in /
- from gcc-4.4 directory
- gcc-core*-bin
- gcc-core-*-dll
- gcc-c++*-bin
- gcc-c++*-dll
- gmp*-dll
- mpfr*-dll
- w32api*-dev
- mingwrt-dev and mingwrt-dll (mingw run time)
- gnu binutils 2.19
===> Uncompress all these packages in /mingw
note: lzma files can be uncompressed using tar --lzma -xvf <file>
* Download intltool (quicklink:
note: -dev package is not needed.)
uncompress in / with 'unzip' command.
* Download lastest gtk+bundle from , uncompress in /
* Download libglade and libglade-dev >=2.6.3 from gnome ftp:
uncompress in /
* Download ActiveState perl and run the installer with default options ( , developer tools)
Yes it is required despite MSYS perl is already installed.
* Download lastest linphone-deps from linphone downloads, misc directory:
uncompress in /
* Download and install Inno Setup Compiler in its default path (required only if you run 'make setup.exe').
Move out /lib/ : it confuses libtool
mv /lib/ /lib/
Move out in order to workaround a gcc-4.4.0 bug (or packaging bug):
mv /mingw/lib/gcc/mingw32/4.4.0/ /mingw/lib/gcc/mingw32/4.4.0/
Download lastest mingw-get-inst.exe from
Run mingw-get-inst.exe. Choose "download lastest catalogues".
In the feature list, select:
* C compiler
* C++ compiler
* Mingw developer toolkit
Let the installer fetch and install everything.
In mingw shell, run
mingw-get install msys-zip
mingw-get install msys-unzip
mingw-get install msys-wget
mkdir -p /opt/perl/bin
cp /bin/perl /opt/perl/bin/.
cd ~
#Download intltool
Download lastest linphone-deps-win32 zip from
using your browser.
Download lastest gtk+ win32 bundle from
Install all these three package in /:
cd /
unzip ~/
unzip <path to gtk bundle zip>
unzip <path to linphone-deps>
#Install GTK+ Outcrop theme, the one used by linphone for distribution.
cd /share/themes
tar -xvzf GTK2-Outcrop.tar.gz
#Remove the special stdint.h and inttypes.h included in linphone-deps: it is for MSVC only.
#Mingw will use the one in /mingw/include
rm /include/stdint.h /include/inttypes.h
#Remove libgcc specific libraries, only needed for MSVC:
rm /lib/libgcc.a /lib/libmingw32.a /lib/libmingwex.a
#Remove libintl from gtk, we don't need it and it conflicts with the one supplied by mingw.
rm /lib/libintl.dll.a
rm /include/intl.h
* Download and install Inno Setup Compiler (required only if you run 'make setup.exe'). Add it to your windows Path environment variable.
Get Linphone source code
......@@ -66,7 +62,7 @@ It is recommended that you create a directory somewhere with a path without any
Within msys-git bash, do
cd /c/sources
git clone git://
git clone git:// --recursive
......@@ -76,17 +72,6 @@ WARNING: During the build, windows might slow down suddenly. Using ctl+alt+del t
you might see a process 'LVpSRV.exe' or something like this that eats 90% of cpu.
Kill it. Don't know what it is, but once killed, windows runs normally.
The following variables must be exported:
#use ActiveState perl instead of mingw perl
export PERL="/c/Perl/bin/perl"
export INTLTOOL_PERL="/c/Perl/bin/perl"
#add gnuwin32 tools to your path:
export PATH=$PATH:/c/Program\ Files/Gnuwin32/bin
for convenience the '' script in linphone sources does this, so you can just source it:
. ./
#run after a git checkout or update
./configure --prefix=/opt/linphone --enable-shared --disable-static
......@@ -97,6 +82,7 @@ make install
make zip
#additionally you can make binary installer if you have Inno Setup 5 installed in its default path
make setup.exe
#now you're done, you have a fresh linphone windows installer in the current directory.
#build plugins
cd mediastreamer2/plugins/msx264
......@@ -20,6 +20,10 @@ if test -d /opt/local/share/aclocal ; then
ACLOCAL_ARGS="-I /opt/local/share/aclocal"
if test -d /share/aclocal ; then
ACLOCAL_ARGS="$ACLOCAL_ARGS -I /share/aclocal"
if test -f /opt/local/bin/intltoolize ; then
......@@ -46,13 +46,14 @@ LOCAL_SRC_FILES = \
sal_eXosip2_sdp.c \
offeranswer.c \
callbacks.c \
linphonecall.c \
-DLINPHONE_VERSION=\"Linphone-3.3.x\" \
......@@ -72,10 +73,11 @@ LOCAL_C_INCLUDES += \
LOCAL_LDLIBS += -llog -ldl
libmediastreamer2 \
libortp \
libspeex \
libeXosip2 \
libosip2 \
......@@ -85,9 +87,14 @@ LOCAL_STATIC_LIBRARIES += \
libavcodec \
libswscale \
libavcore \
libavutil \
libmsx264 \
ifeq ($(TARGET_ARCH_ABI),armeabi-v7a)
dnl Process this file with autoconf to produce a configure script.
......@@ -95,25 +95,19 @@ AC_SUBST(ALL_LINGUAS)
if test "$mingw_found" != "yes" ; then
dnl gettext macro does not work properly under mingw.
dnl gettext macro does not work properly under mingw. And we want to use the one provided by GTK.
if test "$mingwce_found" != "yes" ; then
AC_DEFINE(ENABLE_NLS,1,[Tells whether localisation is possible])
AC_DEFINE(HAVE_GETTEXT,1,[Tells wheter localisation is possible])
LIBS="$LIBS -L/usr/lib -lintl"
dnl gettext macro does not work properly under mingw.
AC_DEFINE(ENABLE_NLS,1,[Tells whether localisation is possible])
AC_DEFINE(HAVE_GETTEXT,1,[Tells wheter localisation is possible])
LIBS="$LIBS -lintl"
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE",[The name of the gettext package name])
dnl AC_CHECK_LIB(intl,libintl_gettext)
AC_CHECK_FUNCS([get_current_dir_name strndup stpcpy] )
......@@ -304,7 +298,9 @@ AC_ARG_ENABLE(x11,
if test "$video" = "true"; then
if test "$enable_x11" = "true"; then
AC_CHECK_LIB(X11,XUnmapWindow, X11_LIBS="-lX11")
AC_DEFINE(VIDEO_ENABLED,1,[defined if video support is available])
......@@ -23,7 +23,8 @@ linphonec_LDADD = $(top_builddir)/coreapi/ $(READLINE_LIBS) \
#special build of linphonec to detach from the windows console
......@@ -33,17 +34,6 @@ linphoned_LDADD=$(linphonec_LDADD)
sipomatic.c sipomatic.h
sipomatic_LDADD= $(INTLLIBS) \
$(top_builddir)/coreapi/ \
linphonecsh_SOURCES = shell.c
linphonecsh_CFLAGS = $(CONSOLE_FLAGS)
linphonecsh_LDADD = $(ORTP_LIBS)
......@@ -83,6 +83,7 @@ static int lpc_cmd_acodec(LinphoneCore *lc, char *args);
static int lpc_cmd_vcodec(LinphoneCore *lc, char *args);
static int lpc_cmd_codec(int type, LinphoneCore *lc, char *args);
static int lpc_cmd_echocancellation(LinphoneCore *lc, char *args);
static int lpc_cmd_echolimiter(LinphoneCore *lc, char *args);
static int lpc_cmd_pause(LinphoneCore *lc, char *args);
static int lpc_cmd_resume(LinphoneCore *lc, char *args);
static int lpc_cmd_mute_mic(LinphoneCore *lc, char *args);
......@@ -93,6 +94,7 @@ static int lpc_cmd_camera(LinphoneCore *lc, char *args);
static int lpc_cmd_video_window(LinphoneCore *lc, char *args);
static int lpc_cmd_preview_window(LinphoneCore *lc, char *args);
static int lpc_cmd_snapshot(LinphoneCore *lc, char *args);
static int lpc_cmd_vfureq(LinphoneCore *lc, char *arg);
static int lpc_cmd_states(LinphoneCore *lc, char *args);
static int lpc_cmd_identify(LinphoneCore *lc, char *args);
......@@ -269,6 +271,10 @@ static LPC_COMMAND advanced_commands[] = {
"'ec on [<delay>] [<tail>] [<framesize>]' : turn EC on with given delay, tail length and framesize\n"
"'ec off' : turn echo cancellation (EC) off\n"
"'ec show' : show EC status" },
{ "el", lpc_cmd_echolimiter, "Echo limiter",
"'el on turns on echo limiter (automatic half duplex, for cases where echo canceller cannot work)\n"
"'el off' : turn echo limiter off\n"
"'el show' : show echo limiter status" },
{ "nortp-on-audio-mute", lpc_cmd_rtp_no_xmit_on_audio_mute,
"Set the rtp_no_xmit_on_audio_mute configuration parameter",
" If set to 1 then rtp transmission will be muted when\n"
......@@ -293,6 +299,7 @@ static LPC_COMMAND advanced_commands[] = {
{ "snapshot", lpc_cmd_snapshot, "Take a snapshot of currently received video stream",
"'snapshot <file path>': take a snapshot and records it in jpeg format into the supplied path\n"
{ "vfureq", lpc_cmd_vfureq, "Request the other side to send VFU for the current call"},
{ "states", lpc_cmd_states, "Show internal states of liblinphone, registrations and calls, according to linphonecore.h definitions",
"'states global': shows global state of liblinphone \n"
......@@ -1948,10 +1955,18 @@ static int lpc_cmd_status(LinphoneCore *lc, char *args)
LinphoneCallState call_state=LinphoneCallIdle;
if (call) call_state=linphone_call_get_state(call);
case LinphoneCallOutgoingInit:
linphonec_out("hook=outgoing_init sip:%s\n",linphonec_get_callee());
case LinphoneCallOutgoingProgress:
linphonec_out("hook=dialing sip:%s\n",linphonec_get_callee());
case LinphoneCallOutgoingRinging:
linphonec_out("hook=ringing sip:%s\n",linphonec_get_callee());
case LinphoneCallPaused:
linphonec_out("hook=paused sip:%s\n",linphonec_get_callee());
case LinphoneCallIdle:
......@@ -1964,8 +1979,8 @@ static int lpc_cmd_status(LinphoneCore *lc, char *args)
linphone_core_is_mic_muted (lc) ? "yes" : "no",
linphone_core_is_rtp_muted(lc) ? "yes" : "no");
linphonec_out("hook=answered duration=%i\n" ,
linphonec_out("hook=answered duration=%i %s\n" ,
linphone_core_get_current_call_duration(lc), linphonec_get_caller());
case LinphoneCallIncomingReceived:
......@@ -2202,6 +2217,18 @@ static int lpc_cmd_echocancellation(LinphoneCore *lc, char *args){
return 1;
static int lpc_cmd_echolimiter(LinphoneCore *lc, char *args){
if (args){
if (strcmp(args,"on")==0){
linphone_core_enable_echo_limiter (lc,TRUE);
}else if (strcmp(args,"off")==0){
linphone_core_enable_echo_limiter (lc,FALSE);
linphonec_out("Echo limiter is now %s.\n",linphone_core_echo_limiter_enabled (lc) ? "on":"off");
return 1;
static int lpc_cmd_mute_mic(LinphoneCore *lc, char *args)
linphone_core_mute_mic(lc, 1);
......@@ -2408,12 +2435,21 @@ static int lpc_cmd_snapshot(LinphoneCore *lc, char *args){
if (!args) return 0;
if (call!=NULL){
linphone_call_take_video_snapshot (call,args);
linphonec_out("Taking video snaphot in file %s\n", args);
linphonec_out("Taking video snapshot in file %s\n", args);
}else linphonec_out("There is no active call.\n");
return 1;
static int lpc_cmd_vfureq(LinphoneCore *lc, char *arg){
LinphoneCall *call;
if (call!=NULL){
linphonec_out("VFU request sent\n");
}else linphonec_out("There is no active call.\n");
return 1;
static int lpc_cmd_identify(LinphoneCore *lc, char *args){
......@@ -34,6 +34,7 @@
#endif /*_WIN32_WCE*/
#include <limits.h>
#include <ctype.h>
#include <stdlib.h>
#include <linphonecore.h>
......@@ -79,7 +80,6 @@
#ifdef HAVE_X11_XLIB_H
#include <X11/Xlib.h>
#include <SDL/SDL_syswm.h>
......@@ -162,6 +162,7 @@ static char *logfile_name = NULL;
static char configfile_name[PATH_MAX];
static const char *factory_configfile_name=NULL;
static char *sipAddr = NULL; /* for autocall */
static int window_id = 0; /* 0=standalone window, or window id for embedding video */
#if !defined(_WIN32_WCE)
static ortp_pipe_t client_sock=ORTP_PIPE_INVALID;
#endif /*_WIN32_WCE*/
......@@ -391,7 +392,7 @@ static void
linphonec_text_received(LinphoneCore *lc, LinphoneChatRoom *cr,
const LinphoneAddress *from, const char *msg)
printf("%s: %s\n", linphone_address_as_string(from), msg);
linphonec_out("Message received from %s: %s\n", linphone_address_as_string(from), msg);
// TODO: provide mechanism for answering.. ('say' command?)
......@@ -716,6 +717,12 @@ linphonec_init(int argc, char **argv)
linphonec=linphone_core_new (&linphonec_vtable, configfile_name, factory_configfile_name, NULL);
if (display_enabled && window_id != 0)
printf ("Setting window_id: 0x%x\n", window_id);
if (!(vcap_enabled || display_enabled)) printf("Warning: video is disabled in linphonec, use -V or -C or -D to enable.\n");
......@@ -878,6 +885,7 @@ usage: linphonec [-c file] [-s sipaddr] [-a] [-V] [-d level ] [-l logfile]\n\
-C enable video capture only (disabled by default)\n\
-D enable video display only (disabled by default)\n\
-S show general state messages (disabled by default)\n\
--wid windowid force embedding of video window into provided windowid (disabled by default)\n\
-v or --version display version and exits.\n");
......@@ -1226,6 +1234,14 @@ linphonec_parse_cmdline(int argc, char **argv)
else if (strncmp ("--wid", argv[arg_num], 5) == 0)
if (arg_num < argc) {
char *tmp;
window_id = strtol( argv[arg_num], &tmp, 0 );
else if (old_arg_num == arg_num)
fprintf (stderr, "ERROR: bad arguments\n");
......@@ -66,7 +66,7 @@ void sipomatic_process_event(Sipomatic *obj,eXosip_event_t *ev)
void endoffile_cb(void *ud, unsigned int ev,void * arg){
void endoffile_cb(void *ud, MSFilter *f, unsigned int ev,void * arg){
......@@ -35,7 +35,8 @@ liblinphone_la_SOURCES=\
linphonecall.c \
sipsetup.c sipsetup.h \
siplogin.c \
lsd.c linphonecore_utils.h
lsd.c linphonecore_utils.h \
liblinphone_la_LDFLAGS= -version-info $(LIBLINPHONE_SO_VERSION) -no-undefined
......@@ -49,7 +50,7 @@ if BUILD_WIN32
noinst_PROGRAMS=test_lsd test_ecc
......@@ -57,6 +58,14 @@ \