首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >在anaconda中安装包gcc-7时出错

在anaconda中安装包gcc-7时出错
EN

Stack Overflow用户
提问于 2019-02-17 14:55:29
回答 1查看 1.5K关注 0票数 1

我正在设置一个新的服务器,并且想安装gcc-5/6/7。我没有超级用户访问服务器的权限,所以我选择了occurred.Does来安装我自己的env.However,一些错误有occurred.Does谁知道如何解决它们吗?

我运行了命令"conda install -v -c quantstack gcc-7“

输出如下所示:

发生意外错误。

请考虑将以下信息发布到

conda GitHub问题跟踪器位于:

代码语言:javascript
复制
https://github.com/conda/conda/issues                                                                                                                                                                            

当前conda安装:

代码语言:javascript
复制
           platform : linux-64                                                                                                                                                                                   
      conda version : 4.3.30                                                                                                                                                                                     
   conda is private : False                                                                                                                                                                                      
  conda-env version : 4.3.30                                                                                                                                                                                     
conda-build version : 3.10.5                                                                                                                                                                                     
     python version : 3.6.5.final.0                                                                                                                                                                              
   requests version : 2.18.4                                                                                                                                                                                     
   root environment : /mnt/lustre/heyue/anaconda3  (writable)                                                                                                                                                    
default environment : /mnt/lustre/heyue/anaconda3/envs/pytorch_1_0                                                                                                                                               
   envs directories : /mnt/lustre/heyue/anaconda3/envs                                                                                                                                                           
                      /home/heyue/.conda/envs                                                                                                                                                                    
      package cache : /mnt/lustre/heyue/anaconda3/pkgs                                                                                                                                                           
                      /home/heyue/.conda/pkgs                                                                                                                                                                    
       channel URLs : https://conda.anaconda.org/quantstack/linux-64                                                                                                                                             
                      https://conda.anaconda.org/quantstack/noarch                                                                                                                                               
                      https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/menpo/linux-64                                                                                                                         
                      https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/menpo/noarch                                                                                                                           
                      https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2/linux-64                                                                                                                         
                      https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2/noarch                                                                                                                           
                      https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/linux-64                                                                                                                   
                      https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/noarch                                                                                                                     
                      https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch/linux-64                                                                                                                       
                      https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch/noarch                                                                                                                         
                      https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/linux-64                                                                                                                           
                      https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/noarch                                                                                                                             
                      https://repo.continuum.io/pkgs/main/linux-64                                                                                                                                               
                      https://repo.continuum.io/pkgs/main/noarch                                                                                                                                                 
                      https://repo.continuum.io/pkgs/free/linux-64                                                                                                                                               
                      https://repo.continuum.io/pkgs/free/noarch                                                                                                                                                 
                      https://repo.continuum.io/pkgs/r/linux-64                                                                                                                                                  
                      https://repo.continuum.io/pkgs/r/noarch                                                                                                                                                    
                      https://repo.continuum.io/pkgs/pro/linux-64                                                                                                                                                
                      https://repo.continuum.io/pkgs/pro/noarch                                                                                                                                                  
        config file : /home/heyue/.condarc                                                                                                                                                                       
         netrc file : None                                                                                                                                                                                       
       offline mode : False                                                                                                                                                                                      
         user-agent : conda/4.3.30 requests/2.18.4 CPython/3.6.5 Linux/3.10.0-327.36.3.el7.x86_64 CentOS Linux/7.2.1511 glibc/2.17                                                                               
            UID:GID : 15665:15665                                                                                                                                                                                

$ /mnt/lustre/heyue/anaconda3/envs/pytorch_1_0/bin/conda install -v -c quantstack gcc-7

代码语言:javascript
复制
Traceback (most recent call last):                                                                                                                                                                               
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/core/link.py", line 497, in run_script                                                                                                     
    subprocess_call(command_args, env=env, path=dirname(path))                                                                                                                                                   
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/gateways/subprocess.py", line 56, in subprocess_call                                                                                       
    output=_format_output(command_str, path, rc, stdout, stderr))                                                                                                                                                
subprocess.CalledProcessError: Command '['/bin/bash', '-x', '/mnt/lustre/heyue/anaconda3/envs/pytorch_1_0/bin/.gcc-7-post-link.sh']' returned non-zero exit status 2.                                            

During handling of the above exception, another exception occurred:                                                                                                                                              

Traceback (most recent call last):                                                                                                                                                                               
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/core/link.py", line 327, in _execute_actions                                                                                               
    run_script(target_prefix, Dist(pkg_data), 'post-unlink' if is_unlink else 'post-link')                                                                                                                       
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/core/link.py", line 513, in run_script                                                                                                     
    raise LinkError(message)                                                                                                                                                                                     
conda.exceptions.LinkError: post-link script failed for package quantstack::gcc-7-7.2.0-2                                                                                                                        
running your command again with `-v` will provide additional information                                                                                                                                         
location of failed script: /mnt/lustre/heyue/anaconda3/envs/pytorch_1_0/bin/.gcc-7-post-link.sh                                                                                                                  
==> script messages <==                                                                                                                                                                                          
<None> 

在处理上述异常的过程中,发生了另一个异常:

代码语言:javascript
复制
Traceback (most recent call last):                                                                                                                                                                               
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/core/link.py", line 281, in execute
    pkg_data, actions)
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/core/link.py", line 344, in _execute_actions
    reverse_excs,
conda.CondaMultiError: post-link script failed for package quantstack::gcc-7-7.2.0-2
running your command again with `-v` will provide additional information
location of failed script: /mnt/lustre/heyue/anaconda3/envs/pytorch_1_0/bin/.gcc-7-post-link.sh
==> script messages <==
<None>

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/exceptions.py", line 640, in conda_exception_handler
    return_value = func(*args, **kwargs)
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/cli/main.py", line 140, in _main
    exit_code = args.func(args, p)
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/cli/main_install.py", line 80, in execute
    install(args, parser, 'install')
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/cli/install.py", line 326, in install
    execute_actions(actions, index, verbose=not context.quiet)
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/plan.py", line 828, in execute_actions
    execute_instructions(plan, index, verbose)
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/instructions.py", line 247, in execute_instructions
    cmd(state, arg)
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/instructions.py", line 108, in UNLINKLINKTRANSACTION_CMD
    txn.execute()
  File "/mnt/lustre/heyue/anaconda3/lib/python3.6/site-packages/conda/core/link.py", line 297, in execute
    rollback_excs,
conda.CondaMultiError: post-link script failed for package quantstack::gcc-7-7.2.0-2
running your command again with `-v` will provide additional information
location of failed script: /mnt/lustre/heyue/anaconda3/envs/pytorch_1_0/bin/.gcc-7-post-link.sh
==> script messages <==
<None>

conda install -v -c quantstack gcc-7

我预计gcc的版本是5或更高。

EN

回答 1

Stack Overflow用户

发布于 2019-11-27 23:11:12

我得到了gcc v7,使用的是miniconda v4.7.12:

代码语言:javascript
复制
conda install -c anaconda gcc_linux-64

更多详细信息请访问:https://www.anaconda.com/utilizing-the-new-compilers-in-anaconda-distribution-5/

https://anaconda.org/anaconda/gcc_linux-64/files

代码语言:javascript
复制
$ x86_64-conda_cos6-linux-gnu-gcc --version
x86_64-conda_cos6-linux-gnu-gcc (crosstool-NG 1.23.0.449-a04d0) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/54730893

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档