Craig Citro | 751b7fb | 2014-09-23 11:20:38 -0700 | [diff] [blame] | 1 | # Copyright 2014 Google Inc. All Rights Reserved. |
Tom Miller | 7c95d81 | 2010-10-11 11:50:52 -0700 | [diff] [blame] | 2 | # |
| 3 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | # you may not use this file except in compliance with the License. |
| 5 | # You may obtain a copy of the License at |
| 6 | # |
| 7 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | # |
| 9 | # Unless required by applicable law or agreed to in writing, software |
| 10 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | # See the License for the specific language governing permissions and |
| 13 | # limitations under the License. |
Joe Gregorio | 48d361f | 2010-08-18 13:19:21 -0400 | [diff] [blame] | 14 | |
Tom Miller | 7c95d81 | 2010-10-11 11:50:52 -0700 | [diff] [blame] | 15 | """Setup script for Google API Python client. |
| 16 | |
| 17 | Also installs included versions of third party libraries, if those libraries |
| 18 | are not already installed. |
| 19 | """ |
Craig Citro | a540cf7 | 2014-08-18 22:50:58 -0700 | [diff] [blame] | 20 | from __future__ import print_function |
| 21 | |
| 22 | import sys |
| 23 | |
Bu Sun Kim | 8325d24 | 2020-12-09 12:04:05 -0700 | [diff] [blame] | 24 | if sys.version_info < (3, 6): |
| 25 | print("google-api-python-client requires python3 version >= 3.6.", file=sys.stderr) |
Bu Sun Kim | 66bb32c | 2019-10-30 10:11:58 -0700 | [diff] [blame] | 26 | sys.exit(1) |
Craig Citro | a540cf7 | 2014-08-18 22:50:58 -0700 | [diff] [blame] | 27 | |
Bu Sun Kim | f706cfd | 2020-04-20 14:05:05 -0700 | [diff] [blame] | 28 | import io |
| 29 | import os |
Anthonios Partheniou | 430449d | 2021-04-22 14:46:04 -0400 | [diff] [blame] | 30 | from setuptools import setup |
Joe Gregorio | 01b9270 | 2011-03-23 21:44:42 -0400 | [diff] [blame] | 31 | |
Bu Sun Kim | 66bb32c | 2019-10-30 10:11:58 -0700 | [diff] [blame] | 32 | packages = ["apiclient", "googleapiclient", "googleapiclient/discovery_cache"] |
Joe Gregorio | 5cdaa51 | 2011-03-28 16:41:55 -0400 | [diff] [blame] | 33 | |
Joe Gregorio | d667c9d | 2011-10-17 13:25:24 -0400 | [diff] [blame] | 34 | install_requires = [ |
Thomas Chopitea | c00f70d | 2020-09-29 02:14:53 +0200 | [diff] [blame] | 35 | "httplib2>=0.15.0,<1dev", |
Bu Sun Kim | 96d2bb0 | 2021-07-20 04:14:29 -0600 | [diff] [blame] | 36 | # NOTE: Maintainers, please do not require google-auth>=2.x.x |
| 37 | # Until this issue is closed |
| 38 | # https://github.com/googleapis/google-cloud-python/issues/10566 |
| 39 | "google-auth>=1.16.0,<3.0.0dev", |
Bu Sun Kim | a9583f7 | 2021-03-15 09:12:02 -0600 | [diff] [blame] | 40 | "google-auth-httplib2>=0.1.0", |
Bu Sun Kim | 96d2bb0 | 2021-07-20 04:14:29 -0600 | [diff] [blame] | 41 | # NOTE: Maintainers, please do not require google-api-core>=2.x.x |
| 42 | # Until this issue is closed |
| 43 | # https://github.com/googleapis/google-cloud-python/issues/10566 |
| 44 | "google-api-core>=1.21.0,<3.0.0dev", |
Bu Sun Kim | 66bb32c | 2019-10-30 10:11:58 -0700 | [diff] [blame] | 45 | "uritemplate>=3.0.0,<4dev", |
John Asmuth | 864311d | 2014-04-24 15:46:08 -0400 | [diff] [blame] | 46 | ] |
Joe Gregorio | 6429bf6 | 2011-03-01 22:53:21 -0800 | [diff] [blame] | 47 | |
Bu Sun Kim | f706cfd | 2020-04-20 14:05:05 -0700 | [diff] [blame] | 48 | package_root = os.path.abspath(os.path.dirname(__file__)) |
Tom Miller | 7c95d81 | 2010-10-11 11:50:52 -0700 | [diff] [blame] | 49 | |
Bu Sun Kim | f706cfd | 2020-04-20 14:05:05 -0700 | [diff] [blame] | 50 | readme_filename = os.path.join(package_root, "README.md") |
| 51 | with io.open(readme_filename, encoding="utf-8") as readme_file: |
| 52 | readme = readme_file.read() |
Bu Sun Kim | 66bb32c | 2019-10-30 10:11:58 -0700 | [diff] [blame] | 53 | |
release-please[bot] | c567b47 | 2021-07-27 10:36:15 +0000 | [diff] [blame] | 54 | version = "2.15.0" |
Joe Gregorio | 696583c | 2012-03-21 15:20:51 -0400 | [diff] [blame] | 55 | |
Anthonios Partheniou | 430449d | 2021-04-22 14:46:04 -0400 | [diff] [blame] | 56 | setup( |
John Asmuth | 864311d | 2014-04-24 15:46:08 -0400 | [diff] [blame] | 57 | name="google-api-python-client", |
Anthonios Partheniou | 430449d | 2021-04-22 14:46:04 -0400 | [diff] [blame] | 58 | version=version, |
John Asmuth | 864311d | 2014-04-24 15:46:08 -0400 | [diff] [blame] | 59 | description="Google API Client Library for Python", |
Bu Sun Kim | f706cfd | 2020-04-20 14:05:05 -0700 | [diff] [blame] | 60 | long_description=readme, |
| 61 | long_description_content_type='text/markdown', |
| 62 | author="Google LLC", |
| 63 | author_email="googleapis-packages@google.com", |
Marie J.I | 48f503f | 2020-05-15 13:32:11 -0400 | [diff] [blame] | 64 | url="https://github.com/googleapis/google-api-python-client/", |
John Asmuth | 864311d | 2014-04-24 15:46:08 -0400 | [diff] [blame] | 65 | install_requires=install_requires, |
Bu Sun Kim | 8325d24 | 2020-12-09 12:04:05 -0700 | [diff] [blame] | 66 | python_requires=">=3.6", |
John Asmuth | 864311d | 2014-04-24 15:46:08 -0400 | [diff] [blame] | 67 | packages=packages, |
Anthonios Partheniou | ad618d0 | 2021-03-04 12:02:12 -0500 | [diff] [blame] | 68 | package_data={"googleapiclient": ["discovery_cache/documents/*.json"]}, |
John Asmuth | 864311d | 2014-04-24 15:46:08 -0400 | [diff] [blame] | 69 | license="Apache 2.0", |
| 70 | keywords="google api client", |
| 71 | classifiers=[ |
Bu Sun Kim | 66bb32c | 2019-10-30 10:11:58 -0700 | [diff] [blame] | 72 | "Programming Language :: Python :: 3", |
Bu Sun Kim | 66bb32c | 2019-10-30 10:11:58 -0700 | [diff] [blame] | 73 | "Programming Language :: Python :: 3.6", |
| 74 | "Programming Language :: Python :: 3.7", |
Bu Sun Kim | 8325d24 | 2020-12-09 12:04:05 -0700 | [diff] [blame] | 75 | "Programming Language :: Python :: 3.8", |
| 76 | "Programming Language :: Python :: 3.9", |
Bu Sun Kim | 66bb32c | 2019-10-30 10:11:58 -0700 | [diff] [blame] | 77 | "Development Status :: 5 - Production/Stable", |
| 78 | "Intended Audience :: Developers", |
| 79 | "License :: OSI Approved :: Apache Software License", |
| 80 | "Operating System :: OS Independent", |
| 81 | "Topic :: Internet :: WWW/HTTP", |
John Asmuth | 864311d | 2014-04-24 15:46:08 -0400 | [diff] [blame] | 82 | ], |
John Asmuth | 864311d | 2014-04-24 15:46:08 -0400 | [diff] [blame] | 83 | ) |