示例#1
0
def check_for_dependencies():
    """Check for IPython's dependencies.

    This function should NOT be called if running under setuptools!
    """
    from setupext.setupext import (
        print_line, print_raw, print_status,
        check_for_sphinx, check_for_pygments,
        check_for_nose, check_for_pexpect,
        check_for_pyzmq, check_for_readline,
        check_for_jinja2, check_for_tornado
    )
    print_line()
    print_raw("BUILDING IPYTHON")
    print_status('python', sys.version)
    print_status('platform', sys.platform)
    if sys.platform == 'win32':
        print_status('Windows version', sys.getwindowsversion())

    print_raw("")
    print_raw("OPTIONAL DEPENDENCIES")

    check_for_sphinx()
    check_for_pygments()
    check_for_nose()
    if os.name == 'posix':
        check_for_pexpect()
    check_for_pyzmq()
    check_for_tornado()
    check_for_readline()
    check_for_jinja2()
示例#2
0
def check_for_dependencies():
    """Check for IPython's dependencies.
    
    This function should NOT be called if running under setuptools!
    """
    from setupext.setupext import (
        print_line,
        print_raw,
        print_status,
        check_for_sphinx,
        check_for_pygments,
        check_for_nose,
        check_for_pexpect,
        check_for_pyzmq,
        check_for_readline,
    )

    print_line()
    print_raw("BUILDING IPYTHON")
    print_status("python", sys.version)
    print_status("platform", sys.platform)
    if sys.platform == "win32":
        print_status("Windows version", sys.getwindowsversion())

    print_raw("")
    print_raw("OPTIONAL DEPENDENCIES")

    check_for_sphinx()
    check_for_pygments()
    check_for_nose()
    check_for_pexpect()
    check_for_pyzmq()
    check_for_readline()
示例#3
0
def check_for_dependencies():
    """Check for IPython's dependencies.
    
    This function should NOT be called if running under setuptools!
    """
    from setupext.setupext import (
        print_line, print_raw, print_status,
        check_for_sphinx, check_for_pygments,
        check_for_nose, check_for_pexpect,
        check_for_pyzmq, check_for_readline
    )
    print_line()
    print_raw("BUILDING IPYTHON")
    print_status('python', sys.version)
    print_status('platform', sys.platform)
    if sys.platform == 'win32':
        print_status('Windows version', sys.getwindowsversion())
    
    print_raw("")
    print_raw("OPTIONAL DEPENDENCIES")

    check_for_sphinx()
    check_for_pygments()
    check_for_nose()
    check_for_pexpect()
    check_for_pyzmq()
    check_for_readline()
示例#4
0
# This dict is used for passing extra arguments that are setuptools 
# specific to setup
setuptools_extra_args = {}

if 'setuptools' in sys.modules:
    setuptools_extra_args['zip_safe'] = False
    setuptools_extra_args['entry_points'] = find_scripts(True)
    setup_args['extras_require'] = dict(
        parallel = 'pyzmq>=2.1.4',
        zmq = 'pyzmq>=2.1.4',
        doc='Sphinx>=0.3',
        test='nose>=0.10.1',
    )
    requires = setup_args.setdefault('install_requires', [])
    setupext.display_status = False
    if not setupext.check_for_readline():
        if sys.platform == 'darwin':
            requires.append('readline')
        elif sys.platform.startswith('win'):
            requires.append('pyreadline')
        else:
            pass
            # do we want to install readline here?
    
    # Script to be run by the windows binary installer after the default setup
    # routine, to add shortcuts and similar windows-only things.  Windows
    # post-install scripts MUST reside in the scripts/ dir, otherwise distutils
    # doesn't find them.
    if 'bdist_wininst' in sys.argv:
        if len(sys.argv) > 2 and \
               ('sdist' in sys.argv or 'bdist_rpm' in sys.argv):
示例#5
0
        zmq='pyzmq>=2.1.11',
        doc='Sphinx>=0.3',
        test='nose>=0.10.1',
        notebook=['tornado>=3.1', 'pyzmq>=2.1.11', 'jinja2'],
        nbconvert=['pygments', 'jinja2', 'Sphinx>=0.3'])
    everything = set()
    for deps in setup_args['extras_require'].values():
        if not isinstance(deps, list):
            deps = [deps]
        for dep in deps:
            everything.add(dep)
    setup_args['extras_require']['all'] = everything

    requires = setup_args.setdefault('install_requires', [])
    setupext.display_status = False
    if not setupext.check_for_readline():
        if sys.platform == 'darwin':
            requires.append('readline')
        elif sys.platform.startswith('win'):
            # Pyreadline 64 bit windows issue solved in versions >=1.7.1
            # Also solves issues with some older versions of pyreadline that
            # satisfy the unconstrained depdendency.
            requires.append('pyreadline>=1.7.1')
        else:
            pass
            # do we want to install readline here?

    # Script to be run by the windows binary installer after the default setup
    # routine, to add shortcuts and similar windows-only things.  Windows
    # post-install scripts MUST reside in the scripts/ dir, otherwise distutils
    # doesn't find them.
示例#6
0
if sys.version_info < (3, 3):
    extras_require['test'].append('mock')

extras_require['notebook'].extend(extras_require['nbformat'])
extras_require['nbconvert'].extend(extras_require['nbformat'])

everything = set()
for deps in extras_require.values():
    everything.update(deps)
extras_require['all'] = everything

install_requires = []

# add readline
if sys.platform == 'darwin':
    if 'bdist_wheel' in sys.argv[1:] or not setupext.check_for_readline():
        install_requires.append('gnureadline')
elif sys.platform.startswith('win'):
    extras_require['terminal'].append('pyreadline>=2.0')


if 'setuptools' in sys.modules:
    # setup.py develop should check for submodules
    from setuptools.command.develop import develop
    setup_args['cmdclass']['develop'] = require_submodules(develop)
    setup_args['cmdclass']['bdist_wheel'] = css_js_prerelease(get_bdist_wheel())
    
    setuptools_extra_args['zip_safe'] = False
    setuptools_extra_args['entry_points'] = {
        'console_scripts': find_entry_points(),
        'pygments.lexers': [
示例#7
0
                      doc=['Sphinx>=1.1', 'numpydoc'],
                      test=['nose>=0.10.1'],
                      notebook=['tornado>=3.1', 'pyzmq>=2.1.11', 'jinja2'],
                      nbconvert=['pygments', 'jinja2', 'Sphinx>=0.3'])
if sys.version_info < (3, 3):
    extras_require['test'].append('mock')

everything = set()
for deps in extras_require.values():
    everything.update(deps)
extras_require['all'] = everything

install_requires = []
if sys.platform == 'darwin':
    if any(arg.startswith('bdist')
           for arg in sys.argv) or not setupext.check_for_readline():
        install_requires.append('gnureadline')
elif sys.platform.startswith('win'):
    # Pyreadline has unicode and Python 3 fixes in 2.0
    install_requires.append('pyreadline>=2.0')

if 'setuptools' in sys.modules:
    # setup.py develop should check for submodules
    from setuptools.command.develop import develop
    setup_args['cmdclass']['develop'] = require_submodules(develop)
    setup_args['cmdclass']['bdist_wheel'] = get_bdist_wheel()

    setuptools_extra_args['zip_safe'] = False
    setuptools_extra_args['entry_points'] = {
        'console_scripts': find_entry_points()
    }
示例#8
0
    doc = ['Sphinx>=1.1', 'numpydoc'],
    test = ['nose>=0.10.1'],
    notebook = ['tornado>=3.1', 'pyzmq>=2.1.11', 'jinja2'],
    nbconvert = ['pygments', 'jinja2', 'Sphinx>=0.3']
)
if sys.version_info < (3, 3):
    extras_require['test'].append('mock')

everything = set()
for deps in extras_require.values():
    everything.update(deps)
extras_require['all'] = everything

install_requires = []
if sys.platform == 'darwin':
    if any(arg.startswith('bdist') for arg in sys.argv) or not setupext.check_for_readline():
        install_requires.append('gnureadline')
elif sys.platform.startswith('win'):
    # Pyreadline has unicode and Python 3 fixes in 2.0
    install_requires.append('pyreadline>=2.0')

if 'setuptools' in sys.modules:
    # setup.py develop should check for submodules
    from setuptools.command.develop import develop
    setup_args['cmdclass']['develop'] = require_submodules(develop)
    setup_args['cmdclass']['bdist_wheel'] = get_bdist_wheel()
    
    setuptools_extra_args['zip_safe'] = False
    setuptools_extra_args['entry_points'] = {'console_scripts':find_entry_points()}
    setup_args['extras_require'] = extras_require
    requires = setup_args['install_requires'] = install_requires
示例#9
0
文件: setup.py 项目: zh3036/ipython
    nbconvert=['pygments', 'jinja2', 'mistune>=0.3.1'])

if not sys.platform.startswith('win'):
    extras_require['notebook'].append('terminado>=0.3.3')

if sys.version_info < (3, 3):
    extras_require['test'].append('mock')

extras_require['notebook'].extend(extras_require['nbformat'])
extras_require['nbconvert'].extend(extras_require['nbformat'])

install_requires = []

# add readline
if sys.platform == 'darwin':
    if 'bdist_wheel' in sys.argv[1:] or not setupext.check_for_readline():
        install_requires.append('gnureadline')
elif sys.platform.startswith('win'):
    extras_require['terminal'].append('pyreadline>=2.0')

everything = set()
for deps in extras_require.values():
    everything.update(deps)
extras_require['all'] = everything

if 'setuptools' in sys.modules:
    # setup.py develop should check for submodules
    from setuptools.command.develop import develop
    setup_args['cmdclass']['develop'] = require_submodules(develop)
    setup_args['cmdclass']['bdist_wheel'] = css_js_prerelease(
        get_bdist_wheel())
示例#10
0
if sys.version_info < (3, 3):
    extras_require['test'].append('mock')

extras_require['notebook'].extend(extras_require['nbformat'])
extras_require['nbconvert'].extend(extras_require['nbformat'])

everything = set()
for deps in extras_require.values():
    everything.update(deps)
extras_require['all'] = everything

install_requires = []

# add readline
if sys.platform == 'darwin':
    if any(arg.startswith('bdist') for arg in sys.argv) or not setupext.check_for_readline():
        install_requires.append('gnureadline')
elif sys.platform.startswith('win'):
    extras_require['terminal'].append('pyreadline>=2.0')


if 'setuptools' in sys.modules:
    # setup.py develop should check for submodules
    from setuptools.command.develop import develop
    setup_args['cmdclass']['develop'] = require_submodules(develop)
    setup_args['cmdclass']['bdist_wheel'] = css_js_prerelease(get_bdist_wheel())
    
    setuptools_extra_args['zip_safe'] = False
    setuptools_extra_args['entry_points'] = {'console_scripts':find_entry_points()}
    setup_args['extras_require'] = extras_require
    requires = setup_args['install_requires'] = install_requires