I have python 2.7 pre-installed on my mac. I have downloaded the orange snapshot from http://orange.biolab.si/download/. However on opening the python shell in IDLE and typing "import Orange" it gives error "no such module exists".
Further upon trying to do the easy_install by typing on Terminal "easy_install numpy && easy_install orange", I get the following error. Am I missing something elementary here? Look forward to inputs.
Searching for numpy
Best match: numpy 1.7.1
Adding numpy 1.7.1 to easy-install.pth file
Using /Users/Sunny/anaconda/lib/python2.7/site-packages
Processing dependencies for numpy
Finished processing dependencies for numpy
Searching for orange
Reading http://pypi.python.org/simple/orange/
Reading http://orange.biolab.si
Reading http://orange.biolab.si/svn/orange/trunk
Reading http://orange.biolab.si/
Reading https://bitbucket.org/biolab/orange/downloads
Best match: Orange 2.7
Downloading http://pypi.python.org/packages/source/O/Orange/Orange-2.7.tar.gz#md5=74f8fdb45688ef75ced7838567846470
Processing Orange-2.7.tar.gz
Writing /var/folders/h5/z1wnbzk518j1vvgzt9x2m9j40000gn/T/easy_install-zJCDvj/Orange-2.7/setup.cfg
Running Orange-2.7/setup.py -q bdist_egg --dist-dir /var/folders/h5/z1wnbzk518j1vvgzt9x2m9j40000gn/T/easy_install-zJCDvj/Orange-2.7/egg-dist-tmp-Zb7l0Q
Warning: Can't read registry to find the necessary compiler setting
Make sure that Python modules _winreg, win32api or win32con are installed.
warning: no previously-included files matching '*' found under directory 'source/orangeqt/build'
no previously-included directories found matching 'source/orange/px'
no previously-included directories found matching 'source/orange/ppp'
no previously-included directories found matching 'source/orangeom/px'
no previously-included directories found matching 'source/orangene/ppp'
no previously-included directories found matching 'source/orangene/px'
no previously-included directories found matching 'source/orangene/ppp'
warning: no previously-included files found matching 'source/orangeom/lib_vectors.cpp'
warning: no previously-included files found matching 'source/orangene/lib_vectors.cpp'
no previously-included directories found matching 'docs/build'
Traceback (most recent call last):
File "/Users/Sunny/anaconda/bin/easy_install", line 6, in <module>
sys.exit(main())
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 1954, in main
with_ei_usage(lambda:
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 1935, in with_ei_usage
return f()
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 1958, in <lambda>
distclass=DistributionWithoutHelpCommands, **kw
File "/Users/Sunny/anaconda/lib/python2.7/distutils/core.py", line 152, in setup
dist.run_commands()
File "/Users/Sunny/anaconda/lib/python2.7/distutils/dist.py", line 953, in run_commands
self.run_command(cmd)
File "/Users/Sunny/anaconda/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 358, in run
self.easy_install(spec, not self.no_deps)
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 602, in easy_install
return self.install_item(spec, dist.location, tmpdir, deps)
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 632, in install_item
dists = self.install_eggs(spec, download, tmpdir)
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 827, in install_eggs
return self.build_and_install(setup_script, setup_base)
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 1107, in build_and_install
self.run_setup(setup_script, setup_base, args)
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 1093, in run_setup
run_setup(setup_script, args)
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/sandbox.py", line 33, in run_setup
lambda: execfile(
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/sandbox.py", line 81, in run
return func()
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/sandbox.py", line 35, in <lambda>
{'__file__':setup_script, '__name__':'__main__'}
File "setup.py", line 792, in <module>
File "setup.py", line 788, in setup_package
File "/Users/Sunny/anaconda/lib/python2.7/distutils/core.py", line 152, in setup
dist.run_commands()
File "/Users/Sunny/anaconda/lib/python2.7/distutils/dist.py", line 953, in run_commands
self.run_command(cmd)
File "/Users/Sunny/anaconda/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/command/bdist_egg.py", line 179, in run
cmd = self.call_command('install_lib', warn_dir=0)
File "/Users/Sunny/anaconda/lib/python2.7/site-packages/setuptools/command/bdist_egg.py", line 166, in call_command
self.run_command(cmdname)
File "/Users/Sunny/anaconda/lib/python2.7/distutils/cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "/Users/Sunny/anaconda/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "setup.py", line 454, in run
File "/Users/Sunny/anaconda/lib/python2.7/distutils/command/install_lib.py", line 92, in run
self.build()
File "/Users/Sunny/anaconda/lib/python2.7/distutils/command/install_lib.py", line 111, in build
self.run_command('build_ext')
File "/Users/Sunny/anaconda/lib/python2.7/distutils/cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "/Users/Sunny/anaconda/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/Users/Sunny/anaconda/lib/python2.7/distutils/command/build_ext.py", line 309, in run
customize_compiler(self.compiler)
File "/Users/Sunny/anaconda/lib/python2.7/distutils/sysconfig.py", line 170, in customize_compiler
_osx_support.customize_compiler(_config_vars)
File "/Users/Sunny/anaconda/lib/python2.7/_osx_support.py", line 412, in customize_compiler
_find_appropriate_compiler(_config_vars)
File "/Users/Sunny/anaconda/lib/python2.7/_osx_support.py", line 191, in _find_appropriate_compiler
"Cannot locate working compiler")
SystemError: Cannot locate working compiler
Related
I am now trying to run a program on a super computer on which I cannot run sudo or easy_install. The program needs pandas so I need to pip install pandas but I keep getting this error message even thought I have tried "pip install --upgrade pip" already.
You are using pip version 8.1.2, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
--edit--
Here is the error message when I pip3 install pandas.
pip3 install pandas
Collecting pandas
Using cached pandas-0.22.0.tar.gz
Complete output from command python setup.py egg_info:
Running from numpy source directory.
/tmp/easy_install-gv5il123/numpy-1.14.1/setup.py:369: UserWarning: Unrecognized setuptools command, proceeding with generating Cython sources and expanding templates
run_build = parse_setuppy_commands()
/usr/lib64/python3.4/distutils/dist.py:260: UserWarning: Unknown distribution option: 'python_requires'
warnings.warn(msg)
/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/system_info.py:624: UserWarning:
Atlas (http://math-atlas.sourceforge.net/) libraries not found.
Directories to search for the libraries can be specified in the
numpy/distutils/site.cfg file (section [atlas]) or by setting
the ATLAS environment variable.
self.calc_info()
/usr/lib64/python3.4/distutils/dist.py:260: UserWarning: Unknown distribution option: 'python_requires'
warnings.warn(msg)
/usr/lib64/python3.4/distutils/dist.py:260: UserWarning: Unknown distribution option: 'define_macros'
warnings.warn(msg)
Traceback (most recent call last):
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 154, in save_modules
yield saved
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 195, in setup_context
yield
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 239, in run_setup
DirectorySandbox(setup_dir).run(runner)
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 269, in run
return func()
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 238, in runner
_execfile(setup_script, ns)
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 46, in _execfile
exec(code, globals, locals)
File "/tmp/easy_install-gv5il123/numpy-1.14.1/setup.py", line 394, in <module>
File "/tmp/easy_install-gv5il123/numpy-1.14.1/setup.py", line 386, in setup_package
File "/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/core.py", line 169, in setup
File "/usr/lib64/python3.4/distutils/core.py", line 148, in setup
dist.run_commands()
File "/usr/lib64/python3.4/distutils/dist.py", line 955, in run_commands
self.run_command(cmd)
File "/usr/lib64/python3.4/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "/usr/lib/python3.4/site-packages/setuptools/command/bdist_egg.py", line 151, in run
self.run_command("egg_info")
File "/usr/lib64/python3.4/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib64/python3.4/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/command/egg_info.py", line 26, in run
File "/usr/lib64/python3.4/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib64/python3.4/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/command/build_src.py", line 148, in run
File "/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/command/build_src.py", line 165, in build_sources
File "/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/command/build_src.py", line 324, in build_extension_sources
File "/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/command/build_src.py", line 377, in generate_sources
File "numpy/core/setup.py", line 422, in generate_config_h
return tag
File "numpy/core/setup.py", line 48, in check_types
min_numpy_ver = '1.9.0'
File "numpy/core/setup.py", line 281, in check_types
pjoin(ujson_lib,'ultrajsondec.c'),
SystemError: Cannot compile 'Python.h'. Perhaps you need to install python-dev|python-devel.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-build-xqyfs1o1/pandas/setup.py", line 743, in <module>
**setuptools_kwargs)
File "/usr/lib64/python3.4/distutils/core.py", line 108, in setup
_setup_distribution = dist = klass(attrs)
File "/usr/lib/python3.4/site-packages/setuptools/dist.py", line 268, in __init__
self.fetch_build_eggs(attrs['setup_requires'])
File "/usr/lib/python3.4/site-packages/setuptools/dist.py", line 312, in fetch_build_eggs
replace_conflicting=True,
File "/usr/lib/python3.4/site-packages/pkg_resources/__init__.py", line 846, in resolve
dist = best[req.key] = env.best_match(req, ws, installer)
File "/usr/lib/python3.4/site-packages/pkg_resources/__init__.py", line 1091, in best_match
return self.obtain(req, installer)
File "/usr/lib/python3.4/site-packages/pkg_resources/__init__.py", line 1103, in obtain
return installer(requirement)
File "/usr/lib/python3.4/site-packages/setuptools/dist.py", line 379, in fetch_build_egg
return cmd.easy_install(req)
File "/usr/lib/python3.4/site-packages/setuptools/command/easy_install.py", line 638, in easy_install
return self.install_item(spec, dist.location, tmpdir, deps)
File "/usr/lib/python3.4/site-packages/setuptools/command/easy_install.py", line 668, in install_item
dists = self.install_eggs(spec, download, tmpdir)
File "/usr/lib/python3.4/site-packages/setuptools/command/easy_install.py", line 851, in install_eggs
return self.build_and_install(setup_script, setup_base)
File "/usr/lib/python3.4/site-packages/setuptools/command/easy_install.py", line 1079, in build_and_install
self.run_setup(setup_script, setup_base, args)
File "/usr/lib/python3.4/site-packages/setuptools/command/easy_install.py", line 1065, in run_setup
run_setup(setup_script, args)
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 242, in run_setup
raise
File "/usr/lib64/python3.4/contextlib.py", line 77, in __exit__
self.gen.throw(type, value, traceback)
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 195, in setup_context
yield
File "/usr/lib64/python3.4/contextlib.py", line 77, in __exit__
self.gen.throw(type, value, traceback)
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 166, in save_modules
saved_exc.resume()
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 141, in resume
compat.reraise(type, exc, self._tb)
File "/usr/lib/python3.4/site-packages/setuptools/compat.py", line 69, in reraise
raise value.with_traceback(tb)
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 154, in save_modules
yield saved
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 195, in setup_context
yield
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 239, in run_setup
DirectorySandbox(setup_dir).run(runner)
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 269, in run
return func()
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 238, in runner
_execfile(setup_script, ns)
File "/usr/lib/python3.4/site-packages/setuptools/sandbox.py", line 46, in _execfile
exec(code, globals, locals)
File "/tmp/easy_install-gv5il123/numpy-1.14.1/setup.py", line 394, in <module>
File "/tmp/easy_install-gv5il123/numpy-1.14.1/setup.py", line 386, in setup_package
File "/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/core.py", line 169, in setup
File "/usr/lib64/python3.4/distutils/core.py", line 148, in setup
dist.run_commands()
File "/usr/lib64/python3.4/distutils/dist.py", line 955, in run_commands
self.run_command(cmd)
File "/usr/lib64/python3.4/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "/usr/lib/python3.4/site-packages/setuptools/command/bdist_egg.py", line 151, in run
self.run_command("egg_info")
File "/usr/lib64/python3.4/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib64/python3.4/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/command/egg_info.py", line 26, in run
File "/usr/lib64/python3.4/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib64/python3.4/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/command/build_src.py", line 148, in run
File "/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/command/build_src.py", line 165, in build_sources
File "/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/command/build_src.py", line 324, in build_extension_sources
File "/tmp/easy_install-gv5il123/numpy-1.14.1/numpy/distutils/command/build_src.py", line 377, in generate_sources
File "numpy/core/setup.py", line 422, in generate_config_h
return tag
File "numpy/core/setup.py", line 48, in check_types
min_numpy_ver = '1.9.0'
File "numpy/core/setup.py", line 281, in check_types
pjoin(ujson_lib,'ultrajsondec.c'),
SystemError: Cannot compile 'Python.h'. Perhaps you need to install python-dev|python-devel.
/tmp/easy_install-gv5il123/numpy-1.14.1/temp/tmpsx06jzi5/source.c:1:19: fatal error: cblas.h: No such file or directory
#include <cblas.h>
^
compilation terminated.
/tmp/easy_install-gv5il123/numpy-1.14.1/temp/tmpsx06jzi5/source.c:1:19: fatal error: cblas.h: No such file or directory
#include <cblas.h>
^
compilation terminated.
non-existing path in 'numpy/distutils': 'site.cfg'
_configtest.c:1:5: warning: conflicting types for built-in function ‘exp’
int exp (void);
^~~
_configtest.o: In function `main':
/tmp/easy_install-gv5il123/numpy-1.14.1/_configtest.c:6: undefined reference to `exp'
collect2: error: ld returned 1 exit status
_configtest.o: In function `main':
/tmp/easy_install-gv5il123/numpy-1.14.1/_configtest.c:6: undefined reference to `exp'
collect2: error: ld returned 1 exit status
_configtest.c:1:5: warning: conflicting types for built-in function ‘exp’
int exp (void);
^~~
_configtest.c:1:20: fatal error: Python.h: No such file or directory
#include <Python.h>
^
compilation terminated.
_configtest.c:1:20: fatal error: Python.h: No such file or directory
#include <Python.h>
^
compilation terminated.
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in
/tmp/pip-build-xqyfs1o1/pandas/
You are using pip version 8.1.2, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
You are missing the packages python-dev and python-devel.
But since you are not root on that server you probably cannot install them yourself. Basically you could ask the administrator if he could install them for you.
I would recommend installing a local version of Python and install the packages there.
By the way: Since you are not root pip would fail anyways since you probably do not have the right to globally install packages. You should use pip install <package> --user instead.
I try to install reddit on a 12.04 ubuntu server but I get an error
Please see the lines from terminal below. Please help me to fix it.
I get this error after the ff line "sudo python setup.py develop"
I already install the all necessary dependencies using the PPA
Cannot find Cython. Skipping Cython build.
Cannot find Baseplate. Skipping Thrift build.
running develop
Checking .pth file support in /usr/local/lib/python2.7/dist-packages/
/usr/bin/python -E -c pass
TEST PASSED: /usr/local/lib/python2.7/dist-packages/ appears to support .pth files
running egg_info
writing requirements to r2.egg-info/requires.txt
writing r2.egg-info/PKG-INFO
writing top-level names to r2.egg-info/top_level.txt
writing dependency_links to r2.egg-info/dependency_links.txt
writing entry points to r2.egg-info/entry_points.txt
reading manifest file 'r2.egg-info/SOURCES.txt'
writing manifest file 'r2.egg-info/SOURCES.txt'
running build_ext
copying build/lib.linux-x86_64-2.7/Cfilters.so ->
Creating /usr/local/lib/python2.7/dist-packages/r2.egg-link (link to .)
r2 0.0.0dev is already the active version in easy-install.pth
Installed /home/reddit/reddit/r2
Processing dependencies for r2==0.0.0dev
Searching for Pillow
Reading http://pypi.python.org/simple/Pillow/
Best match: Pillow 3.2.0
Downloading https://pypi.python.org/packages/e2/af/0a3981fffc5cd43078eb8b1057702e0dd2d5771e5aaa36cbd140e32f8473/Pillow-3.2.0.tar.gz#md5=7cfd093c11205d9e2ebe3c51dfcad510
Processing Pillow-3.2.0.tar.gz
Running Pillow-3.2.0/setup.py -q bdist_egg --dist-dir /tmp/easy_install-72k68O/Pillow-3.2.0/egg-dist-tmp-auWCL6
warning: no files found matching '*.sh'
no previously-included directories found matching 'docs/_static'
warning: no previously-included files found matching '.coveragerc'
warning: no previously-included files found matching '.editorconfig'
warning: no previously-included files found matching '.landscape.yaml'
warning: no previously-included files found matching 'appveyor.yml'
warning: no previously-included files found matching 'build_children.sh'
warning: no previously-included files found matching 'tox.ini'
warning: no previously-included files matching '.git*' found anywhere in distribution
warning: no previously-included files matching '*.pyc' found anywhere in distribution
warning: no previously-included files matching '*.so' found anywhere in distribution
Traceback (most recent call last):
File "setup.py", line 138, in <module>
""",
File "/usr/lib/python2.7/distutils/core.py", line 152, in setup
dist.run_commands()
File "/usr/lib/python2.7/distutils/dist.py", line 953, in run_commands
self.run_command(cmd)
File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/usr/lib/python2.7/dist-packages/setuptools/command/develop.py", line 27, in run
self.install_for_development()
File "/usr/lib/python2.7/dist-packages/setuptools/command/develop.py", line 105, in install_for_development
self.process_distribution(None, self.dist, not self.no_deps)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 692, in process_distribution
[requirement], self.local_index, self.easy_install
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 576, in resolve
dist = best[req.key] = env.best_match(req, self, installer)
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 821, in best_match
return self.obtain(req, installer) # try and download/install
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 833, in obtain
return installer(requirement)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 608, in easy_install
return self.install_item(spec, dist.location, tmpdir, deps)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 638, in install_item
dists = self.install_eggs(spec, download, tmpdir)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 828, in install_eggs
return self.build_and_install(setup_script, setup_base)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 1105, in build_and_install
self.run_setup(setup_script, setup_base, args)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 1094, in run_setup
run_setup(setup_script, args)
File "/usr/lib/python2.7/dist-packages/setuptools/sandbox.py", line 30, in run_setup
lambda: execfile(
File "/usr/lib/python2.7/dist-packages/setuptools/sandbox.py", line 72, in run
return func()
File "/usr/lib/python2.7/dist-packages/setuptools/sandbox.py", line 32, in <lambda>
{'__file__':setup_script, '__name__':'__main__'}
File "setup.py", line 767, in <module>
File "/usr/lib/python2.7/distutils/core.py", line 152, in setup
dist.run_commands()
File "/usr/lib/python2.7/distutils/dist.py", line 953, in run_commands
self.run_command(cmd)
File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/usr/lib/python2.7/dist-packages/setuptools/command/bdist_egg.py", line 179, in run
cmd = self.call_command('install_lib', warn_dir=0)
File "/usr/lib/python2.7/dist-packages/setuptools/command/bdist_egg.py", line 166, in call_command
self.run_command(cmdname)
File "/usr/lib/python2.7/distutils/cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/usr/lib/python2.7/dist-packages/setuptools/command/install_lib.py", line 20, in run
self.build()
File "/usr/lib/python2.7/distutils/command/install_lib.py", line 111, in build
self.run_command('build_ext')
File "/usr/lib/python2.7/distutils/cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/usr/lib/python2.7/distutils/command/build_ext.py", line 339, in run
self.build_extensions()
File "setup.py", line 512, in build_extensions
ValueError: jpeg is required unless explicitly disabled using --disable-jpeg, aborting
You may need some additional libraries to use Pillow. For Ubuntu 12.04 you can try the solution from this question
sudo apt-get install libtiff4-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms2-dev libwebp-dev tcl8.5-dev tk8.5-dev python-tk
This previous solution suggests just trying to install libjpeg8-dev first.
I'm a new beginner in Python and trying to install cython in Windows 7 (i use Anaconda to code with python). I meet a problem when installing cython in my computer:
E:\Python\Cython-0.24>python setup.py install
Unable to find pgen, not compiling formal grammar.
running install
running bdist_egg
running egg_info
writing top-level names to Cython.egg-info\top_level.txt
writing entry points to Cython.egg-info\entry_points.txt
writing Cython.egg-info\PKG-INFO
writing dependency_links to Cython.egg-info\dependency_links.txt
reading manifest file 'Cython.egg-info\SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching '*.pyx' under directory 'Cython\Debugger\Tests'
warning: no files found matching '*.pxd' under directory 'Cython\Debugger\Tests'
warning: no files found matching '*.h' under directory 'Cython\Debugger\Tests'
warning: no files found matching '*.pxd' under directory 'Cython\Utility'
writing manifest file 'Cython.egg-info\SOURCES.txt'
installing library code to build\bdist.win32\egg
running install_lib
running build_py
running build_ext
Traceback (most recent call last):
File "setup.py", line 326, in <module>
**setup_args
File "C:\Anaconda3\lib\distutils\core.py", line 148, in setup
dist.run_commands()
File "C:\Anaconda3\lib\distutils\dist.py", line 955, in run_commands
self.run_command(cmd)
File "C:\Anaconda3\lib\distutils\dist.py", line 974, in run_command
cmd_obj.run()
File "C:\Anaconda3\lib\site-packages\setuptools-18.4-py3.5.egg\setuptools\comm
and\install.py", line 67, in run
File "C:\Anaconda3\lib\site-packages\setuptools-18.4-py3.5.egg\setuptools\comm
and\install.py", line 109, in do_egg_install
File "C:\Anaconda3\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Anaconda3\lib\distutils\dist.py", line 974, in run_command
cmd_obj.run()
File "C:\Anaconda3\lib\site-packages\setuptools-18.4-py3.5.egg\setuptools\comm
and\bdist_egg.py", line 160, in run
File "C:\Anaconda3\lib\site-packages\setuptools-18.4-py3.5.egg\setuptools\comm
and\bdist_egg.py", line 146, in call_command
File "C:\Anaconda3\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Anaconda3\lib\distutils\dist.py", line 974, in run_command
cmd_obj.run()
File "C:\Anaconda3\lib\site-packages\setuptools-18.4-py3.5.egg\setuptools\comm
and\install_lib.py", line 10, in run
File "C:\Anaconda3\lib\distutils\command\install_lib.py", line 107, in build
self.run_command('build_ext')
File "C:\Anaconda3\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Anaconda3\lib\distutils\dist.py", line 974, in run_command
cmd_obj.run()
File "E:\Python\Cython-0.24\Cython\Distutils\build_ext.py", line 164, in run
_build_ext.build_ext.run(self)
File "C:\Anaconda3\lib\distutils\command\build_ext.py", line 307, in run
force=self.force)
File "C:\Anaconda3\lib\distutils\ccompiler.py", line 1031, in new_compiler
return klass(None, dry_run, force)
File "C:\Anaconda3\lib\distutils\cygwinccompiler.py", line 282, in __init__
CygwinCCompiler.__init__ (self, verbose, dry_run, force)
File "C:\Anaconda3\lib\distutils\cygwinccompiler.py", line 126, in __init__
if self.ld_version >= "2.10.90":
TypeError: unorderable types: NoneType() >= str()
E:\Python\Cython-0.24>
How can i solve it and successfully install cython? Thank you !
If you're using Anaconda the first port of call when installing new modules should be to use conda:
conda install cython
This will install a binary package, avoid the need for any compilation (which means you don't need a C/C++ compiler installed).
Occasionally you'll come across a module that isn't provided, in which case it's OK to do:
pip install nameofmissingmodule
I just was trying to install yowsup on my new Raspberry Pi. Everything went fine, until it was about to install Pillow. I got the following error message:
Processing dependencies for yowsup2==2.4
Searching for pillow
Reading http://pypi.python.org/simple/pillow/
Best match: Pillow 3.0.0
Downloading https://pypi.python.org/packages/source/P/Pillow/Pillow-3.0.0.zip#md5=dd81f6cc3f3a5e5fe72f0f1d936339c3
Processing Pillow-3.0.0.zip
Running Pillow-3.0.0/setup.py -q bdist_egg --dist-dir /tmp/easy_install-AlZEzs/Pillow-3.0.0/egg-dist-tmp-rX2XN3
Exception in thread Thread-1 (most likely raised during interpreter shutdown):Exception in thread Thread-2 (most likely raised during interpreter shutdown):
Traceback (most recent call last):
File "/usr/lib/python2.7/threading.py", line 552, in __bootstrap_innerTraceback (most recent call last):
File "/usr/lib/python2.7/threading.py", line 505, in run File "/usr/lib/python2.7/threading.py", line 552, in __bootstrap_inner
File "/usr/lib/python2.7/multiprocessing/pool.py", line 353, in _handle_tasks File "/usr/lib/python2.7/threading.py", line 505, in run
File "/usr/lib/python2.7/multiprocessing/pool.py", line 329, in _handle_workers
<type 'exceptions.TypeError'>: 'NoneType' object is not callable
Exception
TypeError<type 'exceptions.TypeError'>: 'NoneType' object is not callable
: TypeError("'NoneType' object does not support item deletion",) in <Finalize object, dead> ignored
Traceback (most recent call last):
File "setup.py", line 42, in <module>
'Topic :: Software Development :: Libraries :: Python Modules'
File "/usr/lib/python2.7/distutils/core.py", line 152, in setup
dist.run_commands()
File "/usr/lib/python2.7/distutils/dist.py", line 953, in run_commands
self.run_command(cmd)
File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/usr/lib/python2.7/dist-packages/setuptools/command/install.py", line 73, in run
self.do_egg_install()
File "/usr/lib/python2.7/dist-packages/setuptools/command/install.py", line 101, in do_egg_install
cmd.run()
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 368, in run
self.easy_install(spec, not self.no_deps)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 588, in easy_install
return self.install_item(None, spec, tmpdir, deps, True)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 640, in install_item
self.process_distribution(spec, dist, deps)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 692, in process_distribution
[requirement], self.local_index, self.easy_install
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 576, in resolve
dist = best[req.key] = env.best_match(req, self, installer)
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 821, in best_match
return self.obtain(req, installer) # try and download/install
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 833, in obtain
return installer(requirement)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 608, in easy_install
return self.install_item(spec, dist.location, tmpdir, deps)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 638, in install_item
dists = self.install_eggs(spec, download, tmpdir)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 828, in install_eggs
return self.build_and_install(setup_script, setup_base)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 1105, in build_and_install
self.run_setup(setup_script, setup_base, args)
File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 1094, in run_setup
run_setup(setup_script, args)
File "/usr/lib/python2.7/dist-packages/setuptools/sandbox.py", line 30, in run_setup
lambda: execfile(
File "/usr/lib/python2.7/dist-packages/setuptools/sandbox.py", line 72, in run
return func()
File "/usr/lib/python2.7/dist-packages/setuptools/sandbox.py", line 32, in <lambda>
{'__file__':setup_script, '__name__':'__main__'}
File "setup.py", line 767, in <module>
File "/usr/lib/python2.7/distutils/core.py", line 152, in setup
dist.run_commands()
File "/usr/lib/python2.7/distutils/dist.py", line 953, in run_commands
self.run_command(cmd)
File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/usr/lib/python2.7/dist-packages/setuptools/command/bdist_egg.py", line 179, in run
cmd = self.call_command('install_lib', warn_dir=0)
File "/usr/lib/python2.7/dist-packages/setuptools/command/bdist_egg.py", line 166, in call_command
self.run_command(cmdname)
File "/usr/lib/python2.7/distutils/cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/usr/lib/python2.7/dist-packages/setuptools/command/install_lib.py", line 20, in run
self.build()
File "/usr/lib/python2.7/distutils/command/install_lib.py", line 111, in build
self.run_command('build_ext')
File "/usr/lib/python2.7/distutils/cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/usr/lib/python2.7/distutils/command/build_ext.py", line 339, in run
self.build_extensions()
File "setup.py", line 515, in build_extensions
ValueError: --enable-jpeg requested but jpeg not found, aborting.
I googeled it for at least an hour, but couldn't find a correct answer. Do you have any suggestions for me?
So it looks like you're trying to install PIL without the proper packages installed beforehand. Try installing libjpeg.
sudo apt-get install libjpeg-dev
If you look at the External Libraries section of the Pillow docs, you'll see that there are a number of libraries that should be present, including libjpeg and zlib. If you don't want JPEG support, you should download the "source" archive from PyPI, unzip it, then in the resulting directory run python setup.py install --disable-jpeg.
However, I wouldn't recommend this, as you won't be able to process JPEGs with Pillow. Instead, use the package manager on your Pi to install all of the libraries for which you'd like support, then re-run pip install pillow.
I m trying to install pgmagick library on windows. I m following the official page:
http://pypi.python.org/pypi/pgmagick/
From there i can notice that i need to install first easy_install,pip, boost and graphicsMagic.
In this page i found easy_install:
http://blog.troygrosfield.com/2010/12/18/installing-easy_install-and-pip-for-python/
In this page i can find pip and boost:
http://www.lfd.uci.edu/~gohlke/pythonlibs/#pgmagick
But i can't figure out how to install magick++. I went to website and download it but it installs just the software and when i try to install pgmagick like this:
pip install pgmagick
there is an error that i need magick++:
F:\Python27\Scripts>easy_install -ZU pgmagick
Searching for pgmagick
Reading http://pypi.python.org/simple/pgmagick/
Reading http://bitbucket.org/hhatto/pgmagick
Best match: pgmagick 0.5.4
Downloading http://pypi.python.org/packages/source/p/pgmagick/pgmagick-0.5.4.tar
.gz#md5=c10a454331ac1c359b39e50663fd28e4
Processing pgmagick-0.5.4.tar.gz
Running pgmagick-0.5.4\setup.py -q bdist_egg --dist-dir f:\docume~1\alessa~1\imp
ost~1\temp\easy_install-xaypdo\pgmagick-0.5.4\egg-dist-tmp-qu7mji
Traceback (most recent call last):
File "F:\Python27\Scripts\easy_install-script.py", line 8, in <module>
load_entry_point('setuptools==0.6c11', 'console_scripts', 'easy_install')()
File "F:\Python27\lib\site-packages\setuptools\command\easy_install.py", line
1712, in main
with_ei_usage(lambda:
File "F:\Python27\lib\site-packages\setuptools\command\easy_install.py", line
1700, in with_ei_usage
return f()
File "F:\Python27\lib\site-packages\setuptools\command\easy_install.py", line
1716, in <lambda>
distclass=DistributionWithoutHelpCommands, **kw
File "F:\Python27\lib\distutils\core.py", line 152, in setup
dist.run_commands()
File "F:\Python27\lib\distutils\dist.py", line 953, in run_commands
self.run_command(cmd)
File "F:\Python27\lib\distutils\dist.py", line 972, in run_command
cmd_obj.run()
File "F:\Python27\lib\site-packages\setuptools\command\easy_install.py", line
211, in run
self.easy_install(spec, not self.no_deps)
File "F:\Python27\lib\site-packages\setuptools\command\easy_install.py", line
446, in easy_install
return self.install_item(spec, dist.location, tmpdir, deps)
File "F:\Python27\lib\site-packages\setuptools\command\easy_install.py", line
476, in install_item
dists = self.install_eggs(spec, download, tmpdir)
File "F:\Python27\lib\site-packages\setuptools\command\easy_install.py", line
655, in install_eggs
return self.build_and_install(setup_script, setup_base)
File "F:\Python27\lib\site-packages\setuptools\command\easy_install.py", line
930, in build_and_install
self.run_setup(setup_script, setup_base, args)
File "F:\Python27\lib\site-packages\setuptools\command\easy_install.py", line
919, in run_setup
run_setup(setup_script, args)
File "F:\Python27\lib\site-packages\setuptools\sandbox.py", line 62, in run_se
tup
lambda: execfile(
File "F:\Python27\lib\site-packages\setuptools\sandbox.py", line 105, in run
return func()
File "F:\Python27\lib\site-packages\setuptools\sandbox.py", line 64, in <lambd
a>
{'__file__':setup_script, '__name__':'__main__'}
File "setup.py", line 74, in <module>
Exception: Magick++ not found
thanks!
I recommend you use the precompiled binary packages from the Unofficial Windows Binaries for Python Extension Packages (as mentioned in the pgmagick web page), instead of trying to compile from source which will be quite a complicated process.