Gostaria de instalar o python-pyofss [duplicado]

0

Eu tentei seguir as instruções para instalar o pyofss no python, mas recebo o seguinte erro

zeglam@zeglam-Latitude-E6410:~$ pip install pyofss
Downloading/unpacking pyofss
  Downloading pyofss-0.9.tar.gz (69kB): 69kB downloaded
  Running setup.py (path:/tmp/pip_build_zeglam/pyofss/setup.py) egg_info for package pyofss

Requirement already satisfied (use --upgrade to upgrade): numpy>=1.6.2 in /usr/lib/python2.7/dist-packages (from pyofss)
Requirement already satisfied (use --upgrade to upgrade): scipy>=0.10.1 in /usr/lib/python2.7/dist-packages (from pyofss)
Requirement already satisfied (use --upgrade to upgrade): matplotlib>=1.1.0 in /usr/lib/pymodules/python2.7 (from pyofss)
Requirement already satisfied (use --upgrade to upgrade): python-dateutil in /usr/lib/python2.7/dist-packages (from matplotlib>=1.1.0->pyofss)
Downloading/unpacking tornado (from matplotlib>=1.1.0->pyofss)
  Downloading tornado-4.3.tar.gz (450kB): 450kB downloaded
  Running setup.py (path:/tmp/pip_build_zeglam/tornado/setup.py) egg_info for package tornado

    no previously-included directories found matching 'docs/build'
    warning: no files found matching 'tornado/test/README'
Requirement already satisfied (use --upgrade to upgrade): pyparsing>=1.5.6 in /usr/lib/python2.7/dist-packages (from matplotlib>=1.1.0->pyofss)
Downloading/unpacking nose (from matplotlib>=1.1.0->pyofss)
  Downloading nose-1.3.7-py2-none-any.whl (154kB): 154kB downloaded
Downloading/unpacking backports.ssl-match-hostname (from tornado->matplotlib>=1.1.0->pyofss)
  Downloading backports.ssl_match_hostname-3.4.0.2.tar.gz
  Running setup.py (path:/tmp/pip_build_zeglam/backports.ssl-match-hostname/setup.py) egg_info for package backports.ssl-match-hostname

Downloading/unpacking singledispatch (from tornado->matplotlib>=1.1.0->pyofss)
  Downloading singledispatch-3.4.0.3-py2.py3-none-any.whl
Downloading/unpacking certifi (from tornado->matplotlib>=1.1.0->pyofss)
  Downloading certifi-2015.9.6.2-py2.py3-none-any.whl (371kB): 371kB downloaded
Downloading/unpacking backports-abc>=0.4 (from tornado->matplotlib>=1.1.0->pyofss)
  Downloading backports_abc-0.4-py2.py3-none-any.whl
Requirement already satisfied (use --upgrade to upgrade): six in /usr/local/lib/python2.7/dist-packages (from singledispatch->tornado->matplotlib>=1.1.0->pyofss)
Installing collected packages: pyofss, tornado, nose, backports.ssl-match-hostname, singledispatch, certifi, backports-abc
  Running setup.py install for pyofss

    error: could not create '/usr/local/lib/python2.7/dist-packages/pyofss': Permission denied
    Complete output from command /usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip_build_zeglam/pyofss/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-eK437w-record/install-record.txt --single-version-externally-managed --compile:
    running install

running build

running build_py

creating build

creating build/lib.linux-x86_64-2.7

creating build/lib.linux-x86_64-2.7/pyofss

copying pyofss/system.py -> build/lib.linux-x86_64-2.7/pyofss

copying pyofss/metrics.py -> build/lib.linux-x86_64-2.7/pyofss

copying pyofss/domain.py -> build/lib.linux-x86_64-2.7/pyofss

copying pyofss/field.py -> build/lib.linux-x86_64-2.7/pyofss

copying pyofss/__init__.py -> build/lib.linux-x86_64-2.7/pyofss

creating build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/cw.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/gaussian.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/stepper.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/nonlinearity.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/plotter.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/sech.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/fibre.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/bit.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/storage.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/solver.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/filter.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/amplifier.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/__init__.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/generator.py -> build/lib.linux-x86_64-2.7/pyofss/modules

copying pyofss/modules/linearity.py -> build/lib.linux-x86_64-2.7/pyofss/modules

creating build/lib.linux-x86_64-2.7/pyofss/tests

copying pyofss/tests/test_filter.py -> build/lib.linux-x86_64-2.7/pyofss/tests

copying pyofss/tests/test_nonlinearity.py -> build/lib.linux-x86_64-2.7/pyofss/tests

copying pyofss/tests/test_stepper.py -> build/lib.linux-x86_64-2.7/pyofss/tests

copying pyofss/tests/test_gaussian.py -> build/lib.linux-x86_64-2.7/pyofss/tests

copying pyofss/tests/test_linearity.py -> build/lib.linux-x86_64-2.7/pyofss/tests

copying pyofss/tests/test_domain.py -> build/lib.linux-x86_64-2.7/pyofss/tests

copying pyofss/tests/test_sech.py -> build/lib.linux-x86_64-2.7/pyofss/tests

copying pyofss/tests/test_fibre.py -> build/lib.linux-x86_64-2.7/pyofss/tests

copying pyofss/tests/test_solver.py -> build/lib.linux-x86_64-2.7/pyofss/tests

copying pyofss/tests/__init__.py -> build/lib.linux-x86_64-2.7/pyofss/tests

running egg_info

writing requirements to pyofss.egg-info/requires.txt

writing pyofss.egg-info/PKG-INFO

writing top-level names to pyofss.egg-info/top_level.txt

writing dependency_links to pyofss.egg-info/dependency_links.txt

warning: manifest_maker: standard file '-c' not found



reading manifest file 'pyofss.egg-info/SOURCES.txt'

reading manifest template 'MANIFEST.in'

writing manifest file 'pyofss.egg-info/SOURCES.txt'

running install_lib

creating /usr/local/lib/python2.7/dist-packages/pyofss

error: could not create '/usr/local/lib/python2.7/dist-packages/pyofss': Permission denied

----------------------------------------
Cleaning up...
Command /usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip_build_zeglam/pyofss/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-eK437w-record/install-record.txt --single-version-externally-managed --compile failed with error code 1 in /tmp/pip_build_zeglam/pyofss
Storing debug log for failure in /tmp/tmpa4SUaw
    
por MOHAMED BEN ZEGLAM 11.11.2015 / 00:23

1 resposta

1

Você está tentando usar pip fora de um virtualenv. Isso significa que ele tentará instalar coisas nos pacotes globais do site que são de propriedade do root. Duas opções:

  • Mude para fazer as coisas de um modo virtual, o que o seu usuário possui. Isso geralmente é mais seguro porque você não vai sobrescrever arquivos de propriedade do sistema.

    sudo apt-get install python-virtualenv
    virtuanev venv
    source ./venv/bin/activate
    pip install -U pip  # gets a better version of pip!
    pip install pyofss
    
  • Execute seu comando pip como root:

    sudo apt install python-numpy python-scipy python-matplotlib
    sudo pip install pyofss
    
por Oli 11.11.2015 / 00:40

Tags