Step by Step about How to Build libjingle 0.4

1. Download and Install Visual C++ 2010 Express
http://www.microsoft.com/express/Downloads/#2010-Visual-CPP

2. Download and install binary package for Expat
http://sourceforge.net/projects/expat/files/expat_win32/
Currently the latest version is 2.0.1, which is my selection.

After installed, remember the below two directories:
Header file diretory: C:\Program Files (x86)\Expat 2.0.1\Source\lib
Lib file directory: C:\Program Files (x86)\Expat 2.0.1\Bin

3. Download the libjingle 0.4 zip and unzip it

http://libjingle.googlecode.com/files/libjingle-0.4.0.zip

4. Open the solution with Visual C++ 2010 Express
Open Visual C++ 2010 Express, click File->Open->Project/Solution, select talk/libjincle.sln, it will prompt solution conversion, continue. Now you may see there are three projects in the solution.


5. Configure the Expat directories for the solution
Right click "libjingle" project in the Solution Explorer, select Properties, and config the VC++ Diretories as the below:
Include Directories: C:\Program Files (x86)\Expat 2.0.1\Source\lib
Library Directories: C:\Program Files (x86)\Expat 2.0.1\Bin


6. Build the libjingle project

Right click "libjingle" project in the Solution Explorer, select Build. The build will start.
After build finished, you will find build failure with the below error information:
gipslitemediaengine.h(33): fatal error C1083: Cannot open include file: 'talk/third_party/gips/Interface/GipsVoiceEngineLite.h': No such file or directory
1>  gipslitemediaengine.cc


Don't worry. It is because on Windows the project depend on GIPS voice engine. Since we don't care the voice call now, so select all files on Source Files->session->phone, right click and select Exclude From Project. Build again. This time you will make build successfully.
And you may find the generated talk\Debug\libjingle.lib.

7. Build pcp project.

Configure the he Expat directories for this project as step 5. You will make build successfully. And you may find the generated talk\Debug\pcp.exe.

8. Test receiving file.
Run the below command:
pcp

Then send a file to this gmail account from Google Talk client with another account.


9. Test sending file.
Run the below command:
pcp 01.jpg [email protected]

Then accept the file from Google Talk client with the recepient account.


At last,
You may try the attached binary pcp.exe for the test.
And in fact, for Expat XML Parser, you don't need install it, only expat.h/expat_external.h and libexpatMT.lib are needed, which I have attached.

猜你喜欢

转载自mysuperbaby.iteye.com/blog/904758