[libnice] what affects the calculation of the number of candidates

tom chen chentom60 at hotmail.com
Wed Sep 30 21:43:52 PDT 2015


Hello,

The way of compilation significantly affects the number of gathered candidates. The first example is using the auto generated Makefile to compile libnice-0.1.13/examples/simple-example.c and generates 18 candidates on my PC, but the 2nd method, as mentioned in simple-example.c, just generates 3 candidates. Any idea what compilation flags are also needed as I must use the 2nd method to manually compile my applications?

1.       1. Compile using Makefile

tao at ubuntu:~/workspace/libnice-0.1.13/examples$ make simple-example

  CC       simple-example.o

  CCLD     simple-example

tao at ubuntu:~/workspace/libnice-0.1.13/examples$ ./simple-example 0 stunserver.org

Copy this line to remote client:

  aYjQ jmn6uO+LVvafYYAiIbZhX5 1,2013266431,fe80::20c:29ff:fe34:d0c8,40281,host 2,1019216383,fe80::20c:29ff:fe34:d0c8,0,host 3,1015022079,fe80::20c:29ff:fe34:d0c8,36577,host 4,2013266431,fe80::20c:29ff:fe34:d0be,56140,host 5,1019216383,fe80::20c:29ff:fe34:d0be,0,host 6,1015022079,fe80::20c:29ff:fe34:d0be,37034,host 7,2013266431,fe80::20c:29ff:fe34:d0b4,49289,host 8,1019216383,fe80::20c:29ff:fe34:d0b4,0,host 9,1015022079,fe80::20c:29ff:fe34:d0b4,43111,host 10,2013266431,192.168.0.60,57450,host 11,1019216383,192.168.0.60,0,host 12,1015022079,192.168.0.60,49752,host 13,2013266431,172.16.1.129,48506,host 14,1019216383,172.16.1.129,0,host 15,1015022079,172.16.1.129,59754,host 16,2013266431,10.113.54.60,43208,host 17,1019216383,10.113.54.60,0,host 18,1015022079,10.113.54.60,50996,host

Enter remote data (single line, no wrapping):

2.       2. Compile manually using gcc

tao at ubuntu:~/workspace/libnice-0.1.13/examples$ gcc -o simple-example simple-example.c `pkg-config --cflags --libs nice`

tao at ubuntu:~/workspace/libnice-0.1.13/examples$ ./simple-example 0 stunserver.org

Copy this line to remote client:

  HWQy FNchHCZ8oJYNcorQg8M0pU 1,2013266431,192.168.0.60,33215,host 2,2013266431,172.16.1.129,56681,host 3,2013266431,10.113.54.60,56804,host

Enter remote data (single line, no wrapping):


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/nice/attachments/20150930/8990865c/attachment.html>


More information about the nice mailing list