<small id='CunMx'></small><noframes id='CunMx'>

<tfoot id='CunMx'></tfoot>
  • <legend id='CunMx'><style id='CunMx'><dir id='CunMx'><q id='CunMx'></q></dir></style></legend>
      <bdo id='CunMx'></bdo><ul id='CunMx'></ul>

        <i id='CunMx'><tr id='CunMx'><dt id='CunMx'><q id='CunMx'><span id='CunMx'><b id='CunMx'><form id='CunMx'><ins id='CunMx'></ins><ul id='CunMx'></ul><sub id='CunMx'></sub></form><legend id='CunMx'></legend><bdo id='CunMx'><pre id='CunMx'><center id='CunMx'></center></pre></bdo></b><th id='CunMx'></th></span></q></dt></tr></i><div id='CunMx'><tfoot id='CunMx'></tfoot><dl id='CunMx'><fieldset id='CunMx'></fieldset></dl></div>
      1. 启用 openmp 时出错 - “ld: library not found for -lgomp

        时间:2023-09-19
        <legend id='sHGBv'><style id='sHGBv'><dir id='sHGBv'><q id='sHGBv'></q></dir></style></legend>

            <bdo id='sHGBv'></bdo><ul id='sHGBv'></ul>
                  <tbody id='sHGBv'></tbody>

                <i id='sHGBv'><tr id='sHGBv'><dt id='sHGBv'><q id='sHGBv'><span id='sHGBv'><b id='sHGBv'><form id='sHGBv'><ins id='sHGBv'></ins><ul id='sHGBv'></ul><sub id='sHGBv'></sub></form><legend id='sHGBv'></legend><bdo id='sHGBv'><pre id='sHGBv'><center id='sHGBv'></center></pre></bdo></b><th id='sHGBv'></th></span></q></dt></tr></i><div id='sHGBv'><tfoot id='sHGBv'></tfoot><dl id='sHGBv'><fieldset id='sHGBv'></fieldset></dl></div>
                <tfoot id='sHGBv'></tfoot>

                  <small id='sHGBv'></small><noframes id='sHGBv'>

                1. 本文介绍了启用 openmp 时出错 - “ld: library not found for -lgomp"和 Clang 错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  我正在尝试让 openmp 在我的 Mavericks 程序中运行,但是当我尝试使用标志 -fopenmp 进行编译时,我收到以下错误:

                  I'm trying to get openmp to run in my program on Mavericks, however when I try to compile using the flag -fopenmp I get the following error:

                  ld: library not found for -lgomp
                  clang: error: linker command failed with exit code 1 (use -v to see invocation)
                  

                  我正在运行的命令是:

                  gcc myProgram.cpp -fopenmp -o myProgram
                  

                  此外,当我运行 gcc 时,我会收到 Clang 警告,我觉得这很奇怪.并且查看/usr/bin/gcc 它似乎没有链接到 Clang.

                  Also, when I run gcc I get Clang warnings which I find to be very strange. And looking into /usr/bin/gcc it does not appear to link to Clang.

                  关于如何修复我的 Clang 错误并让 openmp 编译的任何建议?

                  Any suggestions on how to fix my Clang errors and get openmp to compile?

                  推荐答案

                  最新 Xcode 套件中的 gcc 命令不再是 LLVM 的 GCC 前端(基于非常旧的 GCC 4.2.1) 而是指向 clang 的符号链接.Clang(尚)不支持 OpenMP.您必须单独安装另一个版本的 GCC,例如通过遵循本教程或使用任何可用的软件包管理系统,如 MacPorts 和 家酿.

                  The gcc command in the latest Xcode suite is no longer the GCC frontend to LLVM (based on the very old GCC 4.2.1) but rather a symlink to clang. Clang does not (yet) support OpenMP. You have to install separately another version of GCC, e.g. by following this tutorial or by using any of the available software package management systems like MacPorts and Homebrew.

                  这篇关于启用 openmp 时出错 - “ld: library not found for -lgomp"和 Clang 错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:如果忽略返回值,如何发出警告? 下一篇:gcc:未定义的引用

                  相关文章

                  最新文章

                  <small id='uYZ78'></small><noframes id='uYZ78'>

                      <bdo id='uYZ78'></bdo><ul id='uYZ78'></ul>
                    <legend id='uYZ78'><style id='uYZ78'><dir id='uYZ78'><q id='uYZ78'></q></dir></style></legend>

                    <i id='uYZ78'><tr id='uYZ78'><dt id='uYZ78'><q id='uYZ78'><span id='uYZ78'><b id='uYZ78'><form id='uYZ78'><ins id='uYZ78'></ins><ul id='uYZ78'></ul><sub id='uYZ78'></sub></form><legend id='uYZ78'></legend><bdo id='uYZ78'><pre id='uYZ78'><center id='uYZ78'></center></pre></bdo></b><th id='uYZ78'></th></span></q></dt></tr></i><div id='uYZ78'><tfoot id='uYZ78'></tfoot><dl id='uYZ78'><fieldset id='uYZ78'></fieldset></dl></div>
                    <tfoot id='uYZ78'></tfoot>