]> sjero.net Git - linphone/blob - README.zrtp
Use static lib for xml2lpc and lpc2xml
[linphone] / README.zrtp
1 ZRTP guide
2
3 == Downloads ==
4 - SRTP
5 http://sourceforge.net/projects/srtp/
6 or "apt-get source libsrtp0" on Debian
7
8 - ZRTP (libzrtpcpp-2.0)
9 http://www.gnutelephony.org/index.php/GNU_ZRTP
10
11
12 == Patch libzrtpcpp ==
13 Index: src/ZIDFile.cpp
14 ===================================================================
15 --- src/ZIDFile.cpp     (révision 754)
16 +++ src/ZIDFile.cpp     (copie de travail)
17 @@ -78,10 +78,11 @@
18  
19      // create save file name, rename and re-open
20      // if rename fails, just unlink old ZID file and create a brand new file
21 -    // just a little inconnvenience for the user, need to verify new SAS
22 +    // just a little inconvenience for the user, need to verify new SAS
23      std::string fn = std::string(name) + std::string(".save");
24      if (rename(name, fn.c_str()) < 0) {
25 -        unlink(name);
26 +       // unlink(name);
27          createZIDFile(name);
28          return;
29      }
30 Index: src/libzrtpcpp/ZrtpCallback.h
31 ===================================================================
32 --- src/libzrtpcpp/ZrtpCallback.h       (révision 754)
33 +++ src/libzrtpcpp/ZrtpCallback.h       (copie de travail)
34 @@ -27,7 +27,7 @@
35  
36  #include <string>
37  #include <stdint.h>
38 -#include <commoncpp/config.h>
39 +//#include <commoncpp/config.h>
40  #include <libzrtpcpp/ZrtpCodes.h>
41  
42  /**
43 Index: src/libzrtpcpp/ZIDRecord.h
44 ===================================================================
45 --- src/libzrtpcpp/ZIDRecord.h  (révision 754)
46 +++ src/libzrtpcpp/ZIDRecord.h  (copie de travail)
47 @@ -33,7 +33,7 @@
48  
49  #include <string.h>
50  #include <stdint.h>
51 -#include <commoncpp/config.h>
52 +//#include <commoncpp/config.h>
53  
54  #define IDENTIFIER_LEN  12
55  #define RS_LENGTH       32
56 Index: CMakeLists.txt
57 ===================================================================
58 --- CMakeLists.txt      (révision 754)
59 +++ CMakeLists.txt      (copie de travail)
60 @@ -124,11 +124,15 @@
61  if(CMAKE_COMPILER_IS_GNUCXX)
62    add_definitions(-Wno-long-long -Wno-char-subscripts)
63    add_definitions(-Wall -ansi -pedantic)
64 +  add_definitions(-DNEW_STDCPP)
65  endif()
66  
67  add_subdirectory(src)
68 -add_subdirectory(demo)
69  
70 +if (enable_ccrtp)
71 +       add_subdirectory(demo)
72 +endif()
73 +
74  if (NOT EXISTS ${CMAKE_CURRENT_BINARY_DIR}/package/)
75      MESSAGE(STATUS "package dir not found")
76      file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/package/)
77
78
79
80 == Create simlinks or move folders ==
81 submodules/external/srtp -> path_to_your_srtp_source
82 submodules/external/libzrtpcpp -> path_to_your_patched_zrtpcpp_source
83
84
85
86 == Compilation for Android ==
87 ndk-build BUILD_GPLV3_ZRTP=1  -j5
88
89
90 == Compilation for Desktop version ==
91 First ortp: ./autogen.sh && ./configure --enable-zrtp && make -j5 && sudo make install
92 Then mediastreamer2: ./autogen.sh && ./configure && make -j5 && sudo make install
93 Finally linphone: ./autogen.sh && ./configure --enable-external-ortp && make -j5 && sudo make install
94