vnpy/setup.py

54 lines
1.8 KiB
Python
Raw Normal View History

2019-02-19 02:39:23 +00:00
import platform
2019-02-18 09:40:15 +00:00
from setuptools import Extension, find_packages, setup
2019-02-19 02:39:23 +00:00
if platform.uname().system == "Windows":
compiler_flags = []
else:
compiler_flags = ['-std=c++11', '-Wno-delete-incomplete']
2019-02-18 09:40:15 +00:00
vnctpmd = Extension('vnpy.api.ctp.vnctpmd',
[
"vnpy/api/ctp/vnctp/vnctpmd/vnctpmd.cpp",
],
include_dirs=["vnpy/api/ctp/include", "vnpy/api/ctp/vnctp", ],
define_macros=[],
undef_macros=[],
library_dirs=["vnpy/api/ctp/libs"],
libraries=["thostmduserapi", "thosttraderapi", ],
# runtime_library_dirs=["vnpy/api/ctp/libs", ],
2019-02-19 02:39:23 +00:00
extra_compile_args=compiler_flags,
2019-02-18 09:40:15 +00:00
extra_link_args=[],
depends=[],
language="cpp",
)
vnctptd = Extension('vnpy.api.ctp.vnctptd',
[
"vnpy/api/ctp/vnctp/vnctptd/vnctptd.cpp",
],
include_dirs=["vnpy/api/ctp/include", "vnpy/api/ctp/vnctp", ],
define_macros=[],
undef_macros=[],
library_dirs=["vnpy/api/ctp/libs"],
libraries=["thostmduserapi", "thosttraderapi", ],
# runtime_library_dirs=["vnpy/api/ctp/libs", ],
2019-02-19 02:39:23 +00:00
extra_compile_args=compiler_flags,
2019-02-18 09:40:15 +00:00
extra_link_args=[],
depends=[],
language="cpp",
)
2019-02-19 02:39:23 +00:00
pkgs = find_packages()
s = setup(
2019-02-18 09:40:15 +00:00
name="vnpy",
version="2.0.dev0",
2019-02-19 02:39:23 +00:00
include_package_data=True,
packages=pkgs,
package_data={'': [
'*.json', '*.md', '*.ico',
'*.dll', '*.so',
]},
2019-02-18 09:40:15 +00:00
ext_modules=[vnctptd, vnctpmd],
)