X-Git-Url: http://git.inspyration.org/?a=blobdiff_plain;f=setup.py;h=6e1adadde826c99f3b812c8256c809b9db83c7fb;hb=3557f3a25e10de4b305033b67ceaa81ab0d1420f;hp=7811915ebcfeda0c49bffb590a7ddbc8809ce2ef;hpb=5356be186dc6650dcdc260d2872b9d6f6aaa75c5;p=odoo%2Fodoo.git diff --git a/setup.py b/setup.py index 7811915..6e1adad 100755 --- a/setup.py +++ b/setup.py @@ -21,29 +21,31 @@ ############################################################################## import glob, os, re, setuptools, sys -from os.path import join +from os.path import join, isfile # List all data files def data(): - r = {} + files = [] for root, dirnames, filenames in os.walk('openerp'): for filename in filenames: - if not re.match(r'.*(\.pyc|\.pyo|\~)$', filename): - r.setdefault(root, []).append(os.path.join(root, filename)) - + if not re.match(r'.*(\.pyc|\.pyo|\~)$',filename): + files.append(os.path.join(root, filename)) + d = {} + for v in files: + k=os.path.dirname(v) + if k in d: + d[k].append(v) + else: + d[k]=[v] + r = d.items() if os.name == 'nt': - r["Microsoft.VC90.CRT"] = glob.glob('C:\Microsoft.VC90.CRT\*.*') - - import babel - r["localedata"] = glob.glob(os.path.join(os.path.dirname(babel.__file__), "localedata", '*')) + r.append(("Microsoft.VC90.CRT", glob.glob('C:\Microsoft.VC90.CRT\*.*'))) - import pytz - tzdir = os.path.dirname(pytz.__file__) - for root, _, filenames in os.walk(os.path.join(tzdir, "zoneinfo")): - base = os.path.join('pytz', root[len(tzdir) + 1:]) - r[base] = [os.path.join(root, f) for f in filenames] + import babel + r.append(("localedata", + glob.glob(os.path.join(os.path.dirname(babel.__file__), "localedata" , '*')))) - return r.items() + return r def gen_manifest(): file_list="\n".join(data()) @@ -62,7 +64,7 @@ def py2exe_options(): "skip_archive": 1, "optimize": 2, "dist_dir": 'dist', - "packages": [ "DAV", "HTMLParser", "PIL", "asynchat", "asyncore", "commands", "dateutil", "decimal", "docutils", "email", "encodings", "imaplib", "lxml", "lxml._elementpath", "lxml.builder", "lxml.etree", "lxml.objectify", "mako", "openerp", "poplib", "pychart", "pydot", "pyparsing", "pytz", "reportlab", "select", "simplejson", "smtplib", "uuid", "vatnumber", "vobject", "xml", "xml.dom", "yaml", ], + "packages": [ "DAV", "HTMLParser", "PIL", "asynchat", "asyncore", "commands", "dateutil", "decimal", "email", "encodings", "imaplib", "lxml", "lxml._elementpath", "lxml.builder", "lxml.etree", "lxml.objectify", "mako", "openerp", "poplib", "pychart", "pydot", "pyparsing", "reportlab", "select", "simplejson", "smtplib", "uuid", "vatnumber", "vobject", "xml", "xml.dom", "yaml", ], "excludes" : ["Tkconstants","Tkinter","tcl"], } } @@ -72,19 +74,6 @@ def py2exe_options(): execfile(join(os.path.dirname(__file__), 'openerp', 'release.py')) -# Notes for OpenERP developer on windows: -# -# To setup a windows developer evironement install python2.7 then pip and use -# "pip install " for every dependency listed below. -# -# Dependecies that requires DLLs are not installable with pip install, for -# them we added comments with links where you can find the installers. -# -# OpenERP on windows also require the pywin32, the binary can be found at -# http://pywin32.sf.net -# -# Both python2.7 32bits and 64bits are known to work. - setuptools.setup( name = 'openerp', version = version, @@ -98,39 +87,38 @@ setuptools.setup( scripts = ['openerp-server'], data_files = data(), packages = setuptools.find_packages(), - dependency_links = ['http://download.gna.org/pychart/'], #include_package_data = True, install_requires = [ - 'pychart', # not on pypi, use: pip install http://download.gna.org/pychart/PyChart-1.39.tar.gz + # TODO the pychart package we include in openerp corresponds to PyChart 1.37. + # It seems there is a single difference, which is a spurious print in generate_docs.py. + # It is probably safe to move to PyChart 1.39 (the latest one). + # (Let setup.py choose the latest one, and we should check we can remove pychart from + # our tree.) http://download.gna.org/pychart/ + # TODO 'pychart', 'babel', - 'docutils', 'feedparser', 'gdata', - 'lxml < 3', # windows binary http://www.lfd.uci.edu/~gohlke/pythonlibs/ + 'lxml', 'mako', - 'mock', - 'PIL', # windows binary http://www.lfd.uci.edu/~gohlke/pythonlibs/ - 'psutil', # windows binary code.google.com/p/psutil/downloads/list 'psycopg2', 'pydot', 'python-dateutil < 2', - 'python-ldap', # optional + 'python-ldap', 'python-openid', 'pytz', 'pywebdav', 'pyyaml', - 'reportlab', # windows binary pypi.python.org/pypi/reportlab + 'reportlab', 'simplejson', - 'unittest2', 'vatnumber', 'vobject', 'werkzeug', 'xlwt', + 'zsi', ], extras_require = { 'SSL' : ['pyopenssl'], }, - tests_require = ['unittest2'], **py2exe_options() )