Skip to content

Commit

Permalink
Merge pull request #8 from Edanflame/readme
Browse files Browse the repository at this point in the history
更新文档并添加macox依赖安装
  • Loading branch information
vnpy committed Aug 11, 2022
2 parents 1306752 + 1bbba68 commit d73c689
Showing 1 changed file with 29 additions and 5 deletions.
34 changes: 29 additions & 5 deletions README.md
@@ -1,22 +1,46 @@
# vn.py框架的LevelDB数据库接口
# VeighNa框架的LevelDB数据库接口

<p align="center">
<img src ="https://vnpy.oss-cn-shanghai.aliyuncs.com/vnpy-logo.png"/>
</p>

<p align="center">
<img src ="https://img.shields.io/badge/version-1.0.2-blueviolet.svg"/>
<img src ="https://img.shields.io/badge/platform-windows-yellow.svg"/>
<img src ="https://img.shields.io/badge/python-3.7-blue.svg" />
<img src ="https://img.shields.io/badge/platform-windows|linux|macox-yellow.svg"/>
<img src ="https://img.shields.io/badge/python-3.7|3.8|3.9|3.10-blue.svg" />
</p>

## 说明

基于plyvel-win32/plyvel开发的LevelDB数据库接口(不支持Mac系统)。
基于plyvel开发的LevelDB数据库接口。

对于不同操作系统需要安装不通版本的plyvel。对于linux与windows会自动安装适配的plyvel与plyvel-win32。

对于macox操作系统,需要手动下载源码进行安装,并在安装前将源码setup.py中

```python
if platform.system() == 'Darwin':
extra_compile_args += ['-stdlib=libc++']
```

修改为

```python
if platform.system() == 'Darwin':
extra_compile_args = ['-Wall', '-g', '-x', 'c++', '-std=c++11', '-fno-rtti']
```

再运行

```bash
python -m pip install .
```

进行手动安装。方法参考自[https://github.com/wbolster/plyvel/issues/114]

## 使用

在vn.py中使用MongoDB时,需要在全局配置中填写以下字段信息:
在VeighNa中使用LevelDB时,需要在全局配置中填写以下字段信息:

|名称|含义|必填|举例|
|---------|----|---|---|
Expand Down

0 comments on commit d73c689

Please sign in to comment.