setup.py 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. #!/usr/bin/env python
  2. import codecs
  3. import kscore
  4. import sys
  5. from setuptools import setup, find_packages
  6. AUTHOR = "liuyichen,xuyaming,ksc_online_sdk"
  7. AUTHOR_EMAIL = "ksc_sdk@kingsoft.com,xuyaming@kingsoft.com,ksc_online_sdk@kingsoft.com"
  8. KEYWORDS = "ksc-sdk-python"
  9. URL = "https://github.com/KscSDK/ksc-sdk-python"
  10. requires = ['jmespath>=0.7.1,<1.0.0',
  11. 'python-dateutil>=2.1,<3.0.0',
  12. 'docutils>=0.10',
  13. 'pyyaml>=5.3.1']
  14. # if sys.version_info.major != 3:
  15. # requires.append('pyyaml==3.13')
  16. # else:
  17. # requires.append('pyyaml>=3.13')
  18. if sys.version_info[:2] == (2, 6):
  19. # For python2.6 we have a few other dependencies.
  20. # First we need an ordered dictionary so we use the
  21. # 2.6 backport.
  22. requires.append('ordereddict==1.1')
  23. # Then we need simplejson. This is because we need
  24. # a json version that allows us to specify we want to
  25. # use an ordereddict instead of a normal dict for the
  26. # JSON objects. The 2.7 json module has this. For 2.6
  27. # we need simplejson.
  28. requires.append('simplejson==3.3.0')
  29. setup(
  30. name='ksc-sdk-python',
  31. version=kscore.__version__,
  32. description='Low-level, data-driven core of ksc.',
  33. long_description='A low-level interface to a growing number of KSC Web Services.',
  34. #long_description=open('README.rst', encoding='utf-8').read(),
  35. author=AUTHOR,
  36. url='https://github.com/KscSDK/ksc-sdk-python',
  37. author_email=AUTHOR_EMAIL,
  38. scripts=[],
  39. packages=find_packages(exclude=['tests*','examples']),
  40. package_data={'kscore': ['data/*.json', 'data/*/*.json'],
  41. 'kscore.vendored.requests': ['*.pem']},
  42. include_package_data=True,
  43. install_requires=requires,
  44. extras_require={
  45. ':python_version=="2.6"': [
  46. 'ordereddict==1.1',
  47. 'simplejson==3.3.0',
  48. ]
  49. },
  50. license="Apache License 2.0",
  51. classifiers=[
  52. 'Development Status :: 5 - Production/Stable',
  53. 'Intended Audience :: Developers',
  54. 'Intended Audience :: System Administrators',
  55. 'Natural Language :: English',
  56. 'License :: OSI Approved :: Apache Software License',
  57. 'Programming Language :: Python',
  58. 'Programming Language :: Python :: 2.6',
  59. 'Programming Language :: Python :: 2.7',
  60. 'Programming Language :: Python :: 3',
  61. 'Programming Language :: Python :: 3.3',
  62. 'Programming Language :: Python :: 3.4',
  63. 'Programming Language :: Python :: 3.5',
  64. 'Programming Language :: Python :: 3.6',
  65. 'Programming Language :: Python :: 3.7',
  66. 'Programming Language :: Python :: 3.8',
  67. ],
  68. )