我正在尝试在虚拟环境中的RHEL7上安装graph-tool;它同时使用Python3和gcc 7或更高版本。我无法在同一个scl bash shell中同时使用它们。
[root@ ~]# scl enable rh-python36 bash
[root@ ~]# python -V
Python 3.6.3
[root@ ~]# gcc --version | grep gcc
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-44)
[root@ ~]# exit
exit[root@ ~]# scl enable devtoolset-7 bash
[root@ ~]# python -V
Python 2.7.5
[root@ ~]# gcc --version | grep gcc
gcc (GCC) 7.3.1 20180303 (Red Hat 7.3.1-5)有没有办法在第一环境(rh-python36)内更新gcc?
谢谢。
发布于 2021-11-12 15:10:25
我按照以下步骤解决了这个问题:
的虚拟环境
[root@ ~]# source /jupyter/bin/activate
(jupyter) [root@ ~]# which python
/jupyter/bin/python
(jupyter) [root@ ~]# python -V
Python 3.6.3后续支持
(jupyter) [root@ ~]# scl enable devtoolset-7 'bash'
[root@ ~]# python -V
Python 3.6.3
[root@ ~]# gcc --version
gcc (GCC) 7.3.1 20180303 (Red Hat 7.3.1-5)https://stackoverflow.com/questions/69933212
复制相似问题