Mac上Python3.6.1安装Python-rrdtool问题

46 篇文章 0 订阅
10 篇文章 0 订阅

请问:各位Python大神,我在MAC上安装Python-rrdtool一直报错如下

(env3) [MrYang:python-rrdtool-1.4.7]$ pip install python-rrdtool
Looking in indexes: http://mirrors.aliyun.com/pypi/simple/
Collecting python-rrdtool
  Downloading http://mirrors.aliyun.com/pypi/packages/99/af/bf46df3104d78591f942278467a1016d056a887c808ed1127207a4e1ebaf/python-rrdtool-1.4.7.tar.gz (1.4MB)
    100% |████████████████████████████████| 1.4MB 11.9MB/s
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/private/var/folders/dx/m2t9qg010gg9pk5v8xzt4gxc0000gn/T/pip-install-xcrz5haf/python-rrdtool/setup.py", line 61
        os.chmod(executable, 0777)
                                ^
    SyntaxError: invalid token

    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /private/var/folders/dx/m2t9qg010gg9pk5v8xzt4gxc0000gn/T/pip-install-xcrz5haf/python-rrdtool/
(env3) [MrYang:python-rrdtool-1.4.7]$ python -V
Python 3.6.1
(env3) [MrYang:python-rrdtool-1.4.7]$ 

改为手动安装后,报错如下

(env3) [MrYang:python-rrdtool-1.4.7]$ python -V
Python 3.6.1
(env3) [MrYang:python-rrdtool-1.4.7]$ python setup.py install
running install
running build
running build_ext
running build_configure
checking build system type... i386-apple-darwin15.6.0
checking host system type... i386-apple-darwin15.6.0
checking target system type... i386-apple-darwin15.6.0
checking for gcc... gcc
checking for C compiler default output file name...
configure: error: in `/Users/MrYang/Downloads/python-rrdtool-1.4.7/rrdtool-1.4.7':
configure: error: C compiler cannot create executables
See `config.log' for more details.
Traceback (most recent call last):
  File "setup.py", line 99, in <module>
    include_dirs=[include_dir],
  File "/usr/local/lib/python3.6/distutils/core.py", line 148, in setup
    dist.run_commands()
  File "/usr/local/lib/python3.6/distutils/dist.py", line 955, in run_commands
    self.run_command(cmd)
  File "/usr/local/lib/python3.6/distutils/dist.py", line 974, in run_command
    cmd_obj.run()
  File "/usr/local/lib/python3.6/distutils/command/install.py", line 545, in run
    self.run_command('build')
  File "/usr/local/lib/python3.6/distutils/cmd.py", line 313, in run_command
    self.distribution.run_command(command)
  File "/usr/local/lib/python3.6/distutils/dist.py", line 974, in run_command
    cmd_obj.run()
  File "/usr/local/lib/python3.6/distutils/command/build.py", line 135, in run
    self.run_command(cmd_name)
  File "/usr/local/lib/python3.6/distutils/cmd.py", line 313, in run_command
    self.distribution.run_command(command)
  File "/usr/local/lib/python3.6/distutils/dist.py", line 974, in run_command
    cmd_obj.run()
  File "setup.py", line 68, in run
    self.run_command(cmd_name)
  File "/usr/local/lib/python3.6/distutils/cmd.py", line 313, in run_command
    self.distribution.run_command(command)
  File "/usr/local/lib/python3.6/distutils/dist.py", line 974, in run_command
    cmd_obj.run()
  File "setup.py", line 62, in run
    subprocess.check_call(executable, cwd=os.path.dirname(executable))
  File "/usr/local/lib/python3.6/subprocess.py", line 291, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '/Users/MrYang/Downloads/python-rrdtool-1.4.7/rrdtool-1.4.7/configure' returned non-zero exit status 77.
(env3) [MrYang:python-rrdtool-1.4.7]$

请问各位大神对于这种问题该如何解决?

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值