gpt4 book ai didi

clang - 如何在 CentOS 7 上安装 Clang 和 LLVM 3.9

转载 作者:行者123 更新时间:2023-12-04 01:17:50 38 4
gpt4 key购买 nike

我已经从
https://copr-be.cloud.fedoraproject.org/results/alonid/llvm-3.9.0/epel-7-x86_64/00505197-clang-3.9.0/对于 Clang 3.9。

我正在通过命令安装 rpm 包

rpm -ivh clang-3.9.0-3.9.0-3.1.el7.centos.alonid.src.rpm

但是当我这样做时
rpm -ivh clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64.rpm

我收到以下错误:
error: Failed dependencies:
clang-3.9.0-libs(x86-64) = 3.9.0-3.1.el7.centos.alonid is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libLLVM-3.9.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclang.so.3.9()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangAST.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangBasic.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangCodeGen.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangDriver.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangFormat.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangFrontend.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangFrontendTool.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangIndex.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangRewrite.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangRewriteFrontend.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangStaticAnalyzerFrontend.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangTooling.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64
libclangToolingCore.so()(64bit) is needed by clang-3.9.0-3.9.0-3.1.el7.centos.alonid.x86_64

我应该从哪里安装所有这些依赖项?

最佳答案

通过启用 SCL 存储库,您可以使用 llvm-toolset-7 在 CentOS 7 上安装 Clang 5.0.1包。

$ sudo yum install centos-release-scl
$ sudo yum install llvm-toolset-7

启用 llvm-toolset-7 :
$ scl enable llvm-toolset-7 bash

您现在可以使用以下命令检查 clang 版本:
$ clang --version

看到这个 Red Hat blog post了解更多信息。

有关 SCL 的更多信息,请参阅 this page .

关于clang - 如何在 CentOS 7 上安装 Clang 和 LLVM 3.9,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44219158/

38 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com