lbry-rocksdb/setup.py

50 lines
1.3 KiB
Python
Raw Normal View History

2020-09-03 08:54:08 +02:00
import platform, sys
from setuptools import setup
from setuptools import find_packages
from setuptools import Extension
2014-01-13 19:52:22 +01:00
2018-01-24 16:50:59 +01:00
extra_compile_args = [
'-std=c++11',
'-O3',
'-Wall',
'-Wextra',
'-Wconversion',
'-fno-strict-aliasing',
'-fno-rtti',
2018-01-24 16:50:59 +01:00
]
if platform.system() == 'Darwin':
extra_compile_args += ['-mmacosx-version-min=10.7', '-stdlib=libc++']
2020-09-03 08:54:08 +02:00
if sys.version_info < (3 , 0):
raise Exception("pyRocksDB require Python 3.x")
2014-01-13 19:52:22 +01:00
setup(
2017-03-23 15:13:45 +01:00
name="python-rocksdb",
2019-02-01 15:02:14 +01:00
version='0.7.0',
2014-02-02 17:40:55 +01:00
description="Python bindings for RocksDB",
keywords='rocksdb',
2017-03-23 15:13:45 +01:00
author='Ming Hsuan Tu',
2018-01-25 16:27:57 +01:00
author_email="qrnnis2623891@gmail.com",
2017-04-23 13:33:42 +02:00
url="https://github.com/twmht/python-rocksdb",
2014-02-02 17:40:55 +01:00
license='BSD License',
setup_requires=['setuptools>=25', 'Cython>=0.20'],
install_requires=['setuptools>=25'],
2014-01-13 19:52:22 +01:00
package_dir={'rocksdb': 'rocksdb'},
packages=find_packages('.'),
ext_modules=[Extension(
'rocksdb._rocksdb',
['rocksdb/_rocksdb.pyx'],
extra_compile_args=extra_compile_args,
language='c++',
libraries=['rocksdb', 'snappy', 'bz2', 'z', 'lz4'],
)],
extras_require={
"doc": ['sphinx_rtd_theme', 'sphinx'],
"test": ['pytest'],
},
include_package_data=True,
zip_safe=False,
2014-01-13 19:52:22 +01:00
)