Telegram之tdesktop源码编译

    编译第三方开源项目代码实际上最坑爹的,因为开源,写的帮助说明简单的不能再简单了,许多细节都是没有的。

    最近因为公司需要研究mtproto,所以需要编译tdesktop,由于本人天资愚钝,花了两个星期才搞定,为了后来者可以少一些坑,将一些注意事项记录下来。

    第一步,安装第三方库

Download ActivePerl installer from https://www.activestate.com/activeperl/downloads and install to BuildPath\ThirdParty\Perl
Download NASM installer from http://www.nasm.us and install to BuildPath\ThirdParty\NASM
Download Yasm executable from http://yasm.tortall.net/Download.html, rename to yasm.exe and put to BuildPath\ThirdParty\yasm
Download MSYS2 installer from http://www.msys2.org/ and install to BuildPath\ThirdParty\msys64
Download jom archive from http://download.qt.io/official_releases/jom/jom.zip and unpack to BuildPath\ThirdParty\jom
Download Python 2.7 installer from https://www.python.org/downloads/ and install to BuildPath\ThirdParty\Python27
Download CMake installer from https://cmake.org/download/ and install to BuildPath\ThirdParty\cmake
Download Ninja executable from https://github.com/ninja-build/ninja/releases/download/v1.7.2/ninja-win.zip and unpack to BuildPath\ThirdParty\Ninja
Open x86 Native Tools Command Prompt for VS 2017.bat, go to BuildPath and run

cd ThirdParty
git clone https://chromium.googlesource.com/external/gyp
cd gyp
git checkout a478c1ab51
cd ..\..
  

注意点①:安装python时需要勾选将python添加到环境变量path中

你可能感兴趣的:(Telegram,源码编译,c++)