Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

__float128 is not supported on this target

I am trying to install sentry server on windows via cygwin. While installing it , it fails with the error:

/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/type_traits:311:39: error: __float128 is not supported on this target
struct __is_floating_point_helper<__float128>
                                  ^

Now on investigating it, I found out that it is relates to the issue of clang supporting the '__float128' on only select target, i.e Before 3.9.0 clang did not support __float128 and prior to 3.9.0 it was defining a type alias as a workaround.

Starting with 3.9.0 clang implemented native __float128 support and the alias workaround was removed. The only targets supporting __float128 at this moment are linux x86_64 and i686

Hence my question, Is there any solution to make this error go away ?

like image 551
Abhishek Choudhery Avatar asked Apr 10 '17 06:04

Abhishek Choudhery


1 Answers

In my cygwin64,

$ grep -r _GLIBCXX_USE_FLOAT128 /usr /lib
/usr/include/boost/config/compiler/gcc.hpp:#if defined(_GLIBCXX_USE_FLOAT128) && !defined(__STRICT_ANSI__)
/usr/include/boost/math/tools/config.hpp:#if defined(_GLIBCXX_USE_FLOAT128) && defined(BOOST_GCC) && !defined(__STRICT_ANSI__) \
/usr/include/boost/multiprecision/detail/number_base.hpp:#if defined(_GLIBCXX_USE_FLOAT128) && defined(BOOST_GCC) && !defined(__STRICT_ANSI__)
/usr/lib/gcc/x86_64-pc-cygwin/6.3.0/include/c++/x86_64-pc-cygwin/bits/c++config.h:#define _GLIBCXX_USE_FLOAT128 1
/lib/gcc/x86_64-pc-cygwin/6.3.0/include/c++/type_traits:#if !defined(__STRICT_ANSI__) && defined(_GLIBCXX_USE_FLOAT128)
/lib/gcc/x86_64-pc-cygwin/6.3.0/include/c++/x86_64-pc-cygwin/bits/c++config.h:#define _GLIBCXX_USE_FLOAT128 1

So, change value of _GLIBCXX_USE_FLOAT128 won't help, because other macro checks its existence, not value.

The solution is removing a line containing _GLIBCXX_USE_FLOAT128 from c++config.h.

like image 135
Byoungchan Lee Avatar answered Nov 19 '22 18:11

Byoungchan Lee