vnpy/centos_setup.md
msincenselee 8e28264c71 [bug fix]
2020-03-24 13:27:04 +08:00

49 lines
1.3 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

下载 anaconda 3最新版必须支持3.7)
使用trade用户安装在 /home/trade/anaconda3
创建py37环境
conda create -name py37=python3.7
安装talib
wget http://prdownloads.sourceforge.net/ta-lib/ta-lib-0.4.0-src.tar.gz
tar xvf ta-lib-0.4.0-src.tar.gz
cd ta-lib
./configure --prefix=/usr
make
下面指令用用root权限运行会把编译结果放在/usr/local/lib下
sudo make install
pip install ta-lib
错误:
ImportError: libta_lib.so.0: cannot open shared object file: No such file or directory
解决:
sudo find / -name libta_lib.so.0
/home/ai/eco-ta/ta-lib/src/.libs/libta_lib.so.0
/usr/local/lib/libta_lib.so.0
vi /etc/profile
添加
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib
source /etc/profile
错误:
autogen.sh:行3: aclocal: 未找到命令
解决:
sudo yum -y install automake
错误:
configure.in:13: error: possibly undefined macro: AC_PROG_LIBTOOL
解决:
sudo yum install libtool
单独编译ctp接口
一般直接使用提供的vnctptd.so 和 vnctpmd.so 就可以了。
如果需要独立编译,按照以下指引:
【root】安装好gcc环境,