Skip to content
Browse files
Merge pull request #2227 from apache/add_thrift_readme
Add Thrift compiler related issues in README
  • Loading branch information
jt2594838 committed Jan 12, 2021
2 parents d7b466c + 72ba8b9 commit c427797ffaf0abc9c025eec7c91bba300a9b5329
Showing 2 changed files with 25 additions and 0 deletions.
@@ -101,6 +101,21 @@ Here in the Quick Start, we give a brief introduction of using source code to in

## Build from source

Skip this paragraph if you are using Windows. As we use Thrift for our RPC module (communication and
protocol definition), we involve Thrift during the compilation, so Thrift compiler 0.13.0 (or
higher) is required to generate Thrift Java code. Thrift officially provides binary compiler for
Windows, but unfortunately, they do not provide that for Unix OSs. However, we compiled a Unix
compiler ourselves and put it onto GitHub, and with the help of a maven plugin, it will be
downloaded automatically during compilation. This compiler works fine with gcc8 or later, Ubuntu
MacOS, and CentOS, but previous versions and other OSs are not guaranteed. Should you find your gcc
version or OS does not support the precompiled compiler, please upgrade your gcc version or follow the
Thrift official instructions to compile the compiler yourself and rename it into `{project_root}\thrift\target\tools\thrift_0.12.0_0.13.0_linux.exe`.
If you have already installed a compatible Thrift compiler, you may add the following parameter
when running Maven: ` -Dthrift.exec.absolute.path=<YOUR LOCAL THRIFT BINARY FILE>`.
If you want to download the Thrift compiler from another position, you may add the following
parameter: `<THE REMOTE URL FOR DOWNLOADING> -Dthrift.exec.absolute.path=<THE DOWNLOADED BINARY FILE NAME>`. Or you may directly modify our root pom if you are skilled enough.
Here is the Thrift official site:

You can download the source code from:

@@ -99,6 +99,16 @@ IoTDB提供了三种安装方法,您可以参考以下建议,选择最适合

## 从源码构建

如果您使用Windows,请跳过此段。我们使用Thrift作为RPC模块来提供客户端-服务器间的通信和协议支持,因此在编译阶段我们需要使用Thrift 0.13.0
,借助一个Maven插件,在编译时可以自动将其下载。该预编译的Thrift编译器在gcc8,Ubuntu, CentOS, MacOS下可以工作,但是在更低的gcc
如果您已经安装了一个兼容的Thrift编译器,您可以在运行Maven时通过以下参数指定使用您的编译器:` -Dthrift.exec.absolute.path=<YOUR LOCAL THRIFT BINARY FILE>`
您也可以使用以下Maven参数来更换Thrift编译器的下载地址:`<THE REMOTE URL FOR DOWNLOADING> -Dthrift.exec.absolute.path=<THE DOWNLOADED BINARY FILE NAME>`

从 git 克隆源代码:


0 comments on commit c427797

Please sign in to comment.