所以我刚刚将我在Cygwin上的gcc安装从v5.3.0更新到v5.4.0。我确保也更新gcc-core。现在,当我尝试编译一个非常简单的代码时,我得到以下错误:
In file included from /usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/x86_64-pc-cygwin/bits/stdc++.h:41:0,
from /cygdrive/c/Users/Mehdi/Documents/ClionProjects/Playground/main.cpp:1:
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1073:11: error: '::acoshl' has not been declared
using ::acoshl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1077:11: error: '::asinhl' has not been declared
using ::asinhl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1081:11: error: '::atanhl' has not been declared
using ::atanhl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1085:11: error: '::cbrtl' has not been declared
using ::cbrtl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1089:11: error: '::copysignl' has not been declared
using ::copysignl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1093:11: error: '::erfl' has not been declared
using ::erfl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1097:11: error: '::erfcl' has not been declared
using ::erfcl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1101:11: error: '::exp2l' has not been declared
using ::exp2l;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1105:11: error: '::expm1l' has not been declared
using ::expm1l;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1109:11: error: '::fdiml' has not been declared
using ::fdiml;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1113:11: error: '::fmal' has not been declared
using ::fmal;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1117:11: error: '::fmaxl' has not been declared
using ::fmaxl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1121:11: error: '::fminl' has not been declared
using ::fminl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1129:11: error: '::ilogbl' has not been declared
using ::ilogbl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1133:11: error: '::lgammal' has not been declared
using ::lgammal;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1137:11: error: '::llrintl' has not been declared
using ::llrintl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1141:11: error: '::llroundl' has not been declared
using ::llroundl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1145:11: error: '::log1pl' has not been declared
using ::log1pl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1149:11: error: '::log2l' has not been declared
using ::log2l;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1153:11: error: '::logbl' has not been declared
using ::logbl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1157:11: error: '::lrintl' has not been declared
using ::lrintl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1161:11: error: '::lroundl' has not been declared
using ::lroundl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1165:11: error: '::nanl' has not been declared
using ::nanl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1169:11: error: '::nearbyintl' has not been declared
using ::nearbyintl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1173:11: error: '::nextafterl' has not been declared
using ::nextafterl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1175:11: error: '::nexttoward' has not been declared
using ::nexttoward;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1176:11: error: '::nexttowardf' has not been declared
using ::nexttowardf;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1177:11: error: '::nexttowardl' has not been declared
using ::nexttowardl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1181:11: error: '::remainderl' has not been declared
using ::remainderl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1185:11: error: '::remquol' has not been declared
using ::remquol;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1189:11: error: '::rintl' has not been declared
using ::rintl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1193:11: error: '::roundl' has not been declared
using ::roundl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1197:11: error: '::scalblnl' has not been declared
using ::scalblnl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1201:11: error: '::scalbnl' has not been declared
using ::scalbnl;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1205:11: error: '::tgammal' has not been declared
using ::tgammal;
^
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/cmath:1209:11: error: '::truncl' has not been declared
using ::truncl;
我没有尝试完全删除Cygwin并重新安装所有内容,因为我认为这是一个非常糟糕的最后努力。我真的不认为编辑cmath删除所有那些“使用”将是一个好主意,因为它可能导致不可预测的行为或更多的编译错误。那么......出了什么问题?
答案 0 :(得分:1)
尝试@matzeri的建议:只需安装cygwin-devel
在尝试构建YouCompleteMe
时尝试编译Boost库时也出现了同样的错误。另外GCC 5.4.0 - 10分钟前安装。安装cygwin-devel为我修复了这个确切的错误。
不幸的是,我刚刚得到一个关于LONG_BIT definition
错误的新内容,但这是另一个问题......