blob: ba7e619e9251197a8a0fe1165be335f179fc79b0 [file] [log] [blame]
Tom Miller7c95d812010-10-11 11:50:52 -07001# Copyright (C) 2010 Google Inc.
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 Gregorio48d361f2010-08-18 13:19:21 -040014
Tom Miller7c95d812010-10-11 11:50:52 -070015"""Setup script for Google API Python client.
16
17Also installs included versions of third party libraries, if those libraries
18are not already installed.
19"""
20
21import setup_utils
22
Joe Gregorio01b92702011-03-23 21:44:42 -040023# Modules, not packages, that might need to be installed.
24
Joe Gregorio6429bf62011-03-01 22:53:21 -080025packages = [
26 'apiclient',
27 'oauth2client',
28 'apiclient.ext',
29 'apiclient.contrib',
30 'apiclient.contrib.buzz',
31 'apiclient.contrib.latitude',
32 'apiclient.contrib.moderator',
Joe Gregorio4258d6b2011-03-18 10:20:16 -040033 'uritemplate',
Joe Gregorio6429bf62011-03-01 22:53:21 -080034]
Joe Gregorio01b92702011-03-23 21:44:42 -040035py_modules = []
Joe Gregorio6429bf62011-03-01 22:53:21 -080036
Joe Gregorio01b92702011-03-23 21:44:42 -040037third_party_packages = ['httplib2']
38third_party_modules = ['gflags', 'gflags_validators']
Tom Miller7c95d812010-10-11 11:50:52 -070039
40# Don't clobber installed versions of third party libraries
41# with what we include.
Joe Gregorio01b92702011-03-23 21:44:42 -040042packages.extend(setup_utils.get_missing_requirements(third_party_packages))
43py_modules.extend(setup_utils.get_missing_requirements(third_party_modules))
Tom Miller7c95d812010-10-11 11:50:52 -070044
45try:
46 # Some people prefer setuptools, and may have that installed
47 from setuptools import setup
48except ImportError:
49 from distutils.core import setup
Tom Miller7c95d812010-10-11 11:50:52 -070050
Joe Gregorio3ad5e9a2010-12-09 15:01:04 -050051long_desc = """The Google API Client for Python is a client library for
Tom Miller7c95d812010-10-11 11:50:52 -070052accessing the Buzz, Moderator, and Latitude APIs."""
53
Joe Gregorio48d361f2010-08-18 13:19:21 -040054setup(name="google-api-python-client",
Joe Gregorio5d7dbb32011-03-23 17:21:43 -040055 version="1.0alpha5",
Joe Gregorio48d361f2010-08-18 13:19:21 -040056 description="Google API Client Library for Python",
Tom Miller7c95d812010-10-11 11:50:52 -070057 long_description=long_desc,
Joe Gregorio48d361f2010-08-18 13:19:21 -040058 author="Joe Gregorio",
59 author_email="jcgregorio@google.com",
60 url="http://code.google.com/p/google-api-python-client/",
Tom Miller7c95d812010-10-11 11:50:52 -070061 packages=packages,
Joe Gregorio01b92702011-03-23 21:44:42 -040062 py_modules=py_modules,
Joe Gregorio6429bf62011-03-01 22:53:21 -080063 package_data={
64 'apiclient': ['contrib/*/*.json']
65 },
Tom Miller7c95d812010-10-11 11:50:52 -070066 license="Apache 2.0",
Joe Gregorio4258d6b2011-03-18 10:20:16 -040067 install_requires = ['python-gflags', 'oauth2'],
Tom Miller7c95d812010-10-11 11:50:52 -070068 keywords="google api client",
69 classifiers=['Development Status :: 3 - Alpha',
70 'Intended Audience :: Developers',
71 'License :: OSI Approved :: Apache Software License',
72 'Operating System :: POSIX',
73 'Topic :: Internet :: WWW/HTTP'])