flens lapack:需要 GNU GCC 版本 4.7 或更高版本!我的 mac 有
flens lapack: GNU GCC Version 4.7 or higher required! my mac has
我正在尝试 FLENS-LAPACK 的教程 (http://apfel.mathematik.uni-ulm.de/~lehn/FLENS/flens/examples/lapack-geqp3.html)。
我已经从网站 (https://github.com/michael-lehn/FLENS) 下载了 src 代码。
当我尝试教程中的说明时
g++ -std=c++11 -Wall -I../.. -o lapack-geqp3 lapack-geqp3.cc
我从控制台收到错误消息:
In file included from lapack-geqp3.cc:2:0:
../../flens/flens.cxx:45:6: error: static assertion failed:
GNU GCC Version 4.7 or higher required! static_assert(__GNUG__>=4 && __GNUC_MINOR__>=7,
我检查了 mac
的 gcc 版本
$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/x86_64-apple-darwin14.0.0/5.0.0/lto-wrapper Target: x86_64-apple-darwin14.0.0
Configured with: ../gcc-5-20141005/configure --enable-languages=c++,fortran Thread model: posix
gcc version 5.0.0 20141005 (experimental) (GCC)
显示我的mac有gcc 5.0.0。
谁能告诉我 mac 上的 gcc 有什么问题??
非常感谢!!
注意你的 GCC 有问题,static_assert
是错误的。
static_assert(__GNUG__>=4 && __GNUC_MINOR__>=7, ...)
这会检查 GCC 是否为 4.x 或更新版本,也是 次要版本 7 或更新版本。这个断言只会在 4.7, 4.8, 4.9, 5.7, 5.8, ... 等等
如果断言像这样改变:
static_assert(__GNUG__==4 && __GNUC_MINOR__>=7 || __GNUG__>4, ...)
那么它应该通过 GCC 5(假设它将 __GNUG__
定义为 5;我目前无法检查。)
编辑:我已 submitted a patch 修复此问题,该问题已被接受并合并。如果您拉出最新的 HEAD,您的问题应该得到解决。
我正在尝试 FLENS-LAPACK 的教程 (http://apfel.mathematik.uni-ulm.de/~lehn/FLENS/flens/examples/lapack-geqp3.html)。 我已经从网站 (https://github.com/michael-lehn/FLENS) 下载了 src 代码。
当我尝试教程中的说明时
g++ -std=c++11 -Wall -I../.. -o lapack-geqp3 lapack-geqp3.cc
我从控制台收到错误消息:
In file included from lapack-geqp3.cc:2:0: ../../flens/flens.cxx:45:6: error: static assertion failed: GNU GCC Version 4.7 or higher required! static_assert(__GNUG__>=4 && __GNUC_MINOR__>=7,
我检查了 mac
的 gcc 版本$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/x86_64-apple-darwin14.0.0/5.0.0/lto-wrapper Target: x86_64-apple-darwin14.0.0
Configured with: ../gcc-5-20141005/configure --enable-languages=c++,fortran Thread model: posix
gcc version 5.0.0 20141005 (experimental) (GCC)
显示我的mac有gcc 5.0.0。 谁能告诉我 mac 上的 gcc 有什么问题?? 非常感谢!!
注意你的 GCC 有问题,static_assert
是错误的。
static_assert(__GNUG__>=4 && __GNUC_MINOR__>=7, ...)
这会检查 GCC 是否为 4.x 或更新版本,也是 次要版本 7 或更新版本。这个断言只会在 4.7, 4.8, 4.9, 5.7, 5.8, ... 等等
如果断言像这样改变:
static_assert(__GNUG__==4 && __GNUC_MINOR__>=7 || __GNUG__>4, ...)
那么它应该通过 GCC 5(假设它将 __GNUG__
定义为 5;我目前无法检查。)
编辑:我已 submitted a patch 修复此问题,该问题已被接受并合并。如果您拉出最新的 HEAD,您的问题应该得到解决。