Tobias Hieta via llvm-dev
2018-Feb-06 08:51 UTC
[llvm-dev] libc++ cross-compile linux-armv7 and math function problems
Hello,
I am trying to cross-compile libc++ from my x86_64 linux system to armv7hf.
We have our own gcc compiler that we build with crosstools-ng (based on gcc
6.3.0) and I set my environment like this:
CC=armv7a-plex-linux-gnueabihf-gcc
CXX=armv7a-plex-linux-gnueabihf-g++
CFLAGS=-fPIC -DPIC -mfloat-abi=hard -march=armv7-a -Os -mfpu=vfpv3-d16
--sysroot=<path>
CXXFLAGS=-fPIC -DPIC -mfloat-abi=hard -march=armv7-a -Os -mfpu=vfpv3-d16
--sysroot=<path>
LDFLAGS=-static-libgcc --sysroot=<path>
then run cmake:
cmake -GNinja -DLIBCXXABI_USE_LLVM_UNWINDER=ON DLLVM_TARGET_ARCH=ARM
-DLLVM_DEFAULT_TARGET_TRIPLE=arm-linux-gnueabihf
-DLLVM_TARGETS_TO_BUILD=ARM -DCMAKE_CROSSCOMPILING=True ..
This errors out as shown below. It's like it's missing some definitions
of
different math functions that I can't seem to be able to see anywhere else.
Is this a known problem? Or is it something with my compiler / toolchain
setup that creates this problem?
Thanks for any assistance.
-- Tobias
armv7a-plex-linux-gnueabihf-g++ -DLLVM_BUILD_GLOBAL_ISEL -DNDEBUG -D_DEBUG
-D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -D_LARGEFILE_SOURCE
-D_LIBCPP_BUILDING_LIBRARY -D_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER
-D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS
-Iprojects/libcxx/lib -I../projects/libcxx/lib -Iinclude -I../include
-Iprojects/libcxx/include/c++build -I../projects/libcxx/include -fPIC -DPIC
-mfloat-abi=hard -march=armv7-a -Os -mfpu=vfpv3-d16
--sysroot=armv7a-plex-linux-gnueabihf/sysroot -fPIC
-fvisibility-inlines-hidden -Werror=date-time -std=c++11 -Wall -W
-Wno-unused-parameter -Wwrite-strings -Wcast-qual
-Wno-missing-field-initializers
-Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor
-Wno-comment -g -DLIBCXX_BUILDING_LIBCXXABI -std=c++11 -nostdinc++
-fvisibility-inlines-hidden -Wall -Wextra -W -Wwrite-strings
-Wno-unused-parameter -Wno-long-long -Werror=return-type
-Wno-literal-suffix -Wno-c++14-compat -Wno-noexcept-type -Wno-error -fPIC
-MD -MT projects/libcxx/lib/CMakeFiles/cxx_objects.dir/__/src/algorithm.cpp.o
-MF projects/libcxx/lib/CMakeFiles/cxx_objects.dir/__/src/algorithm.cpp.o.d
-o projects/libcxx/lib/CMakeFiles/cxx_objects.dir/__/src/algorithm.cpp.o -c
../projects/libcxx/src/algorithm.cpp
In file included from ../projects/libcxx/include/cmath:305:0,
from ../projects/libcxx/include/random:1638,
from ../projects/libcxx/src/algorithm.cpp:11:
../projects/libcxx/include/math.h: In function 'long double abs(long
double)':
../projects/libcxx/include/math.h:742:45: error: '::fabsl' has not been
declared
abs(long double __lcpp_x) _NOEXCEPT {return ::fabsl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double acos(long
double)':
../projects/libcxx/include/math.h:749:91: error: '::acosl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double acos(long double __lcpp_x)
_NOEXCEPT {return ::acosl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double asin(long
double)':
../projects/libcxx/include/math.h:761:91: error: '::asinl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double asin(long double __lcpp_x)
_NOEXCEPT {return ::asinl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double atan(long
double)':
../projects/libcxx/include/math.h:773:91: error: '::atanl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double atan(long double __lcpp_x)
_NOEXCEPT {return ::atanl(__lcpp_x);}
^~
In file included from ../projects/libcxx/include/cmath:305:0,
from ../projects/libcxx/include/random:1638,
from ../projects/libcxx/src/algorithm.cpp:11:
../projects/libcxx/include/math.h: In function 'long double atan2(long
double, long double)':
../projects/libcxx/include/math.h:785:114: error: '::atan2l' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double atan2(long double __lcpp_y,
long double __lcpp_x) _NOEXCEPT {return ::atan2l(__lcpp_y, __lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double ceil(long
double)':
../projects/libcxx/include/math.h:808:91: error: '::ceill' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double ceil(long double __lcpp_x)
_NOEXCEPT {return ::ceill(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double cos(long
double)':
../projects/libcxx/include/math.h:820:90: error: '::cosl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double cos(long double __lcpp_x)
_NOEXCEPT {return ::cosl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double cosh(long
double)':
../projects/libcxx/include/math.h:832:91: error: '::coshl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double cosh(long double __lcpp_x)
_NOEXCEPT {return ::coshl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double exp(long
double)':
../projects/libcxx/include/math.h:844:90: error: '::expl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double exp(long double __lcpp_x)
_NOEXCEPT {return ::expl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double fabs(long
double)':
../projects/libcxx/include/math.h:856:91: error: '::fabsl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double fabs(long double __lcpp_x)
_NOEXCEPT {return ::fabsl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double floor(long
double)':
../projects/libcxx/include/math.h:868:92: error: '::floorl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double floor(long double __lcpp_x)
_NOEXCEPT {return ::floorl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double fmod(long
double, long double)':
../projects/libcxx/include/math.h:880:113: error: '::fmodl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double fmod(long double __lcpp_x,
long double __lcpp_y) _NOEXCEPT {return ::fmodl(__lcpp_x, __lcpp_y);}
^~
../projects/libcxx/include/math.h: In function 'long double frexp(long
double, int*)':
../projects/libcxx/include/math.h:903:107: error: '::frexpl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double frexp(long double __lcpp_x,
int* __lcpp_e) _NOEXCEPT {return ::frexpl(__lcpp_x, __lcpp_e);}
^~
../projects/libcxx/include/math.h: In function 'long double ldexp(long
double, int)':
../projects/libcxx/include/math.h:915:106: error: '::ldexpl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double ldexp(long double __lcpp_x,
int __lcpp_e) _NOEXCEPT {return ::ldexpl(__lcpp_x, __lcpp_e);}
^~
../projects/libcxx/include/math.h: In function 'long double log(long
double)':
../projects/libcxx/include/math.h:927:90: error: '::logl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double log(long double __lcpp_x)
_NOEXCEPT {return ::logl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double log10(long
double)':
../projects/libcxx/include/math.h:939:92: error: '::log10l' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double log10(long double __lcpp_x)
_NOEXCEPT {return ::log10l(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double modf(long
double, long double*)':
../projects/libcxx/include/math.h:951:114: error: '::modfl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double modf(long double __lcpp_x,
long double* __lcpp_y) _NOEXCEPT {return ::modfl(__lcpp_x, __lcpp_y);}
^~
../projects/libcxx/include/math.h: In function 'long double pow(long
double, long double)':
../projects/libcxx/include/math.h:958:112: error: '::powl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double pow(long double __lcpp_x,
long double __lcpp_y) _NOEXCEPT {return ::powl(__lcpp_x, __lcpp_y);}
^~
../projects/libcxx/include/math.h: In function 'long double sin(long
double)':
../projects/libcxx/include/math.h:981:90: error: '::sinl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double sin(long double __lcpp_x)
_NOEXCEPT {return ::sinl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double sinh(long
double)':
../projects/libcxx/include/math.h:993:91: error: '::sinhl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double sinh(long double __lcpp_x)
_NOEXCEPT {return ::sinhl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double sqrt(long
double)':
../projects/libcxx/include/math.h:1005:91: error: '::sqrtl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double sqrt(long double __lcpp_x)
_NOEXCEPT {return ::sqrtl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double tan(long
double)':
../projects/libcxx/include/math.h:1017:90: error: '::tanl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double tan(long double __lcpp_x)
_NOEXCEPT {return ::tanl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double tanh(long
double)':
../projects/libcxx/include/math.h:1029:91: error: '::tanhl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double tanh(long double __lcpp_x)
_NOEXCEPT {return ::tanhl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double acosh(long
double)':
../projects/libcxx/include/math.h:1040:92: error: '::acoshl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double acosh(long double __lcpp_x)
_NOEXCEPT {return ::acoshl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double asinh(long
double)':
../projects/libcxx/include/math.h:1050:92: error: '::asinhl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double asinh(long double __lcpp_x)
_NOEXCEPT {return ::asinhl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double atanh(long
double)':
../projects/libcxx/include/math.h:1060:92: error: '::atanhl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double atanh(long double __lcpp_x)
_NOEXCEPT {return ::atanhl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double cbrt(long
double)':
../projects/libcxx/include/math.h:1070:91: error: '::cbrtl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double cbrt(long double __lcpp_x)
_NOEXCEPT {return ::cbrtl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double copysign(long
double, long double)':
../projects/libcxx/include/math.h:1085:10: error: '::copysignl' has not
been declared
return ::copysignl(__lcpp_x, __lcpp_y);
^~
../projects/libcxx/include/math.h: In function 'long double erf(long
double)':
../projects/libcxx/include/math.h:1107:90: error: '::erfl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double erf(long double __lcpp_x)
_NOEXCEPT {return ::erfl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double erfc(long
double)':
../projects/libcxx/include/math.h:1117:91: error: '::erfcl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double erfc(long double __lcpp_x)
_NOEXCEPT {return ::erfcl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double exp2(long
double)':
../projects/libcxx/include/math.h:1127:91: error: '::exp2l' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double exp2(long double __lcpp_x)
_NOEXCEPT {return ::exp2l(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double expm1(long
double)':
../projects/libcxx/include/math.h:1137:92: error: '::expm1l' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double expm1(long double __lcpp_x)
_NOEXCEPT {return ::expm1l(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double fdim(long
double, long double)':
../projects/libcxx/include/math.h:1147:113: error: '::fdiml' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double fdim(long double __lcpp_x,
long double __lcpp_y) _NOEXCEPT {return ::fdiml(__lcpp_x, __lcpp_y);}
^~
../projects/libcxx/include/math.h: In function 'long double fma(long
double, long double, long double)':
../projects/libcxx/include/math.h:1168:134: error: '::fmal' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double fma(long double __lcpp_x,
long double __lcpp_y, long double __lcpp_z) _NOEXCEPT {return
::fmal(__lcpp_x, __lcpp_y, __lcpp_z);}
^~
../projects/libcxx/include/math.h: In function 'long double fmax(long
double, long double)':
../projects/libcxx/include/math.h:1191:113: error: '::fmaxl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double fmax(long double __lcpp_x,
long double __lcpp_y) _NOEXCEPT {return ::fmaxl(__lcpp_x, __lcpp_y);}
^~
../projects/libcxx/include/math.h: In function 'long double fmin(long
double, long double)':
../projects/libcxx/include/math.h:1212:113: error: '::fminl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double fmin(long double __lcpp_x,
long double __lcpp_y) _NOEXCEPT {return ::fminl(__lcpp_x, __lcpp_y);}
^~
../projects/libcxx/include/math.h: In function 'long double hypot(long
double, long double)':
../projects/libcxx/include/math.h:1233:114: error: '::hypotl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double hypot(long double __lcpp_x,
long double __lcpp_y) _NOEXCEPT {return ::hypotl(__lcpp_x, __lcpp_y);}
^~
../projects/libcxx/include/math.h: In function 'int ilogb(long double)':
../projects/libcxx/include/math.h:1254:84: error: '::ilogbl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY int ilogb(long double __lcpp_x) _NOEXCEPT
{return ::ilogbl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double lgamma(long
double)':
../projects/libcxx/include/math.h:1264:93: error: '::lgammal' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double lgamma(long double __lcpp_x)
_NOEXCEPT {return ::lgammal(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long long int llrint(long
double)':
../projects/libcxx/include/math.h:1274:91: error: '::llrintl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long long llrint(long double __lcpp_x)
_NOEXCEPT {return ::llrintl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long long int llround(long
double)':
../projects/libcxx/include/math.h:1284:92: error: '::llroundl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long long llround(long double __lcpp_x)
_NOEXCEPT {return ::llroundl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double log1p(long
double)':
../projects/libcxx/include/math.h:1294:92: error: '::log1pl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double log1p(long double __lcpp_x)
_NOEXCEPT {return ::log1pl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double log2(long
double)':
../projects/libcxx/include/math.h:1304:91: error: '::log2l' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double log2(long double __lcpp_x)
_NOEXCEPT {return ::log2l(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double logb(long
double)':
../projects/libcxx/include/math.h:1314:91: error: '::logbl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double logb(long double __lcpp_x)
_NOEXCEPT {return ::logbl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long int lrint(long
double)':
../projects/libcxx/include/math.h:1324:85: error: '::lrintl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long lrint(long double __lcpp_x)
_NOEXCEPT {return ::lrintl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long int lround(long
double)':
../projects/libcxx/include/math.h:1334:86: error: '::lroundl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long lround(long double __lcpp_x)
_NOEXCEPT {return ::lroundl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double nearbyint(long
double)':
../projects/libcxx/include/math.h:1346:96: error: '::nearbyintl' has not
been declared
inline _LIBCPP_INLINE_VISIBILITY long double nearbyint(long double
__lcpp_x) _NOEXCEPT {return ::nearbyintl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double nextafter(long
double, long double)':
../projects/libcxx/include/math.h:1356:118: error: '::nextafterl' has
not
been declared
inline _LIBCPP_INLINE_VISIBILITY long double nextafter(long double
__lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::nextafterl(__lcpp_x,
__lcpp_y);}
^~
../projects/libcxx/include/math.h: In function 'long double nexttoward(long
double, long double)':
../projects/libcxx/include/math.h:1377:119: error: '::nexttowardl' has
not
been declared
inline _LIBCPP_INLINE_VISIBILITY long double nexttoward(long double
__lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::nexttowardl(__lcpp_x,
__lcpp_y);}
^~
../projects/libcxx/include/math.h: In function 'long double remainder(long
double, long double)':
../projects/libcxx/include/math.h:1387:118: error: '::remainderl' has
not
been declared
inline _LIBCPP_INLINE_VISIBILITY long double remainder(long double
__lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::remainderl(__lcpp_x,
__lcpp_y);}
^~
../projects/libcxx/include/math.h: In function 'long double remquo(long
double, long double, int*)':
../projects/libcxx/include/math.h:1408:130: error: '::remquol' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double remquo(long double __lcpp_x,
long double __lcpp_y, int* __lcpp_z) _NOEXCEPT {return ::remquol(__lcpp_x,
__lcpp_y, __lcpp_z);}
^~
../projects/libcxx/include/math.h: In function 'long double rint(long
double)':
../projects/libcxx/include/math.h:1429:91: error: '::rintl' has not been
declared
inline _LIBCPP_INLINE_VISIBILITY long double rint(long double __lcpp_x)
_NOEXCEPT {return ::rintl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double round(long
double)':
../projects/libcxx/include/math.h:1439:92: error: '::roundl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double round(long double __lcpp_x)
_NOEXCEPT {return ::roundl(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double scalbln(long
double, long int)':
../projects/libcxx/include/math.h:1449:109: error: '::scalblnl' has not
been declared
inline _LIBCPP_INLINE_VISIBILITY long double scalbln(long double __lcpp_x,
long __lcpp_y) _NOEXCEPT {return ::scalblnl(__lcpp_x, __lcpp_y);}
^~
../projects/libcxx/include/math.h: In function 'long double scalbn(long
double, int)':
../projects/libcxx/include/math.h:1459:107: error: '::scalbnl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double scalbn(long double __lcpp_x,
int __lcpp_y) _NOEXCEPT {return ::scalbnl(__lcpp_x, __lcpp_y);}
^~
../projects/libcxx/include/math.h: In function 'long double tgamma(long
double)':
../projects/libcxx/include/math.h:1469:93: error: '::tgammal' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double tgamma(long double __lcpp_x)
_NOEXCEPT {return ::tgammal(__lcpp_x);}
^~
../projects/libcxx/include/math.h: In function 'long double trunc(long
double)':
../projects/libcxx/include/math.h:1479:92: error: '::truncl' has not
been
declared
inline _LIBCPP_INLINE_VISIBILITY long double trunc(long double __lcpp_x)
_NOEXCEPT {return ::truncl(__lcpp_x);}
^~
In file included from ../projects/libcxx/include/random:1638:0,
from ../projects/libcxx/src/algorithm.cpp:11:
../projects/libcxx/include/cmath: At global scope:
../projects/libcxx/include/cmath:464:9: error: '::acosl' has not been
declared
using ::acosl;
^~~~~
../projects/libcxx/include/cmath:465:9: error: '::asinl' has not been
declared
using ::asinl;
^~~~~
../projects/libcxx/include/cmath:466:9: error: '::atanl' has not been
declared
using ::atanl;
^~~~~
../projects/libcxx/include/cmath:467:9: error: '::atan2l' has not been
declared
using ::atan2l;
^~~~~~
../projects/libcxx/include/cmath:468:9: error: '::ceill' has not been
declared
using ::ceill;
^~~~~
../projects/libcxx/include/cmath:469:9: error: '::cosl' has not been
declared
using ::cosl;
^~~~
../projects/libcxx/include/cmath:470:9: error: '::coshl' has not been
declared
using ::coshl;
^~~~~
../projects/libcxx/include/cmath:471:9: error: '::expl' has not been
declared
using ::expl;
^~~~
../projects/libcxx/include/cmath:472:9: error: '::fabsl' has not been
declared
using ::fabsl;
^~~~~
../projects/libcxx/include/cmath:473:9: error: '::floorl' has not been
declared
using ::floorl;
^~~~~~
../projects/libcxx/include/cmath:474:9: error: '::fmodl' has not been
declared
using ::fmodl;
^~~~~
../projects/libcxx/include/cmath:475:9: error: '::frexpl' has not been
declared
using ::frexpl;
^~~~~~
../projects/libcxx/include/cmath:476:9: error: '::ldexpl' has not been
declared
using ::ldexpl;
^~~~~~
../projects/libcxx/include/cmath:477:9: error: '::logl' has not been
declared
using ::logl;
^~~~
../projects/libcxx/include/cmath:478:9: error: '::log10l' has not been
declared
using ::log10l;
^~~~~~
../projects/libcxx/include/cmath:479:9: error: '::modfl' has not been
declared
using ::modfl;
^~~~~
../projects/libcxx/include/cmath:480:9: error: '::powl' has not been
declared
using ::powl;
^~~~
../projects/libcxx/include/cmath:481:9: error: '::sinl' has not been
declared
using ::sinl;
^~~~
../projects/libcxx/include/cmath:482:9: error: '::sinhl' has not been
declared
using ::sinhl;
^~~~~
../projects/libcxx/include/cmath:483:9: error: '::sqrtl' has not been
declared
using ::sqrtl;
^~~~~
../projects/libcxx/include/cmath:484:9: error: '::tanl' has not been
declared
using ::tanl;
^~~~
../projects/libcxx/include/cmath:486:9: error: '::tanhl' has not been
declared
using ::tanhl;
^~~~~
../projects/libcxx/include/cmath:487:9: error: '::acoshl' has not been
declared
using ::acoshl;
^~~~~~
../projects/libcxx/include/cmath:488:9: error: '::asinhl' has not been
declared
using ::asinhl;
^~~~~~
../projects/libcxx/include/cmath:489:9: error: '::atanhl' has not been
declared
using ::atanhl;
^~~~~~
../projects/libcxx/include/cmath:490:9: error: '::cbrtl' has not been
declared
using ::cbrtl;
^~~~~
../projects/libcxx/include/cmath:492:9: error: '::copysignl' has not
been
declared
using ::copysignl;
^~~~~~~~~
../projects/libcxx/include/cmath:494:9: error: '::erfl' has not been
declared
using ::erfl;
^~~~
../projects/libcxx/include/cmath:495:9: error: '::erfcl' has not been
declared
using ::erfcl;
^~~~~
../projects/libcxx/include/cmath:496:9: error: '::exp2l' has not been
declared
using ::exp2l;
^~~~~
../projects/libcxx/include/cmath:497:9: error: '::expm1l' has not been
declared
using ::expm1l;
^~~~~~
../projects/libcxx/include/cmath:498:9: error: '::fdiml' has not been
declared
using ::fdiml;
^~~~~
../projects/libcxx/include/cmath:499:9: error: '::fmal' has not been
declared
using ::fmal;
^~~~
../projects/libcxx/include/cmath:500:9: error: '::fmaxl' has not been
declared
using ::fmaxl;
^~~~~
../projects/libcxx/include/cmath:501:9: error: '::fminl' has not been
declared
using ::fminl;
^~~~~
../projects/libcxx/include/cmath:502:9: error: '::hypotl' has not been
declared
using ::hypotl;
^~~~~~
../projects/libcxx/include/cmath:503:9: error: '::ilogbl' has not been
declared
using ::ilogbl;
^~~~~~
../projects/libcxx/include/cmath:504:9: error: '::lgammal' has not been
declared
using ::lgammal;
^~~~~~~
../projects/libcxx/include/cmath:505:9: error: '::llrintl' has not been
declared
using ::llrintl;
^~~~~~~
../projects/libcxx/include/cmath:506:9: error: '::llroundl' has not been
declared
using ::llroundl;
^~~~~~~~
../projects/libcxx/include/cmath:507:9: error: '::log1pl' has not been
declared
using ::log1pl;
^~~~~~
../projects/libcxx/include/cmath:508:9: error: '::log2l' has not been
declared
using ::log2l;
^~~~~
../projects/libcxx/include/cmath:509:9: error: '::logbl' has not been
declared
using ::logbl;
^~~~~
../projects/libcxx/include/cmath:510:9: error: '::lrintl' has not been
declared
using ::lrintl;
^~~~~~
../projects/libcxx/include/cmath:511:9: error: '::lroundl' has not been
declared
using ::lroundl;
^~~~~~~
../projects/libcxx/include/cmath:512:9: error: '::nanl' has not been
declared
using ::nanl;
^~~~
../projects/libcxx/include/cmath:513:9: error: '::nearbyintl' has not
been
declared
using ::nearbyintl;
^~~~~~~~~~
../projects/libcxx/include/cmath:514:9: error: '::nextafterl' has not
been
declared
using ::nextafterl;
^~~~~~~~~~
../projects/libcxx/include/cmath:515:9: error: '::nexttowardl' has not
been
declared
using ::nexttowardl;
^~~~~~~~~~~
../projects/libcxx/include/cmath:516:9: error: '::remainderl' has not
been
declared
using ::remainderl;
^~~~~~~~~~
../projects/libcxx/include/cmath:517:9: error: '::remquol' has not been
declared
using ::remquol;
^~~~~~~
../projects/libcxx/include/cmath:518:9: error: '::rintl' has not been
declared
using ::rintl;
^~~~~
../projects/libcxx/include/cmath:519:9: error: '::roundl' has not been
declared
using ::roundl;
^~~~~~
../projects/libcxx/include/cmath:520:9: error: '::scalblnl' has not been
declared
using ::scalblnl;
^~~~~~~~
../projects/libcxx/include/cmath:521:9: error: '::scalbnl' has not been
declared
using ::scalbnl;
^~~~~~~
../projects/libcxx/include/cmath:522:9: error: '::tgammal' has not been
declared
using ::tgammal;
^~~~~~~
../projects/libcxx/include/cmath:523:9: error: '::truncl' has not been
declared
using ::truncl;
^~~~~~
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.llvm.org/pipermail/llvm-dev/attachments/20180206/45c4eb7c/attachment-0001.html>
Dimitry Andric via llvm-dev
2018-Feb-06 10:47 UTC
[llvm-dev] libc++ cross-compile linux-armv7 and math function problems
At first glance, it looks like long double functions (such as fabsl and friends) are missing from your sysroot's <math.h>. Does your target support long double at all? -Dimitry> On 6 Feb 2018, at 09:51, Tobias Hieta via llvm-dev <llvm-dev at lists.llvm.org> wrote: > > Hello, > > I am trying to cross-compile libc++ from my x86_64 linux system to armv7hf. We have our own gcc compiler that we build with crosstools-ng (based on gcc 6.3.0) and I set my environment like this: > > CC=armv7a-plex-linux-gnueabihf-gcc > CXX=armv7a-plex-linux-gnueabihf-g++ > CFLAGS=-fPIC -DPIC -mfloat-abi=hard -march=armv7-a -Os -mfpu=vfpv3-d16 --sysroot=<path> > CXXFLAGS=-fPIC -DPIC -mfloat-abi=hard -march=armv7-a -Os -mfpu=vfpv3-d16 --sysroot=<path> > LDFLAGS=-static-libgcc --sysroot=<path> > > then run cmake: > > cmake -GNinja -DLIBCXXABI_USE_LLVM_UNWINDER=ON DLLVM_TARGET_ARCH=ARM -DLLVM_DEFAULT_TARGET_TRIPLE=arm-linux-gnueabihf -DLLVM_TARGETS_TO_BUILD=ARM -DCMAKE_CROSSCOMPILING=True .. > > This errors out as shown below. It's like it's missing some definitions of different math functions that I can't seem to be able to see anywhere else. Is this a known problem? Or is it something with my compiler / toolchain setup that creates this problem? > > Thanks for any assistance. > > -- Tobias > > armv7a-plex-linux-gnueabihf-g++ -DLLVM_BUILD_GLOBAL_ISEL -DNDEBUG -D_DEBUG -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_LIBCPP_BUILDING_LIBRARY -D_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Iprojects/libcxx/lib -I../projects/libcxx/lib -Iinclude -I../include -Iprojects/libcxx/include/c++build -I../projects/libcxx/include -fPIC -DPIC -mfloat-abi=hard -march=armv7-a -Os -mfpu=vfpv3-d16 --sysroot=armv7a-plex-linux-gnueabihf/sysroot -fPIC -fvisibility-inlines-hidden -Werror=date-time -std=c++11 -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -g -DLIBCXX_BUILDING_LIBCXXABI -std=c++11 -nostdinc++ -fvisibility-inlines-hidden -Wall -Wextra -W -Wwrite-strings -Wno-unused-parameter -Wno-long-long -Werror=return-type -Wno-literal-suffix -Wno-c++14-compat -Wno-noexcept-type -Wno-error -fPIC -MD -MT projects/libcxx/lib/CMakeFiles/cxx_objects.dir/__/src/algorithm.cpp.o -MF projects/libcxx/lib/CMakeFiles/cxx_objects.dir/__/src/algorithm.cpp.o.d -o projects/libcxx/lib/CMakeFiles/cxx_objects.dir/__/src/algorithm.cpp.o -c ../projects/libcxx/src/algorithm.cpp > In file included from ../projects/libcxx/include/cmath:305:0, > from ../projects/libcxx/include/random:1638, > from ../projects/libcxx/src/algorithm.cpp:11: > ../projects/libcxx/include/math.h: In function 'long double abs(long double)': > ../projects/libcxx/include/math.h:742:45: error: '::fabsl' has not been declared > abs(long double __lcpp_x) _NOEXCEPT {return ::fabsl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double acos(long double)': > ../projects/libcxx/include/math.h:749:91: error: '::acosl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double acos(long double __lcpp_x) _NOEXCEPT {return ::acosl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double asin(long double)': > ../projects/libcxx/include/math.h:761:91: error: '::asinl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double asin(long double __lcpp_x) _NOEXCEPT {return ::asinl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double atan(long double)': > ../projects/libcxx/include/math.h:773:91: error: '::atanl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double atan(long double __lcpp_x) _NOEXCEPT {return ::atanl(__lcpp_x);} > ^~ > In file included from ../projects/libcxx/include/cmath:305:0, > from ../projects/libcxx/include/random:1638, > from ../projects/libcxx/src/algorithm.cpp:11: > ../projects/libcxx/include/math.h: In function 'long double atan2(long double, long double)': > ../projects/libcxx/include/math.h:785:114: error: '::atan2l' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double atan2(long double __lcpp_y, long double __lcpp_x) _NOEXCEPT {return ::atan2l(__lcpp_y, __lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double ceil(long double)': > ../projects/libcxx/include/math.h:808:91: error: '::ceill' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double ceil(long double __lcpp_x) _NOEXCEPT {return ::ceill(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double cos(long double)': > ../projects/libcxx/include/math.h:820:90: error: '::cosl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double cos(long double __lcpp_x) _NOEXCEPT {return ::cosl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double cosh(long double)': > ../projects/libcxx/include/math.h:832:91: error: '::coshl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double cosh(long double __lcpp_x) _NOEXCEPT {return ::coshl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double exp(long double)': > ../projects/libcxx/include/math.h:844:90: error: '::expl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double exp(long double __lcpp_x) _NOEXCEPT {return ::expl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double fabs(long double)': > ../projects/libcxx/include/math.h:856:91: error: '::fabsl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double fabs(long double __lcpp_x) _NOEXCEPT {return ::fabsl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double floor(long double)': > ../projects/libcxx/include/math.h:868:92: error: '::floorl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double floor(long double __lcpp_x) _NOEXCEPT {return ::floorl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double fmod(long double, long double)': > ../projects/libcxx/include/math.h:880:113: error: '::fmodl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double fmod(long double __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::fmodl(__lcpp_x, __lcpp_y);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double frexp(long double, int*)': > ../projects/libcxx/include/math.h:903:107: error: '::frexpl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double frexp(long double __lcpp_x, int* __lcpp_e) _NOEXCEPT {return ::frexpl(__lcpp_x, __lcpp_e);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double ldexp(long double, int)': > ../projects/libcxx/include/math.h:915:106: error: '::ldexpl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double ldexp(long double __lcpp_x, int __lcpp_e) _NOEXCEPT {return ::ldexpl(__lcpp_x, __lcpp_e);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double log(long double)': > ../projects/libcxx/include/math.h:927:90: error: '::logl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double log(long double __lcpp_x) _NOEXCEPT {return ::logl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double log10(long double)': > ../projects/libcxx/include/math.h:939:92: error: '::log10l' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double log10(long double __lcpp_x) _NOEXCEPT {return ::log10l(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double modf(long double, long double*)': > ../projects/libcxx/include/math.h:951:114: error: '::modfl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double modf(long double __lcpp_x, long double* __lcpp_y) _NOEXCEPT {return ::modfl(__lcpp_x, __lcpp_y);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double pow(long double, long double)': > ../projects/libcxx/include/math.h:958:112: error: '::powl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double pow(long double __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::powl(__lcpp_x, __lcpp_y);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double sin(long double)': > ../projects/libcxx/include/math.h:981:90: error: '::sinl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double sin(long double __lcpp_x) _NOEXCEPT {return ::sinl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double sinh(long double)': > ../projects/libcxx/include/math.h:993:91: error: '::sinhl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double sinh(long double __lcpp_x) _NOEXCEPT {return ::sinhl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double sqrt(long double)': > ../projects/libcxx/include/math.h:1005:91: error: '::sqrtl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double sqrt(long double __lcpp_x) _NOEXCEPT {return ::sqrtl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double tan(long double)': > ../projects/libcxx/include/math.h:1017:90: error: '::tanl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double tan(long double __lcpp_x) _NOEXCEPT {return ::tanl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double tanh(long double)': > ../projects/libcxx/include/math.h:1029:91: error: '::tanhl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double tanh(long double __lcpp_x) _NOEXCEPT {return ::tanhl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double acosh(long double)': > ../projects/libcxx/include/math.h:1040:92: error: '::acoshl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double acosh(long double __lcpp_x) _NOEXCEPT {return ::acoshl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double asinh(long double)': > ../projects/libcxx/include/math.h:1050:92: error: '::asinhl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double asinh(long double __lcpp_x) _NOEXCEPT {return ::asinhl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double atanh(long double)': > ../projects/libcxx/include/math.h:1060:92: error: '::atanhl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double atanh(long double __lcpp_x) _NOEXCEPT {return ::atanhl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double cbrt(long double)': > ../projects/libcxx/include/math.h:1070:91: error: '::cbrtl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double cbrt(long double __lcpp_x) _NOEXCEPT {return ::cbrtl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double copysign(long double, long double)': > ../projects/libcxx/include/math.h:1085:10: error: '::copysignl' has not been declared > return ::copysignl(__lcpp_x, __lcpp_y); > ^~ > ../projects/libcxx/include/math.h: In function 'long double erf(long double)': > ../projects/libcxx/include/math.h:1107:90: error: '::erfl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double erf(long double __lcpp_x) _NOEXCEPT {return ::erfl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double erfc(long double)': > ../projects/libcxx/include/math.h:1117:91: error: '::erfcl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double erfc(long double __lcpp_x) _NOEXCEPT {return ::erfcl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double exp2(long double)': > ../projects/libcxx/include/math.h:1127:91: error: '::exp2l' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double exp2(long double __lcpp_x) _NOEXCEPT {return ::exp2l(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double expm1(long double)': > ../projects/libcxx/include/math.h:1137:92: error: '::expm1l' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double expm1(long double __lcpp_x) _NOEXCEPT {return ::expm1l(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double fdim(long double, long double)': > ../projects/libcxx/include/math.h:1147:113: error: '::fdiml' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double fdim(long double __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::fdiml(__lcpp_x, __lcpp_y);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double fma(long double, long double, long double)': > ../projects/libcxx/include/math.h:1168:134: error: '::fmal' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double fma(long double __lcpp_x, long double __lcpp_y, long double __lcpp_z) _NOEXCEPT {return ::fmal(__lcpp_x, __lcpp_y, __lcpp_z);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double fmax(long double, long double)': > ../projects/libcxx/include/math.h:1191:113: error: '::fmaxl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double fmax(long double __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::fmaxl(__lcpp_x, __lcpp_y);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double fmin(long double, long double)': > ../projects/libcxx/include/math.h:1212:113: error: '::fminl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double fmin(long double __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::fminl(__lcpp_x, __lcpp_y);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double hypot(long double, long double)': > ../projects/libcxx/include/math.h:1233:114: error: '::hypotl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double hypot(long double __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::hypotl(__lcpp_x, __lcpp_y);} > ^~ > ../projects/libcxx/include/math.h: In function 'int ilogb(long double)': > ../projects/libcxx/include/math.h:1254:84: error: '::ilogbl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY int ilogb(long double __lcpp_x) _NOEXCEPT {return ::ilogbl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double lgamma(long double)': > ../projects/libcxx/include/math.h:1264:93: error: '::lgammal' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double lgamma(long double __lcpp_x) _NOEXCEPT {return ::lgammal(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long long int llrint(long double)': > ../projects/libcxx/include/math.h:1274:91: error: '::llrintl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long long llrint(long double __lcpp_x) _NOEXCEPT {return ::llrintl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long long int llround(long double)': > ../projects/libcxx/include/math.h:1284:92: error: '::llroundl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long long llround(long double __lcpp_x) _NOEXCEPT {return ::llroundl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double log1p(long double)': > ../projects/libcxx/include/math.h:1294:92: error: '::log1pl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double log1p(long double __lcpp_x) _NOEXCEPT {return ::log1pl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double log2(long double)': > ../projects/libcxx/include/math.h:1304:91: error: '::log2l' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double log2(long double __lcpp_x) _NOEXCEPT {return ::log2l(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double logb(long double)': > ../projects/libcxx/include/math.h:1314:91: error: '::logbl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double logb(long double __lcpp_x) _NOEXCEPT {return ::logbl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long int lrint(long double)': > ../projects/libcxx/include/math.h:1324:85: error: '::lrintl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long lrint(long double __lcpp_x) _NOEXCEPT {return ::lrintl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long int lround(long double)': > ../projects/libcxx/include/math.h:1334:86: error: '::lroundl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long lround(long double __lcpp_x) _NOEXCEPT {return ::lroundl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double nearbyint(long double)': > ../projects/libcxx/include/math.h:1346:96: error: '::nearbyintl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double nearbyint(long double __lcpp_x) _NOEXCEPT {return ::nearbyintl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double nextafter(long double, long double)': > ../projects/libcxx/include/math.h:1356:118: error: '::nextafterl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double nextafter(long double __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::nextafterl(__lcpp_x, __lcpp_y);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double nexttoward(long double, long double)': > ../projects/libcxx/include/math.h:1377:119: error: '::nexttowardl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double nexttoward(long double __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::nexttowardl(__lcpp_x, __lcpp_y);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double remainder(long double, long double)': > ../projects/libcxx/include/math.h:1387:118: error: '::remainderl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double remainder(long double __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::remainderl(__lcpp_x, __lcpp_y);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double remquo(long double, long double, int*)': > ../projects/libcxx/include/math.h:1408:130: error: '::remquol' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double remquo(long double __lcpp_x, long double __lcpp_y, int* __lcpp_z) _NOEXCEPT {return ::remquol(__lcpp_x, __lcpp_y, __lcpp_z);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double rint(long double)': > ../projects/libcxx/include/math.h:1429:91: error: '::rintl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double rint(long double __lcpp_x) _NOEXCEPT {return ::rintl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double round(long double)': > ../projects/libcxx/include/math.h:1439:92: error: '::roundl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double round(long double __lcpp_x) _NOEXCEPT {return ::roundl(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double scalbln(long double, long int)': > ../projects/libcxx/include/math.h:1449:109: error: '::scalblnl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double scalbln(long double __lcpp_x, long __lcpp_y) _NOEXCEPT {return ::scalblnl(__lcpp_x, __lcpp_y);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double scalbn(long double, int)': > ../projects/libcxx/include/math.h:1459:107: error: '::scalbnl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double scalbn(long double __lcpp_x, int __lcpp_y) _NOEXCEPT {return ::scalbnl(__lcpp_x, __lcpp_y);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double tgamma(long double)': > ../projects/libcxx/include/math.h:1469:93: error: '::tgammal' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double tgamma(long double __lcpp_x) _NOEXCEPT {return ::tgammal(__lcpp_x);} > ^~ > ../projects/libcxx/include/math.h: In function 'long double trunc(long double)': > ../projects/libcxx/include/math.h:1479:92: error: '::truncl' has not been declared > inline _LIBCPP_INLINE_VISIBILITY long double trunc(long double __lcpp_x) _NOEXCEPT {return ::truncl(__lcpp_x);} > ^~ > In file included from ../projects/libcxx/include/random:1638:0, > from ../projects/libcxx/src/algorithm.cpp:11: > ../projects/libcxx/include/cmath: At global scope: > ../projects/libcxx/include/cmath:464:9: error: '::acosl' has not been declared > using ::acosl; > ^~~~~ > ../projects/libcxx/include/cmath:465:9: error: '::asinl' has not been declared > using ::asinl; > ^~~~~ > ../projects/libcxx/include/cmath:466:9: error: '::atanl' has not been declared > using ::atanl; > ^~~~~ > ../projects/libcxx/include/cmath:467:9: error: '::atan2l' has not been declared > using ::atan2l; > ^~~~~~ > ../projects/libcxx/include/cmath:468:9: error: '::ceill' has not been declared > using ::ceill; > ^~~~~ > ../projects/libcxx/include/cmath:469:9: error: '::cosl' has not been declared > using ::cosl; > ^~~~ > ../projects/libcxx/include/cmath:470:9: error: '::coshl' has not been declared > using ::coshl; > ^~~~~ > ../projects/libcxx/include/cmath:471:9: error: '::expl' has not been declared > using ::expl; > ^~~~ > ../projects/libcxx/include/cmath:472:9: error: '::fabsl' has not been declared > using ::fabsl; > ^~~~~ > ../projects/libcxx/include/cmath:473:9: error: '::floorl' has not been declared > using ::floorl; > ^~~~~~ > ../projects/libcxx/include/cmath:474:9: error: '::fmodl' has not been declared > using ::fmodl; > ^~~~~ > ../projects/libcxx/include/cmath:475:9: error: '::frexpl' has not been declared > using ::frexpl; > ^~~~~~ > ../projects/libcxx/include/cmath:476:9: error: '::ldexpl' has not been declared > using ::ldexpl; > ^~~~~~ > ../projects/libcxx/include/cmath:477:9: error: '::logl' has not been declared > using ::logl; > ^~~~ > ../projects/libcxx/include/cmath:478:9: error: '::log10l' has not been declared > using ::log10l; > ^~~~~~ > ../projects/libcxx/include/cmath:479:9: error: '::modfl' has not been declared > using ::modfl; > ^~~~~ > ../projects/libcxx/include/cmath:480:9: error: '::powl' has not been declared > using ::powl; > ^~~~ > ../projects/libcxx/include/cmath:481:9: error: '::sinl' has not been declared > using ::sinl; > ^~~~ > ../projects/libcxx/include/cmath:482:9: error: '::sinhl' has not been declared > using ::sinhl; > ^~~~~ > ../projects/libcxx/include/cmath:483:9: error: '::sqrtl' has not been declared > using ::sqrtl; > ^~~~~ > ../projects/libcxx/include/cmath:484:9: error: '::tanl' has not been declared > using ::tanl; > ^~~~ > ../projects/libcxx/include/cmath:486:9: error: '::tanhl' has not been declared > using ::tanhl; > ^~~~~ > ../projects/libcxx/include/cmath:487:9: error: '::acoshl' has not been declared > using ::acoshl; > ^~~~~~ > ../projects/libcxx/include/cmath:488:9: error: '::asinhl' has not been declared > using ::asinhl; > ^~~~~~ > ../projects/libcxx/include/cmath:489:9: error: '::atanhl' has not been declared > using ::atanhl; > ^~~~~~ > ../projects/libcxx/include/cmath:490:9: error: '::cbrtl' has not been declared > using ::cbrtl; > ^~~~~ > ../projects/libcxx/include/cmath:492:9: error: '::copysignl' has not been declared > using ::copysignl; > ^~~~~~~~~ > ../projects/libcxx/include/cmath:494:9: error: '::erfl' has not been declared > using ::erfl; > ^~~~ > ../projects/libcxx/include/cmath:495:9: error: '::erfcl' has not been declared > using ::erfcl; > ^~~~~ > ../projects/libcxx/include/cmath:496:9: error: '::exp2l' has not been declared > using ::exp2l; > ^~~~~ > ../projects/libcxx/include/cmath:497:9: error: '::expm1l' has not been declared > using ::expm1l; > ^~~~~~ > ../projects/libcxx/include/cmath:498:9: error: '::fdiml' has not been declared > using ::fdiml; > ^~~~~ > ../projects/libcxx/include/cmath:499:9: error: '::fmal' has not been declared > using ::fmal; > ^~~~ > ../projects/libcxx/include/cmath:500:9: error: '::fmaxl' has not been declared > using ::fmaxl; > ^~~~~ > ../projects/libcxx/include/cmath:501:9: error: '::fminl' has not been declared > using ::fminl; > ^~~~~ > ../projects/libcxx/include/cmath:502:9: error: '::hypotl' has not been declared > using ::hypotl; > ^~~~~~ > ../projects/libcxx/include/cmath:503:9: error: '::ilogbl' has not been declared > using ::ilogbl; > ^~~~~~ > ../projects/libcxx/include/cmath:504:9: error: '::lgammal' has not been declared > using ::lgammal; > ^~~~~~~ > ../projects/libcxx/include/cmath:505:9: error: '::llrintl' has not been declared > using ::llrintl; > ^~~~~~~ > ../projects/libcxx/include/cmath:506:9: error: '::llroundl' has not been declared > using ::llroundl; > ^~~~~~~~ > ../projects/libcxx/include/cmath:507:9: error: '::log1pl' has not been declared > using ::log1pl; > ^~~~~~ > ../projects/libcxx/include/cmath:508:9: error: '::log2l' has not been declared > using ::log2l; > ^~~~~ > ../projects/libcxx/include/cmath:509:9: error: '::logbl' has not been declared > using ::logbl; > ^~~~~ > ../projects/libcxx/include/cmath:510:9: error: '::lrintl' has not been declared > using ::lrintl; > ^~~~~~ > ../projects/libcxx/include/cmath:511:9: error: '::lroundl' has not been declared > using ::lroundl; > ^~~~~~~ > ../projects/libcxx/include/cmath:512:9: error: '::nanl' has not been declared > using ::nanl; > ^~~~ > ../projects/libcxx/include/cmath:513:9: error: '::nearbyintl' has not been declared > using ::nearbyintl; > ^~~~~~~~~~ > ../projects/libcxx/include/cmath:514:9: error: '::nextafterl' has not been declared > using ::nextafterl; > ^~~~~~~~~~ > ../projects/libcxx/include/cmath:515:9: error: '::nexttowardl' has not been declared > using ::nexttowardl; > ^~~~~~~~~~~ > ../projects/libcxx/include/cmath:516:9: error: '::remainderl' has not been declared > using ::remainderl; > ^~~~~~~~~~ > ../projects/libcxx/include/cmath:517:9: error: '::remquol' has not been declared > using ::remquol; > ^~~~~~~ > ../projects/libcxx/include/cmath:518:9: error: '::rintl' has not been declared > using ::rintl; > ^~~~~ > ../projects/libcxx/include/cmath:519:9: error: '::roundl' has not been declared > using ::roundl; > ^~~~~~ > ../projects/libcxx/include/cmath:520:9: error: '::scalblnl' has not been declared > using ::scalblnl; > ^~~~~~~~ > ../projects/libcxx/include/cmath:521:9: error: '::scalbnl' has not been declared > using ::scalbnl; > ^~~~~~~ > ../projects/libcxx/include/cmath:522:9: error: '::tgammal' has not been declared > using ::tgammal; > ^~~~~~~ > ../projects/libcxx/include/cmath:523:9: error: '::truncl' has not been declared > using ::truncl; > ^~~~~~ > > _______________________________________________ > LLVM Developers mailing list > llvm-dev at lists.llvm.org > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev-------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 223 bytes Desc: Message signed with OpenPGP URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20180206/02310410/attachment.sig>
Tobias Hieta via llvm-dev
2018-Feb-06 14:51 UTC
[llvm-dev] libc++ cross-compile linux-armv7 and math function problems
Hello Dimitry and thanks for your answer. I am pretty sure it does indeed support long double. It's configured with vfpv3-d16 - but I noticed that c++config.h in gcc has _GLIBCXX__HAS_FABSL and friends are undefined. I think I need to look deeper at the configuration of our toolchain. long double support is required in libc++ then I gather? -- Tobias On Tue, Feb 6, 2018 at 11:47 AM, Dimitry Andric <dimitry at andric.com> wrote:> At first glance, it looks like long double functions (such as fabsl and > friends) are missing from your sysroot's <math.h>. Does your target > support long double at all? > > -Dimitry > > > On 6 Feb 2018, at 09:51, Tobias Hieta via llvm-dev < > llvm-dev at lists.llvm.org> wrote: > > > > Hello, > > > > I am trying to cross-compile libc++ from my x86_64 linux system to > armv7hf. We have our own gcc compiler that we build with crosstools-ng > (based on gcc 6.3.0) and I set my environment like this: > > > > CC=armv7a-plex-linux-gnueabihf-gcc > > CXX=armv7a-plex-linux-gnueabihf-g++ > > CFLAGS=-fPIC -DPIC -mfloat-abi=hard -march=armv7-a -Os -mfpu=vfpv3-d16 > --sysroot=<path> > > CXXFLAGS=-fPIC -DPIC -mfloat-abi=hard -march=armv7-a -Os -mfpu=vfpv3-d16 > --sysroot=<path> > > LDFLAGS=-static-libgcc --sysroot=<path> > > > > then run cmake: > > > > cmake -GNinja -DLIBCXXABI_USE_LLVM_UNWINDER=ON DLLVM_TARGET_ARCH=ARM > -DLLVM_DEFAULT_TARGET_TRIPLE=arm-linux-gnueabihf > -DLLVM_TARGETS_TO_BUILD=ARM -DCMAKE_CROSSCOMPILING=True .. > > > > This errors out as shown below. It's like it's missing some definitions > of different math functions that I can't seem to be able to see anywhere > else. Is this a known problem? Or is it something with my compiler / > toolchain setup that creates this problem? > > > > Thanks for any assistance. > > > > -- Tobias > > > > armv7a-plex-linux-gnueabihf-g++ -DLLVM_BUILD_GLOBAL_ISEL -DNDEBUG > -D_DEBUG -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -D_LARGEFILE_SOURCE > -D_LIBCPP_BUILDING_LIBRARY -D_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER > -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS > -Iprojects/libcxx/lib -I../projects/libcxx/lib -Iinclude -I../include > -Iprojects/libcxx/include/c++build -I../projects/libcxx/include -fPIC > -DPIC -mfloat-abi=hard -march=armv7-a -Os -mfpu=vfpv3-d16 > --sysroot=armv7a-plex-linux-gnueabihf/sysroot -fPIC > -fvisibility-inlines-hidden -Werror=date-time -std=c++11 -Wall -W > -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers > -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor > -Wno-comment -g -DLIBCXX_BUILDING_LIBCXXABI -std=c++11 -nostdinc++ > -fvisibility-inlines-hidden -Wall -Wextra -W -Wwrite-strings > -Wno-unused-parameter -Wno-long-long -Werror=return-type > -Wno-literal-suffix -Wno-c++14-compat -Wno-noexcept-type -Wno-error -fPIC > -MD -MT projects/libcxx/lib/CMakeFiles/cxx_objects.dir/__/src/algorithm.cpp.o > -MF projects/libcxx/lib/CMakeFiles/cxx_objects.dir/__/src/algorithm.cpp.o.d > -o projects/libcxx/lib/CMakeFiles/cxx_objects.dir/__/src/algorithm.cpp.o > -c ../projects/libcxx/src/algorithm.cpp > > In file included from ../projects/libcxx/include/cmath:305:0, > > from ../projects/libcxx/include/random:1638, > > from ../projects/libcxx/src/algorithm.cpp:11: > > ../projects/libcxx/include/math.h: In function 'long double abs(long > double)': > > ../projects/libcxx/include/math.h:742:45: error: '::fabsl' has not been > declared > > abs(long double __lcpp_x) _NOEXCEPT {return ::fabsl(__lcpp_x);} > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double acos(long > double)': > > ../projects/libcxx/include/math.h:749:91: error: '::acosl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double acos(long double __lcpp_x) > _NOEXCEPT {return ::acosl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double asin(long > double)': > > ../projects/libcxx/include/math.h:761:91: error: '::asinl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double asin(long double __lcpp_x) > _NOEXCEPT {return ::asinl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double atan(long > double)': > > ../projects/libcxx/include/math.h:773:91: error: '::atanl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double atan(long double __lcpp_x) > _NOEXCEPT {return ::atanl(__lcpp_x);} > > > ^~ > > In file included from ../projects/libcxx/include/cmath:305:0, > > from ../projects/libcxx/include/random:1638, > > from ../projects/libcxx/src/algorithm.cpp:11: > > ../projects/libcxx/include/math.h: In function 'long double atan2(long > double, long double)': > > ../projects/libcxx/include/math.h:785:114: error: '::atan2l' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double atan2(long double > __lcpp_y, long double __lcpp_x) _NOEXCEPT {return ::atan2l(__lcpp_y, > __lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double ceil(long > double)': > > ../projects/libcxx/include/math.h:808:91: error: '::ceill' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double ceil(long double __lcpp_x) > _NOEXCEPT {return ::ceill(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double cos(long > double)': > > ../projects/libcxx/include/math.h:820:90: error: '::cosl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double cos(long double __lcpp_x) > _NOEXCEPT {return ::cosl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double cosh(long > double)': > > ../projects/libcxx/include/math.h:832:91: error: '::coshl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double cosh(long double __lcpp_x) > _NOEXCEPT {return ::coshl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double exp(long > double)': > > ../projects/libcxx/include/math.h:844:90: error: '::expl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double exp(long double __lcpp_x) > _NOEXCEPT {return ::expl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double fabs(long > double)': > > ../projects/libcxx/include/math.h:856:91: error: '::fabsl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double fabs(long double __lcpp_x) > _NOEXCEPT {return ::fabsl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double floor(long > double)': > > ../projects/libcxx/include/math.h:868:92: error: '::floorl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double floor(long double > __lcpp_x) _NOEXCEPT {return ::floorl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double fmod(long > double, long double)': > > ../projects/libcxx/include/math.h:880:113: error: '::fmodl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double fmod(long double __lcpp_x, > long double __lcpp_y) _NOEXCEPT {return ::fmodl(__lcpp_x, __lcpp_y);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double frexp(long > double, int*)': > > ../projects/libcxx/include/math.h:903:107: error: '::frexpl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double frexp(long double > __lcpp_x, int* __lcpp_e) _NOEXCEPT {return ::frexpl(__lcpp_x, __lcpp_e);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double ldexp(long > double, int)': > > ../projects/libcxx/include/math.h:915:106: error: '::ldexpl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double ldexp(long double > __lcpp_x, int __lcpp_e) _NOEXCEPT {return ::ldexpl(__lcpp_x, __lcpp_e);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double log(long > double)': > > ../projects/libcxx/include/math.h:927:90: error: '::logl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double log(long double __lcpp_x) > _NOEXCEPT {return ::logl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double log10(long > double)': > > ../projects/libcxx/include/math.h:939:92: error: '::log10l' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double log10(long double > __lcpp_x) _NOEXCEPT {return ::log10l(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double modf(long > double, long double*)': > > ../projects/libcxx/include/math.h:951:114: error: '::modfl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double modf(long double __lcpp_x, > long double* __lcpp_y) _NOEXCEPT {return ::modfl(__lcpp_x, __lcpp_y);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double pow(long > double, long double)': > > ../projects/libcxx/include/math.h:958:112: error: '::powl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double pow(long double __lcpp_x, > long double __lcpp_y) _NOEXCEPT {return ::powl(__lcpp_x, __lcpp_y);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double sin(long > double)': > > ../projects/libcxx/include/math.h:981:90: error: '::sinl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double sin(long double __lcpp_x) > _NOEXCEPT {return ::sinl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double sinh(long > double)': > > ../projects/libcxx/include/math.h:993:91: error: '::sinhl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double sinh(long double __lcpp_x) > _NOEXCEPT {return ::sinhl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double sqrt(long > double)': > > ../projects/libcxx/include/math.h:1005:91: error: '::sqrtl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double sqrt(long double __lcpp_x) > _NOEXCEPT {return ::sqrtl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double tan(long > double)': > > ../projects/libcxx/include/math.h:1017:90: error: '::tanl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double tan(long double __lcpp_x) > _NOEXCEPT {return ::tanl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double tanh(long > double)': > > ../projects/libcxx/include/math.h:1029:91: error: '::tanhl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double tanh(long double __lcpp_x) > _NOEXCEPT {return ::tanhl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double acosh(long > double)': > > ../projects/libcxx/include/math.h:1040:92: error: '::acoshl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double acosh(long double > __lcpp_x) _NOEXCEPT {return ::acoshl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double asinh(long > double)': > > ../projects/libcxx/include/math.h:1050:92: error: '::asinhl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double asinh(long double > __lcpp_x) _NOEXCEPT {return ::asinhl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double atanh(long > double)': > > ../projects/libcxx/include/math.h:1060:92: error: '::atanhl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double atanh(long double > __lcpp_x) _NOEXCEPT {return ::atanhl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double cbrt(long > double)': > > ../projects/libcxx/include/math.h:1070:91: error: '::cbrtl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double cbrt(long double __lcpp_x) > _NOEXCEPT {return ::cbrtl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double > copysign(long double, long double)': > > ../projects/libcxx/include/math.h:1085:10: error: '::copysignl' has not > been declared > > return ::copysignl(__lcpp_x, __lcpp_y); > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double erf(long > double)': > > ../projects/libcxx/include/math.h:1107:90: error: '::erfl' has not been > declared > > inline _LIBCPP_INLINE_VISIBILITY long double erf(long double __lcpp_x) > _NOEXCEPT {return ::erfl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double erfc(long > double)': > > ../projects/libcxx/include/math.h:1117:91: error: '::erfcl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double erfc(long double __lcpp_x) > _NOEXCEPT {return ::erfcl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double exp2(long > double)': > > ../projects/libcxx/include/math.h:1127:91: error: '::exp2l' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double exp2(long double __lcpp_x) > _NOEXCEPT {return ::exp2l(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double expm1(long > double)': > > ../projects/libcxx/include/math.h:1137:92: error: '::expm1l' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double expm1(long double > __lcpp_x) _NOEXCEPT {return ::expm1l(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double fdim(long > double, long double)': > > ../projects/libcxx/include/math.h:1147:113: error: '::fdiml' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double fdim(long double __lcpp_x, > long double __lcpp_y) _NOEXCEPT {return ::fdiml(__lcpp_x, __lcpp_y);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double fma(long > double, long double, long double)': > > ../projects/libcxx/include/math.h:1168:134: error: '::fmal' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double fma(long double __lcpp_x, > long double __lcpp_y, long double __lcpp_z) _NOEXCEPT {return > ::fmal(__lcpp_x, __lcpp_y, __lcpp_z);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double fmax(long > double, long double)': > > ../projects/libcxx/include/math.h:1191:113: error: '::fmaxl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double fmax(long double __lcpp_x, > long double __lcpp_y) _NOEXCEPT {return ::fmaxl(__lcpp_x, __lcpp_y);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double fmin(long > double, long double)': > > ../projects/libcxx/include/math.h:1212:113: error: '::fminl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double fmin(long double __lcpp_x, > long double __lcpp_y) _NOEXCEPT {return ::fminl(__lcpp_x, __lcpp_y);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double hypot(long > double, long double)': > > ../projects/libcxx/include/math.h:1233:114: error: '::hypotl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double hypot(long double > __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::hypotl(__lcpp_x, > __lcpp_y);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'int ilogb(long double)': > > ../projects/libcxx/include/math.h:1254:84: error: '::ilogbl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY int ilogb(long double __lcpp_x) > _NOEXCEPT {return ::ilogbl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double lgamma(long > double)': > > ../projects/libcxx/include/math.h:1264:93: error: '::lgammal' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double lgamma(long double > __lcpp_x) _NOEXCEPT {return ::lgammal(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long long int > llrint(long double)': > > ../projects/libcxx/include/math.h:1274:91: error: '::llrintl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long long llrint(long double __lcpp_x) > _NOEXCEPT {return ::llrintl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long long int > llround(long double)': > > ../projects/libcxx/include/math.h:1284:92: error: '::llroundl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long long llround(long double > __lcpp_x) _NOEXCEPT {return ::llroundl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double log1p(long > double)': > > ../projects/libcxx/include/math.h:1294:92: error: '::log1pl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double log1p(long double > __lcpp_x) _NOEXCEPT {return ::log1pl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double log2(long > double)': > > ../projects/libcxx/include/math.h:1304:91: error: '::log2l' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double log2(long double __lcpp_x) > _NOEXCEPT {return ::log2l(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double logb(long > double)': > > ../projects/libcxx/include/math.h:1314:91: error: '::logbl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double logb(long double __lcpp_x) > _NOEXCEPT {return ::logbl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long int lrint(long > double)': > > ../projects/libcxx/include/math.h:1324:85: error: '::lrintl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long lrint(long double __lcpp_x) > _NOEXCEPT {return ::lrintl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long int lround(long > double)': > > ../projects/libcxx/include/math.h:1334:86: error: '::lroundl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long lround(long double __lcpp_x) > _NOEXCEPT {return ::lroundl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double > nearbyint(long double)': > > ../projects/libcxx/include/math.h:1346:96: error: '::nearbyintl' has > not been declared > > inline _LIBCPP_INLINE_VISIBILITY long double nearbyint(long double > __lcpp_x) _NOEXCEPT {return ::nearbyintl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double > nextafter(long double, long double)': > > ../projects/libcxx/include/math.h:1356:118: error: '::nextafterl' has > not been declared > > inline _LIBCPP_INLINE_VISIBILITY long double nextafter(long double > __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::nextafterl(__lcpp_x, > __lcpp_y);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double > nexttoward(long double, long double)': > > ../projects/libcxx/include/math.h:1377:119: error: '::nexttowardl' has > not been declared > > inline _LIBCPP_INLINE_VISIBILITY long double nexttoward(long double > __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::nexttowardl(__lcpp_x, > __lcpp_y);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double > remainder(long double, long double)': > > ../projects/libcxx/include/math.h:1387:118: error: '::remainderl' has > not been declared > > inline _LIBCPP_INLINE_VISIBILITY long double remainder(long double > __lcpp_x, long double __lcpp_y) _NOEXCEPT {return ::remainderl(__lcpp_x, > __lcpp_y);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double remquo(long > double, long double, int*)': > > ../projects/libcxx/include/math.h:1408:130: error: '::remquol' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double remquo(long double > __lcpp_x, long double __lcpp_y, int* __lcpp_z) _NOEXCEPT {return > ::remquol(__lcpp_x, __lcpp_y, __lcpp_z);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double rint(long > double)': > > ../projects/libcxx/include/math.h:1429:91: error: '::rintl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double rint(long double __lcpp_x) > _NOEXCEPT {return ::rintl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double round(long > double)': > > ../projects/libcxx/include/math.h:1439:92: error: '::roundl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double round(long double > __lcpp_x) _NOEXCEPT {return ::roundl(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double > scalbln(long double, long int)': > > ../projects/libcxx/include/math.h:1449:109: error: '::scalblnl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double scalbln(long double > __lcpp_x, long __lcpp_y) _NOEXCEPT {return ::scalblnl(__lcpp_x, __lcpp_y);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double scalbn(long > double, int)': > > ../projects/libcxx/include/math.h:1459:107: error: '::scalbnl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double scalbn(long double > __lcpp_x, int __lcpp_y) _NOEXCEPT {return ::scalbnl(__lcpp_x, __lcpp_y);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double tgamma(long > double)': > > ../projects/libcxx/include/math.h:1469:93: error: '::tgammal' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double tgamma(long double > __lcpp_x) _NOEXCEPT {return ::tgammal(__lcpp_x);} > > > ^~ > > ../projects/libcxx/include/math.h: In function 'long double trunc(long > double)': > > ../projects/libcxx/include/math.h:1479:92: error: '::truncl' has not > been declared > > inline _LIBCPP_INLINE_VISIBILITY long double trunc(long double > __lcpp_x) _NOEXCEPT {return ::truncl(__lcpp_x);} > > > ^~ > > In file included from ../projects/libcxx/include/random:1638:0, > > from ../projects/libcxx/src/algorithm.cpp:11: > > ../projects/libcxx/include/cmath: At global scope: > > ../projects/libcxx/include/cmath:464:9: error: '::acosl' has not been > declared > > using ::acosl; > > ^~~~~ > > ../projects/libcxx/include/cmath:465:9: error: '::asinl' has not been > declared > > using ::asinl; > > ^~~~~ > > ../projects/libcxx/include/cmath:466:9: error: '::atanl' has not been > declared > > using ::atanl; > > ^~~~~ > > ../projects/libcxx/include/cmath:467:9: error: '::atan2l' has not been > declared > > using ::atan2l; > > ^~~~~~ > > ../projects/libcxx/include/cmath:468:9: error: '::ceill' has not been > declared > > using ::ceill; > > ^~~~~ > > ../projects/libcxx/include/cmath:469:9: error: '::cosl' has not been > declared > > using ::cosl; > > ^~~~ > > ../projects/libcxx/include/cmath:470:9: error: '::coshl' has not been > declared > > using ::coshl; > > ^~~~~ > > ../projects/libcxx/include/cmath:471:9: error: '::expl' has not been > declared > > using ::expl; > > ^~~~ > > ../projects/libcxx/include/cmath:472:9: error: '::fabsl' has not been > declared > > using ::fabsl; > > ^~~~~ > > ../projects/libcxx/include/cmath:473:9: error: '::floorl' has not been > declared > > using ::floorl; > > ^~~~~~ > > ../projects/libcxx/include/cmath:474:9: error: '::fmodl' has not been > declared > > using ::fmodl; > > ^~~~~ > > ../projects/libcxx/include/cmath:475:9: error: '::frexpl' has not been > declared > > using ::frexpl; > > ^~~~~~ > > ../projects/libcxx/include/cmath:476:9: error: '::ldexpl' has not been > declared > > using ::ldexpl; > > ^~~~~~ > > ../projects/libcxx/include/cmath:477:9: error: '::logl' has not been > declared > > using ::logl; > > ^~~~ > > ../projects/libcxx/include/cmath:478:9: error: '::log10l' has not been > declared > > using ::log10l; > > ^~~~~~ > > ../projects/libcxx/include/cmath:479:9: error: '::modfl' has not been > declared > > using ::modfl; > > ^~~~~ > > ../projects/libcxx/include/cmath:480:9: error: '::powl' has not been > declared > > using ::powl; > > ^~~~ > > ../projects/libcxx/include/cmath:481:9: error: '::sinl' has not been > declared > > using ::sinl; > > ^~~~ > > ../projects/libcxx/include/cmath:482:9: error: '::sinhl' has not been > declared > > using ::sinhl; > > ^~~~~ > > ../projects/libcxx/include/cmath:483:9: error: '::sqrtl' has not been > declared > > using ::sqrtl; > > ^~~~~ > > ../projects/libcxx/include/cmath:484:9: error: '::tanl' has not been > declared > > using ::tanl; > > ^~~~ > > ../projects/libcxx/include/cmath:486:9: error: '::tanhl' has not been > declared > > using ::tanhl; > > ^~~~~ > > ../projects/libcxx/include/cmath:487:9: error: '::acoshl' has not been > declared > > using ::acoshl; > > ^~~~~~ > > ../projects/libcxx/include/cmath:488:9: error: '::asinhl' has not been > declared > > using ::asinhl; > > ^~~~~~ > > ../projects/libcxx/include/cmath:489:9: error: '::atanhl' has not been > declared > > using ::atanhl; > > ^~~~~~ > > ../projects/libcxx/include/cmath:490:9: error: '::cbrtl' has not been > declared > > using ::cbrtl; > > ^~~~~ > > ../projects/libcxx/include/cmath:492:9: error: '::copysignl' has not > been declared > > using ::copysignl; > > ^~~~~~~~~ > > ../projects/libcxx/include/cmath:494:9: error: '::erfl' has not been > declared > > using ::erfl; > > ^~~~ > > ../projects/libcxx/include/cmath:495:9: error: '::erfcl' has not been > declared > > using ::erfcl; > > ^~~~~ > > ../projects/libcxx/include/cmath:496:9: error: '::exp2l' has not been > declared > > using ::exp2l; > > ^~~~~ > > ../projects/libcxx/include/cmath:497:9: error: '::expm1l' has not been > declared > > using ::expm1l; > > ^~~~~~ > > ../projects/libcxx/include/cmath:498:9: error: '::fdiml' has not been > declared > > using ::fdiml; > > ^~~~~ > > ../projects/libcxx/include/cmath:499:9: error: '::fmal' has not been > declared > > using ::fmal; > > ^~~~ > > ../projects/libcxx/include/cmath:500:9: error: '::fmaxl' has not been > declared > > using ::fmaxl; > > ^~~~~ > > ../projects/libcxx/include/cmath:501:9: error: '::fminl' has not been > declared > > using ::fminl; > > ^~~~~ > > ../projects/libcxx/include/cmath:502:9: error: '::hypotl' has not been > declared > > using ::hypotl; > > ^~~~~~ > > ../projects/libcxx/include/cmath:503:9: error: '::ilogbl' has not been > declared > > using ::ilogbl; > > ^~~~~~ > > ../projects/libcxx/include/cmath:504:9: error: '::lgammal' has not been > declared > > using ::lgammal; > > ^~~~~~~ > > ../projects/libcxx/include/cmath:505:9: error: '::llrintl' has not been > declared > > using ::llrintl; > > ^~~~~~~ > > ../projects/libcxx/include/cmath:506:9: error: '::llroundl' has not > been declared > > using ::llroundl; > > ^~~~~~~~ > > ../projects/libcxx/include/cmath:507:9: error: '::log1pl' has not been > declared > > using ::log1pl; > > ^~~~~~ > > ../projects/libcxx/include/cmath:508:9: error: '::log2l' has not been > declared > > using ::log2l; > > ^~~~~ > > ../projects/libcxx/include/cmath:509:9: error: '::logbl' has not been > declared > > using ::logbl; > > ^~~~~ > > ../projects/libcxx/include/cmath:510:9: error: '::lrintl' has not been > declared > > using ::lrintl; > > ^~~~~~ > > ../projects/libcxx/include/cmath:511:9: error: '::lroundl' has not been > declared > > using ::lroundl; > > ^~~~~~~ > > ../projects/libcxx/include/cmath:512:9: error: '::nanl' has not been > declared > > using ::nanl; > > ^~~~ > > ../projects/libcxx/include/cmath:513:9: error: '::nearbyintl' has not > been declared > > using ::nearbyintl; > > ^~~~~~~~~~ > > ../projects/libcxx/include/cmath:514:9: error: '::nextafterl' has not > been declared > > using ::nextafterl; > > ^~~~~~~~~~ > > ../projects/libcxx/include/cmath:515:9: error: '::nexttowardl' has not > been declared > > using ::nexttowardl; > > ^~~~~~~~~~~ > > ../projects/libcxx/include/cmath:516:9: error: '::remainderl' has not > been declared > > using ::remainderl; > > ^~~~~~~~~~ > > ../projects/libcxx/include/cmath:517:9: error: '::remquol' has not been > declared > > using ::remquol; > > ^~~~~~~ > > ../projects/libcxx/include/cmath:518:9: error: '::rintl' has not been > declared > > using ::rintl; > > ^~~~~ > > ../projects/libcxx/include/cmath:519:9: error: '::roundl' has not been > declared > > using ::roundl; > > ^~~~~~ > > ../projects/libcxx/include/cmath:520:9: error: '::scalblnl' has not > been declared > > using ::scalblnl; > > ^~~~~~~~ > > ../projects/libcxx/include/cmath:521:9: error: '::scalbnl' has not been > declared > > using ::scalbnl; > > ^~~~~~~ > > ../projects/libcxx/include/cmath:522:9: error: '::tgammal' has not been > declared > > using ::tgammal; > > ^~~~~~~ > > ../projects/libcxx/include/cmath:523:9: error: '::truncl' has not been > declared > > using ::truncl; > > ^~~~~~ > > > > _______________________________________________ > > LLVM Developers mailing list > > llvm-dev at lists.llvm.org > > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev > >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20180206/b08af400/attachment-0001.html>
Reasonably Related Threads
- libc++ cross-compile linux-armv7 and math function problems
- libc++ cross-compile linux-armv7 and math function problems
- Cross-compiling libc++ to linux-armv7hf gives undefined symbols in cmath / math.h
- LLVM-3.8.0 libcxx in-tree build fails with cmath error ::signbit has not been declared
- LLVM-3.8.0 libcxx in-tree build fails with cmath error ::signbit has not been declared